Login Page - Create Account

Support Board


Date/Time: Thu, 09 May 2024 00:11:04 +0000



GetTimeAndSales freezes DOM, when used inside GDI function

View Count: 143

[2024-04-05 23:36:51]
KylieV1618 - Posts: 59
Im trying to access the TimeAndSales, from within a GDI drawing function.
In replay mode this works fine, and the script fires normally.

But when the market is live, it freezes the DOM (which is where I have the study applied).
Hiding the script, makes the DOM come back to life.

Here is the code

The script...

if (sc.HideStudy == 1)
return;


if (hasAccess == 1)
{

sc.p_GDIFunction = MyGDIDrawingFunction;
}



Inside the GDI function at the top

c_SCTimeAndSalesArray TimeSales;
sc.GetTimeAndSales(TimeSales);


I deleted literally all the code out of the function, and boiled it down to these lines.
When you add this to a DOM, it will hang the DOM.

Any ideas why this might occur??


Would you just recommend storing the TimeAndSales array as a persistent var to access in GDI?
Because when I move these 2 lines into the main script, everything runs again just fine.
Date Time Of Last Edit: 2024-04-05 23:59:46
[2024-04-06 00:03:53]
Sierra_Chart Engineering - Posts: 14282
We know why this happens. We will fix this in the next release.

It was not contemplated that function would be used from the graphics drawing function.
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, use the Teton service:
Sierra Chart Teton Futures Order Routing
Date Time Of Last Edit: 2024-04-06 00:04:14
[2024-04-16 04:38:03]
KylieV1618 - Posts: 59
Has this been updated yet? Just need to know if I should pull the latest version
[2024-04-16 05:00:01]
Sierra_Chart Engineering - Posts: 14282
Not sure if it has been released but it will be in version 2628. So we recommend waiting until then. We expect this to be released over the next 24 hours.
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, use 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