Reply

How can I exit long and short orders on the custom date?

1 replies

gao

Subscriber, bbp_participant, 0 replies.

Visit profile

4 years ago #247282

How can I exit long and short orders on the custom date and time when the strategy runs?

 

MC / TS code:

if date = 20190201 and time =1500 then begin
sell this bar at close;
buytocover this bar at close;

end;

0

tomas262

Administrator, sq-ultimate, 2 replies.

Visit profile

4 years ago #247288

Hello,

custom date needs to be specified manually in the code as you show or using the AlgoWizard editor by editing the strategy (as shown on the screenshot attached)

Attachments:
You must be logged in to view attached files.

0

Viewing 1 replies (of 1 total)