This category contains 16 posts

MQL4: Get the highest price of a set number of periods, candles, bars

High[x] returns the high price of the period at shift x. iHighest() returns the shift of where the highest price is observed for the defined periods. Combine them to obtain the highest price for the defined periods: double highestPrice = High[iHighest(Symbol(), 0, MODE_HIGH, 10, 1)]; In this example, the last parameter being “1” … Continue reading

Getting Fibonacci prices from the percentage level

Getting a price at a Fibonnaci percentage level is a straightforward mathematical calculation. We just need to define 3 things: 1. Price at 100% 2. Price at 0% 3. Percentage to return Price at This is a script illustrating all the calculation needed: You just need these 2 lines to to obtain your required price … Continue reading

MQL: Making your extern inputs as a dropdown list of fixed options

A quick script illustrating making your extern inputs as a dropdown list of fixed options. This is what will be seen.

MQL: Get maximum value in an array

Simple script illustrating getting the maximum value in an array. Code identical for MQL4 and MQL5. MT4 output: MT5 output:

MetaTrader 4 Client Terminal Build 646

MetaTrader 4 updated to Build 646 (30 Apr 2014), and MetaEditor to Build 934 (30 Apr 2014): The interesting updates I found are: 3. Terminal: Increased the number of supported email service protocols. Now, alerts and emails from MQL4 applications can be sent to Gmail, Hotmail, Yahoo and other mailboxes. Set the target mailbox … Continue reading



Flag Counter