Support Board
Date/Time: Fri, 29 Nov 2024 10:23:45 +0000
[Programming Help] - SetStudyVisibilityState flakiness?
View Count: 330
[2023-02-18 23:36:23] |
User275839 - Posts: 61 |
Hello - Note: This is in SC v.2480, using the remote build facility to generate the study DLL. I have a simple ACSIL custom study that places a custom button in the control bar to let me toggle a study's visibility by clicking the button. I am finding that calls to SetStudyVisibilityState(int StudyID, int Visible) don't appear to stick. To test, I put a check using GetStudyVisibilityState() before and after the call to SetStudyVisibilityState to verify the visibility state of the study. Before state = 1 Call SetStudyVisibilityState with 'Visible = 0' After state = 0 However, the study is still shown on the chart, and the "hidden" checkbox for the study is unchecked. So, the ACSIL calls are reporting one thing, but the Sierra UI is showing the opposite. Is there something else I have to do to make the visibility toggle call take effect? Thank you! |
[2023-02-19 23:16:43] |
User275839 - Posts: 61 |
UPDATE by OP -- I did make one discovery in messing around with this some more... It appears that the actual on-screen update AND the associated study visibility setting (checkbox) in the UI, occurs only on chart redraw. I was doing my development and testing over the weekend when there was no live market data, so the chart would not redraw on its own. Forcing a redraw by hitting the INSERT key or changing the bar period would cause the study internal visibility state and the on-screen/UI state to return to synch. So I suspect that this is "expected behavior" as there is no need to redraw the chart if nothing is happening. |
To post a message in this thread, you need to log in with your Sierra Chart account: