Login Page - Create Account

Support Board


Date/Time: Wed, 25 Dec 2024 16:23:47 +0000



Post From: ACSIL: Use Date Range

[2015-11-19 02:26:56]
QnReally - Posts: 181
The chart properties image is attached. Chart data dates are set to April of this year. The chart reloads as expected every 15 seconds based on the following study. However, it doesn't set the new dates as expected (the study uses dates 42314 and 43320 which are both in November).
SCSFExport scsf_Test3(SCStudyInterfaceRef sc)
{
  SCDateTime& lastLoad = sc.PersistVars->scdt1;
  if (sc.SetDefaults)
  {
    sc.GraphName = "Set Chart Dates";
    sc.AutoLoop = 0;
    sc.FreeDLL = 0;
    sc.GraphRegion = 0;

    return;
  }

  if (sc.HideStudy) return;
  if (sc.DownloadingHistoricalData) return;
  if (sc.UpdateStartIndex == 0) {
    lastLoad = sc.CurrentSystemDateTime;
  }
  if ((sc.CurrentSystemDateTime - lastLoad) > 15 * SECONDS) {
    sc.ChartDataStartDate = 42314;
    sc.ChartDataEndDate = 42320;
    sc.LoadChartDataByDateRange = 1;
    sc.FlagToReloadChartData = 1;
  }
}

Your thoughts please.
imageChartProperties.png / V - Attached On 2015-11-19 02:20:22 UTC - Size: 52.57 KB - 410 views
imageChartReloadsEvery15Secs.png / V - Attached On 2015-11-19 02:20:29 UTC - Size: 14.35 KB - 336 views