Login Page - Create Account

Support Board


Date/Time: Wed, 05 Mar 2025 19:34:57 +0000



Post From: Problems with Drawing Tools

[2022-01-05 15:18:45]
Sierra123 - Posts: 27
I have two problems with the drawing tools, one is API-based, and the 2nd is with the User Interface. I've read documentation specific to these problem areas and nothing I could find applies.

1) I create a DRAWING_TEXT on the chart, with a BeginDateTime Anchor that is specified down to the second. E.G. Jan 4, 2022 at 10:30:07. It doesn't matter if I create it on a 1 second chart, 5 second chart, 1 minute chart, or any other time interval chart. The value of the Anchor remains accurate down to the second. (I can see it in Manage Drawings Window). As part of my application, I need to Hide/Show the Drawing. Here is where the problem is. As soon as I send the sc.UseTool() method to update the Drawing to be Hidden (or Shown if already Hidden), The BeginDateTime Anchor is also updated to have a value that is justified to the current barInterval of the chart. As per example above, it is modified to 10:30:00 on a 1-minute chart, losing the seconds of precision.
What can I do to avoid this, other than deleting the DRAWING and RE-ADDING it? That is very time consuming for lots of Drawings.

[Removed 2nd question, moving to anther thread.]
Date Time Of Last Edit: 2022-01-07 18:27:41