Login Page - Create Account

Support Board


Date/Time: Thu, 18 Jan 2018 22:02:05 +0000



Cutting off a Rectangle

Support Request:
[2017-12-14 12:53:49]
WHum7812 - Posts: 11
Hello:

Could you please explain how exactly a line is cut off once price comes back up (or down) and intersects the line when using the AddLineUntilFutureIntersection function. I have written a script to test it and it works great. However, I do not understand how it knows when to cut off the line because there is nothing in the structure to tell it to. There is a StartBarIndex and the linevalue for the line but the rest of the parameters are for the line structure.

The reason I am asking is because I am trying to do something similar with the DRAWING_RECTANGLEHIGHLIGHT or DRAWING_RECTANGLE_EXT_HIGHLIGHT drawing type. I am using the sc.UseTool function to do this. I can get both draw type to appear on my chart properly, given my condition, but I am just unsure how to cut it off when price intersects it again. I think if I understood how the AddLineUntilFutureIntersection function did it, I could figure it out.

I would appreciate any help you could offer.

thank you,

Ward Hum
[2017-12-14 17:56:00]
Sierra Chart Engineering - Posts: 56270
DRAWING_RECTANGLE_EXT_HIGHLIGHT cannot be cut. The drawing would have to be changed to DRAWING_RECTANGLEHIGHLIGHT

To cut a drawing, you just need to modify the drawing and change this structure member:
https://www.sierrachart.com/index.php?page=doc/ACSILDrawingTools.html#EndDateTime

To modify a drawing, refer to:
https://www.sierrachart.com/index.php?page=doc/ACSILDrawingTools.html#AdjustingChartDrawings
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. If possible please keep your questions brief and to the point. Please be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

If your question/request has been answered and you do not have anything further, then it is easiest for us if you do not reply again to say thank you.
Date Time Of Last Edit: 2017-12-14 17:56:53
[2017-12-18 18:04:04]
WHum7812 - Posts: 11
Thank you very much with regards to the expending rectangle. I greatly appreciate your response.

I would still like to know how the AddLineUntilFutureIntersection function cuts off the line even though there is no part of its structure that has an end date and time. It is just so I may get a good idea of how I may do my logic also using the sc.UseTool function. Any guidance would be greatly appreciated.

Second, I have another study that uses lines and then cuts them so naturally I am using the the AddLineUntilFutureIntersection function. I set the structure using the sc.UseTool function. However, I am unable to get the AddAsUsDrawnDrawings to work. The drawings appear but not as user drawn drawings. Is this because I am using sc.AddLineUntilFutureIntersection?

thanks,

Ward Hum
[2017-12-18 19:35:27]
Sierra Chart Engineering - Posts: 56270

Second, I have another study that uses lines and then cuts them so naturally I am using the the AddLineUntilFutureIntersection function. I set the structure using the sc.UseTool function. However, I am unable to get the AddAsUsDrawnDrawings to work. The drawings appear but not as user drawn drawings. Is this because I am using sc.AddLineUntilFutureIntersection?
This does not make any sense.

sc.UseTool and sc.AddLineUntilFutureIntersection are totally separate and different functions altogether. The lines added by sc.AddLineUntilFutureIntersection are not drawing tool type of lines.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. If possible please keep your questions brief and to the point. Please be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

If your question/request has been answered and you do not have anything further, then it is easiest for us if you do not reply again to say thank you.
Date Time Of Last Edit: 2017-12-18 19:36:10
[2017-12-18 19:56:26]
WHum7812 - Posts: 11
Thank you.. You are absolutely right. What was I thinking trying to use two different functions together.....I am sorry for wasting your time. My apologies.

To post a message in this thread, you need to login with your Sierra Chart account:

Login


Login Page - Create Account