Jump to content
Medved Trader Forums

AntoineOpala

Members
  • Posts

    2
  • Joined

  • Last visited

Reputation

0 Neutral
  1. Your first suggestion, for the main order, works perfectly. It is indeed what I needed there. Thank you. For the legs, it doesn't work as intended. I'm trying to flip the stoploss and target prices upside down depending on whether the main order is long or short. If the main order is long, the stoploss should be -0.06 below the entry price. This is currently the case ✔. If the main order is short, then the stoploss should move around to the other side and be +0.06 above the entry price. This is currently not the case ❌. How to program this? Currently, the stoploss is always below the entry price regardless of whether I'm buying or shorting a stock. It should flip above in case I'm shorting. The limit and stop prices I decided are designed to make me risk $5 per trade. Basically, if I buy 83 stocks and if my trade fails, I will only lose 83 * $0.06. If you do the math, I will only lose $4.98. As for my target limit order, it is set to +33. I know it's too far to trigger. I'm doing this just so a target limit order exists in the machine. I can later adjust its price on the fly depending on where the market will have gone.
  2. Hello, My goal is to create the following saved order : - Buy/sell (depending on which DOM column the mouse is currently over) StopLimit (Stop = PriceAtMouse; Limit = PriceAtMouse+0.01), 83 quantity. It is an OTOCA. Therefore, two more orders come with it. An order to buy/sell (whichever is the opposite of the first action above) StopMarket at PriceAtMouse-0.06. This is basically my stoploss. Another order to buy/sell (whichever is the opposite of the first action above again) at PriceAtMouse+33. This is my take profit. Which formulas would be the correct ones? I cannot find what works to buy or sell depending on which DOM column the mouse is at. I currently have programmed the following thing, but the action "CapOrderType" doesn't work. Using it creates the following message: Error in tag "Action": CapOrderType is invalid - mouse is not over the window." Yet, I guarantee you I'm executing this in a DOM window. Best regards, Antoine
×
×
  • Create New...