Error message : Closing Order Quantity

Posted By: OptimusPrime

Error message : Closing Order Quantity - 03/18/19 21:07

Hi Team:

Does anyone have any experience with this Interactive Brokers error message and possible causes/remedies?

" !The closing order quantity is greater than your current position." It's typically followed by Error 075

Much appreciated.
Posted By: jcl

Re: Error message : Closing Order Quantity - 03/19/19 10:44

The IB API has no command for closing. How did you get that message? Was it an asset that cannot be shorted?
Posted By: Zheka

Re: Error message : Closing Order Quantity - 03/19/19 15:21

You will get this from IB when you are reversing a position (i.e. short 2 when long 1). However, this is normally a "warning", not something that actually prohibits order placement.

You can (AFAIK) suppress it by "bypass Order precautions for API orders" in IBG/TWS and/or disable the "Cross Side Warning"

That Zorro does not actually place an order is most probably because of how Zorro handles this warning.
Posted By: jcl

Re: Error message : Closing Order Quantity - 03/20/19 07:59

Warnings won't matter, but error 075 means that the position could really not be opened. Check the log, maybe there is another error or the asset cannot be shorted.
Posted By: OptimusPrime

Re: Error message : Closing Order Quantity - 03/20/19 11:49

Thanks JCL and Zheka.. I am testing on the USD/JPY (or any FX pair really).
Posted By: Zheka

Re: Error message : Closing Order Quantity - 03/29/19 09:44

Did you manage to resolve the issue?
Posted By: OptimusPrime

Re: Error message : Closing Order Quantity - 03/31/19 19:25

Hi Zheka: thanks for the followup! I have been working on various parts of the script and did not notice what I changed specifically to remove the warning. I no longer get the warning.

I will retrace my steps and see what change(s) removed the warning.
© 2024 lite-C Forums