Login Page - Create Account

Support Board


Date/Time: Tue, 07 May 2024 08:32:36 +0000



[Programming Help] - Sim mode attached orders.

View Count: 850

[2016-07-08 05:12:18]
enemyspy - Posts: 304
Hi I just wanted to quickly confirm something. I am using the following code block in order speed up replays. So basically it constantly truncates the size of the chart via start date in order to keep the memory lower ect. I did not notice this until recently - but what is happening is that if a trade is on during the reload and recalculate that the code below triggers: the attached target and stop are getting removed when the chart loads up again.
Is this to be expected? as in should the target and stop persist through this circumstance?


if(sc.Index == sc.ArraySize-1)
{
if (sc.IsReplayRunning() && (ReplayDays.GetInt()>0 && !sc.IsFullRecalculation))
{
SCDateTime Current = sc.BaseDateTimeIn[sc.ArraySize - 1];
if (DATE_PART(Current) - DATE_PART(sc.BaseDateTimeIn[0]) > ReplayDays.GetInt() && Current.GetDayOfWeek()<3)
{
        
SCString mssg;        
sc.ChartDataStartDate = DATE_PART(Current) - (Current.GetDayOfWeek() + 2);        
sc.AddMessageToLog(mssg.Format("Replay Optimizer Reloading : %d",sc.ChartDataStartDate),1);        
      
}
}

Date Time Of Last Edit: 2016-07-08 05:15:12
[2016-07-08 05:46:55]
enemyspy - Posts: 304
actually sorry it looks like what is happening is the trade position is getting removed but the target and and stop are staying so what it is doing is then entering a new position off the target or stop. It still may also be doing as described in post 1 as well.

Is it possible if the position entry is outside the bounds of the newly loaded chart that it will not show up?
The Trade activity Log indicates "Unmatched fill" on these.
[2016-07-08 09:05:18]
enemyspy - Posts: 304
This is not an issue any more was able to fix via using the last trade open date as the new start date, now there are no issues.
Date Time Of Last Edit: 2016-07-08 09:05:32
[2016-07-08 17:36:43]
Sierra Chart Engineering - Posts: 104368
For help with Unmatched Fills, refer to:
https://www.sierrachart.com/index.php?page=doc/doc_TradeActivityLog.php#TradesTabUnmatchedFill
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, *change* to the Teton service:
Sierra Chart Teton Futures Order Routing

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account