Login Page - Create Account

Support Board


Date/Time: Sat, 27 Jul 2024 01:17:36 +0000



[Programming Help] - Not updating index

View Count: 179

[2024-02-12 17:08:18]
User285179 - Posts: 14
Hey, I am doing ACSIL from last 5 days and stuck to this point. I am using GetPointOfControlPriceVolumeForBar for only 5 bars on a chart, not all. I used this code and its working.

sc.AutoLoop = 0;
sc.MaintainVolumeAtPriceData = true;
for (int BarIndex = sc.ArraySize - 5; BarIndex <= sc.ArraySize; BarIndex++)
  {
    s_VolumeAtPriceV2 VAP_POC;
    sc.GetPointOfControlPriceVolumeForBar(BarIndex, VAP_POC);

    if (VAP_POC.PriceInTicks != 0)
    {
      Subgraph_VPOC.Data[BarIndex] = sc.TicksToPriceValue(VAP_POC.PriceInTicks);
    }
  }

The problem is that It scontinuously adding more and more candles. I only want result of 5 candles only.

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

Login

Login Page - Create Account