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)
I have the following code I use as a trailing stop loss:
When I build a conditional sell order in the Study Order Condition screen, I set it up as the following:
My problem is, seemingly at random, I'll get an error message stating "rec usage is not allowed in this context". Twice now, I've built this study from scratch, testing to see if the order will pass with each change and it'll work, but then it seems as if it just decides it doesn't want to work anymore.
For example, I set the order up last night and it worked perfectly this morning. When I tied to setup my next order, I get the error message. What am I dong wrong? I'm stumped...HALP
Can you help answer these questions from other members on NexusFi?
your definition of trail references the previous value. this is called a recursive reference. according to the docs (at the very bottom here), this is not allowed in conditional orders: (add http colon slash slash) tlc.thinkorswim.com/center/howToTos/thinkManual/Trade/Order-Entry-Tools/conditionalorders.html
Is there a broker other than TOS/Ameritrade that will allow rec usage? Or were you able to find a work around? Trying to find someplace to use an ATR trailstop to close an open position automatically with a conditional/coded orders. I keep getting this recursive data not allowed message too, and I guess will need to switch to another broker that will if possible. Thanks in advance for any help