Support Board
Date/Time: Sun, 22 Dec 2024 11:20:45 +0000
Post From: UseTool Text bug
[2015-08-04 16:01:44] |
User431614 - Posts: 4 |
I am running SC Build 1280 on Windows 8.1 (64-bit). I built a study to display average values on the left side of my chart. The problem is that they are randomly over-written by other values. This seems to be some kind of memory or pointer issue in SC, since I can reproduce the problem with static values for my averages. float EMA_Value1 = 20.0;
float EMA_Value2 = 40.0; float Simple_Avg1_Value = 60.0; float Simple_Avg2_Value = 80.0; float Simple_Avg3_Value = 100.0; float Simple_Avg4_Value = 120.0; float Previous_Close_Value = 140.0; // Character arrays const char* EMA_Value1Chars = sg.FormatGraphValue(EMA_Value1, sg.BaseGraphValueFormat).GetChars(); const char* EMA_Value2Chars = sg.FormatGraphValue(EMA_Value2, sg.BaseGraphValueFormat).GetChars(); const char* Simple_Avg1_ValueChars = sg.FormatGraphValue(Simple_Avg1_Value, sg.BaseGraphValueFormat).GetChars(); const char* Simple_Avg2_ValueChars = sg.FormatGraphValue(Simple_Avg2_Value, sg.BaseGraphValueFormat).GetChars(); const char* Simple_Avg3_ValueChars = sg.FormatGraphValue(Simple_Avg3_Value, sg.BaseGraphValueFormat).GetChars(); const char* Simple_Avg4_ValueChars = sg.FormatGraphValue(Simple_Avg4_Value, sg.BaseGraphValueFormat).GetChars(); const char* Previous_Close_ValueChars = sg.FormatGraphValue(Previous_Close_Value, sg.BaseGraphValueFormat).GetChars(); Please find the attached dll, which you can use to reproduce this issue; just load the study in one of your charts and hit "Insert" or "Cntl-Insert" repeatedly. You will see the pink values on the left change, which should be impossible (they are statically defined as floats). Date Time Of Last Edit: 2015-08-04 17:26:35
|