Best way to get data when position closes automatically?
pag24
Post subject: Best way to get data when position closes automatically?
Post rating: 0
Posted: Mon 16 Jan, 2012, 19:42
User rating: 0
Joined: Sat 19 Nov, 2011, 01:24 Posts: 23 Location: United Kingdom,
At the moment my strategy is setup to output data to a text file, things like price and time whenever an order is filled. I'm doing this because I'm post processing in matlab.
What I would like to know is, when a position closes, either because its hit its stop loss or whatever reason, what is the best way to capture the information of what time and price it has been closed at?
I believe a way would be to capture the data from onMessage correct?
Is there a better way or could someone show an example of how to do this?
Thank you.
API Support
Post subject: Re: Best way to get data when position closes automatically?