Support Board
Date/Time: Tue, 04 Nov 2025 01:39:16 +0000
[Programming Help] - Alert when Price is within 2 ticks from a Moving Average
View Count: 993
|   [2018-09-06 12:59:50]     |  
| User164231 - Posts: 281 | 
| 
                Hi, I am using this formula but it only triggers when touched. AND(H >=ID2.SG1,L <= ID2.SG1) What is the code to use in order to have the alert triggered when price is within 2 ticks of nearing a Moving Average?  | 
        
|   [2018-09-06 13:22:52]     |  
| Sawtooth - Posts: 4285 | 
| 
                Try this: AND(H>=ID2.SG1-TICKSIZE*2,L<=ID2.SG1+TICKSIZE*2)  | 
        
|   [2018-09-07 06:11:37]     |  
| User164231 - Posts: 281 | 
| 
                Hi Tom, It worked perfectly! Thank you very much. Date Time Of Last Edit: 2018-09-07 06:39:12  
             | 
        
To post a message in this thread, you need to log in with your Sierra Chart account:
