question

Upvotes
Accepted
16 1 0 2

Cancel all syntax to cancel all open orders

I need to sometimes cancel all my orders under a Redi Plus user ID. I can currently cancel via excel VBA and cancel by account symbol. However, if I feed each individual symbol and request a cancel that way, it is too slow. Is there a cancel all and if so, what is the VBA syntax?

redi-api
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

@kris_mcc
Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query? If yes please click the 'Accept' text next to the reply. This will guide all community members who have a similar question. Otherwise please post again offering further insight into your question.
Thanks,
-AHS

@kris_mcc
Please be informed that a reply has been verified as correct in answering the question, and has been marked as such.
Thanks,
-AHS

1 Answer

· Write an Answer
Upvotes
Accepted
79.2k 251 52 74

@kris_mcc

In the RediLib.Application class, there is the CancelAllOrders method used to cancel all open orders filtered by side and supervisory scope.

The code looks like:

Dim App As New RediLib.Application
Dim verr, rtnVal
rtnVal = App.CancelAllOrders(“Buy”, 1, verr)

You can refer to the REDI API SPECIFICATION for more information.


application.png (44.9 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.