Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
However there is bound to be a much more elegant way to do this - so if anyone does know of a way please let me know.
Essentially you need to throw your entryprice into the following command line
and then
where incomingpath = Cbi.Core.UserDataDir.ToString() + "\incoming\oif.txt";
This file is made and destroyed instantly and is better if you increment it for each order to prevent locking in cases of multiple orders hitting the file path simultaneously.
Now I am on to monitoring the outgoing file path for an oco order related to the entry!
Can you help answer these questions from other members on NexusFi?
Ok bit further ahead now - it would help if I had taken a course in C# or even better Ninja Script - so forgive the messy way this is done.
setting oif's in indicators is fraught with little niggles
1. You have to send orders to the incoming folder whilst the position is "updated" - I use that term loosely - in the outgoing folder (My Documents -Nt 6.5)
2. I am reading the file in the outgoing folder and checking for when it doesn't say "FLAT" - eventually I will get it to look for long and short but lets walk first.
3.once that happens ( ie I am assuming I have a filled order - again partial fills are not catered for yet) - you can then send a straight oco order to the incoming folder in the format
I am only using this in sim so far as there are lots of holes but I am very pleased so far - I can now submit an order and place a stop and a target that are oco - its just annoying I can't use all the built in position code as it's all strategy based - unless someone can tell me otherwise...
btw is anyone finding this useful?