Login Page - Create Account

Support Board


Date/Time: Fri, 19 Dec 2025 13:32:35 +0000



Post From: ACSIL sc.SetBarPeriodParameters() causes indefinite loading loop

[2021-12-31 07:56:24]
User907968 - Posts: 859

n_ASCIL::s_BarPeriod NewBarPeriod;
if (NewBarPeriod.IntradayChartBarPeriodParameter1 != 30)
{
.
.
.
sc.SetBarPeriodParameters(NewBarPeriod)
}

The test 'IntradayChartBarPeriodParameter1 != 30' always returns true. Each time the study is called it is initialized to 0, therefore you are repeatedly calling 'sc.SetBarPeriodParameters(NewBarPeriod)'.

Need to call sc.GetBarPeriodParameters to fill data structure, before testing value(s) - as you do in the block at lines 181-191.
Date Time Of Last Edit: 2021-12-31 07:57:03