Support and Resistance - Tools - MetaTrader 4 Scripts | Trading Script Downloads - MT4/MT5 Resources



Place your mouse cursor where you want the line to be created and press the "A" key (if you keep the default key), the line will be created automatically and you can create it as many times as you want.
Lines are drawn with the color and style you choose in the parameters.
When the price crosses a line, you will receive an alert by default, or a smartphone notification if you prefer.
Now you can use the auxiliary line. Therefore, you can use the first line as heavy resistance and support and the second line as warning or light resistance and support. If you want more, I can add more.
outer string horizontal line = "a" ; //key to create SR line(1) External color line resistance color = clr dodge blue ; //resistance line color(1) External color line support color = clr dark orange ; // support line color (1) External ENUM_LINE_STYLE line style = style_entity ; //SR line style (1) External integer line width = 1 ; //Select the width of the line (1) outer string horizontal line second = "ask" ; //Create SR line key(2) external color line resistance color second = clr dodge blue ; //resistance line color(2) external color line support color seconds = clr dark orange ; // support line color(2) External ENUM_LINE_STYLE line type second = style_point ; //SR line style(2) External integer line width seconds = 1 ; //Select the width of the line (2) external boolean TakecareManualTrendLine = true ; // handle manually added trendlines outer string delete last row = "X" ; //key to delete last SR row External boolean value AlarmCrossWithAlert= True ; //Send alert external boolean AlarmCrossWhithPushSmartphone= True ; //Send notification external boolean MagnetLinePriceOnFullPip = true ; // draw a line at 1.1500 even if the mouse is at 1.15002 external double default lot size = 0.1 ; //calculate monetary value of lots integer external history = 200 ; //Number of candles to check, could be 200 minutes or 200 weeks, depending on your timeframe integer outside maximum deviation = 10 ; // If the candle stops below 10 pips, it will appear in the history of support and resistance levels External color text color = red blood cells ; //Color of mouse position and history boolean value external comment or not = true ; // You can choose to see mouse and support/resistance history in comments or positionable tags

You can see the purple pips separated from the actual price, and if you mouse over the label or line it will display the value using your default lot size.
In the yellow part, you can see floating boxes where you can move your mouse around the chart for price and historical information. You can view the history of a line by clicking on the line label.

In the blue circle you can see the price at the position of the mouse cursor. Lines are created in seconds, and styles and colors change automatically.

In this example, you can see that when the price drops, the line 0.71 changes color and an alert is sent via the MetaTrader alert box. But you can choose smartphone notifications or both.
If you have other ideas, you can share them.
Attachment download
📎 keycontrol_support_resistance.mq4 (27.04 KB)
Source: MQL5 #13649
💡 Featured Recommendations
✍️ Latest by the author
- •
- •
- •
- •
- •
- •
📌 Popular topics
- •
- •
- •
- •
- •
- •
- •
- •
🔗 You May Be Interested In
- •
- •
- •
- •
- •
- •