Login Page - Create Account

Support Board


Date/Time: Sun, 02 Nov 2025 18:40:41 +0000



Spreadsheet system formula for exit positions l-3 & N-3 HELP!

View Count: 744

[2022-03-24 13:14:07]
User9890731 - Posts: 47
What formula must I add to l-3(sell exit) and n-3(buy exit) in order to have the spreadsheet close a trade when a signal no longer appears on k-3 or m-3 on the current bar. Basically if the signal appears on the column then an entry is made, but when the same signal on the same column disappears then the spreadsheet should flatten the position until a new signal is generated.

I already have an entry formula for k-3 and m-3;

=ID1.SG1@3 > 0
=ID1.SG2@3 > 0
[2022-03-24 13:31:22]
Sawtooth - Posts: 4285
Try this:
L3:
=AND(K4>0,K3=0)
N3:
=AND(M4>0,M3=0)
[2022-03-24 15:31:31]
User9890731 - Posts: 47
Hi Tomgilb,

Thanks for the reply, but it still failed to flatten the position, or is there an option in the spreadsheet study settings that I should set to ''yes'' for it to work. I have attached the test.
imageautotrader 1.png / V - Attached On 2022-03-24 15:29:49 UTC - Size: 137.36 KB - 170 views
imageautotrader 2.png / V - Attached On 2022-03-24 15:29:58 UTC - Size: 144.2 KB - 168 views
[2022-03-24 15:41:59]
Sawtooth - Posts: 4285
OK, try this:
L3:
=ID1.SG1@3 = 0
N3:
=ID1.SG2@3 = 0
[2022-03-24 15:57:44]
User9890731 - Posts: 47
Awesome! Works perfectly, thanks!

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

Login

Login Page - Create Account