Codes

Delete all objects on chart (main window and sub window) with drag and drop for MetaTrader 5

It will delete all objects on the chart when the script is dragged onto the chart

Click on the market chart to create a price alert for MetaTrader 5

This is a first for MetaTrader 5. Now you can click on the chart to create price alerts

Confluence Detector for MetaTrader 5

It will detect whether there's confluence between the current chart timeframe and two other timeframes

MT5 CCI with shift parameter for MetaTrader 5

The default CCI in MT5 doesn't have the shift parameter. This script implements the shift

Automatic Chart Refresher for MetaTrader 5

A tool which refreshes the chart automatically and will make active indicators update if something stopped plotting on the chart

Plot the previous candlestick OHLC of the selected period for MetaTrader 5

It will automatically plot a colored horizontal line on the previous open/highs/lows/close of the selected period, and it will make the lines consistent on this price when switching timeframes

Translating mouse click on chart into price value (Helper function) for MetaTrader 5

This is a helper function which enables you to find the price of the symbol (the prices on the Y-axis) wherever you click the mouse on the chart. Using OnChartEvent, we don't have an MQL5 function in the API to do this, we can only obtain X and Y pixel values with mouse click

Moving Average with alerts on price crossovers for MetaTrader 5

I wanted to build a moving average which would create an alert when the price moves over the line by a user defined amount of points. It creates both bullish and bearish signals depending on the direction of market price moving through the MA. It is designed for slow length moving averages (default

Forum

Could simplicity win against complexity in EA programming?

For those who are experienced in programming EAs, I'd value your opinion on this. If you have an EA that makes buy and sell positions based on valid strong signals, is this better than having a lot of position management code (recovery trades, PnL analysis etc.)? I wrote a script full of position

Can two EAs control a trade on the same symbol (different charts)?

I'm wondering if it's possible to have two EAs with the same magic number running on two different charts but on the same symbol. I'd like to know if this would make both EAs watch the same trades. The idea is to make the 2nd advisor employ extra money management features while I don't have access

Highlighting noise/consolidation area in the market

In your opinion...most effective way to find the areas of noise and consolidation by means of technology? What comes to mind is the ATR, and basic volume analysis, but I'd like to know your opinion

PosititionModify keeps trying to modify the same position over and over again

Looking at the journal, you can see it is trying to modify the same position with the same SL and TP every tick: 2024.05.23 13:15:36.661 2024.05.01 21:00:58 order performed buy 1 at 1.06904 [#6 buy 1 EURUSD at 1.06904] 2024.05.23 13:15:36.663 2024.05.01 21:00:58 CTrade::OrderSend: market buy 1.00

Discuss plot normalization code

I'm talking about oscillator based indicators, and by normalization I mean that the plot is in a stable range and the 0.00 level remains directly in the center of the window. My knowledge is limited on this, but I figured out that if you have a plot ranging from a negative value to a positive value

What makes an indicator free and what makes it not free?

I'm just genuinely interested in your opinion. What is it which makes an indicator a freebie, and what is it which makes an indicator have a cost attached to it

Programming a Kill Switch in your EA

Introduction Anticipating the unforeseen is a cardinal principle in the realm of automated trading. Despite the meticulous design and rigorous testing of trading algorithms, the reality remains that even the most sophisticated Expert Advisors (EAs) are susceptible to making erroneous trades

Is it possible and feasible to design your own activation system into an indicator or EA?

Quote: "When selling products on the MetaQuotes Marketplace, the platform allows you to specify a certain number of activations for your product. These activations are tied to a unique installation code that ensures the product only works on the buyer's PC³. Regarding coding these activations into

Facing difficulty trying to overlay a line plot on top of Color Candles (in the separate window)

I made a simple candlestick chart in the separate window (DRAW_COLOR_CANDLES). I wanted to make a moving average in the same window, but when the buffers have very different values it causes the candlestick chart to scaled down so much that you can't see it anymore. Is it not possible to do what I'm

The best way to freeze a signal so the signal doesn't repaint

I have a signal indicator that should make an arrow on the LL or HH for any timeframe, but it repaints frantically like a rabid racoon on crack cocaine. One idea to stop something repainting is to take the initial signal it found and force it to remain with some boolean logic, another idea would be