Support Board
Date/Time: Wed, 19 Mar 2025 23:37:21 +0000
Post From: ACSIL: sc.AddLineUntilFutureIntersection() delete lines
[2022-10-31 19:44:45] |
User431178 - Posts: 617 |
No, not exactly, because at the point of creation you do not know that it is intersected, being as the bars are processed sequentially. If you query the line immediately after adding it, you will see that endIndex is not set. There are other ways to approach this, but you cannot get away from first creating and then destroying the lines. When you say performance problems, I would assume that this is during initial calculation? What you can do to improve this is only run the code to delete the lines once the initial calculation is complete. For example: if (!sc.IsFullRecalculation) { //// Delete lines in here } Date Time Of Last Edit: 2022-10-31 19:45:21
|