Login Page - Create Account

Support Board


Date/Time: Sat, 01 Aug 2026 04:18:27 +0000



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

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

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