I am placing text in a label but as soon as the text length expands, instead of the text moving to the right, it moves off to the left like it is right justified or something. Any ideas? ObjectCreate ( "alerttext" , OBJ_LABEL , 0 , 0 , 0
I am having problems with alerts being repeated every time I change the chart period or reload metatrader. I though of using globalvariables but can you store datetimes in global variables? if ( iIchimoku ( Symbol ( ) , PERIOD_H4 , 9 , 26 , 52
I have some code which creates a little symbol indicator with buy/sell values. In this example the chinkou green line is above the price so it should be displaying an up arrow but it does not. Any ideas on what I have set incorrectly? The chinkou is
I would like to have an indicator that I can leave open on the daily chart but it monitors all timeframes below it. How can I get the close of a timeframe with set period? if ( Period ( ) = = PERIOD_D1 | | Period ( ) = = PERIOD_H4 | | Period ( ) = =
I'm trying to set rectangles for the chart background but seem to be getting the same colour no matter what, which is orange????? Seems like it's laying the colours over each other regardless of the timeframe ObjectCreate ( "D1_Rectangle"
Is there a way we could calculate the percentage of a candle outside a bollinger band ? For example, an upper bollinger band is at 1.5000 and a candle moves outside of this value to a high of 1.5020 and the low was 1.4990. Do we just calculate the
I am trying to list the value of the tenkan sen but it keeps displaying 0.00000 Any ideas? //---- Tenkan Sen i = Bars - Tenkan ; if ( counted_bars > Tenkan ) i = Bars - counted_bars - 1 ; while ( i > = 0 )
Is this the right way t do ichimoku alerts in MQL4? The alerts are at the bottom. I haven't figure dout a way of swapping over the senkou span/kumo cloud alerts yet apart from the alert every time the Bid price crosses. Complete code in the attached
I'm trying to get a histogram to show the differences bbetween 2 moving averages . I modified the OsMa for this but am not sure i have the buffers right for the drawing? It seems to draw it correctly but somehow the code doesn't seem correct
The alert is sounding every hour with this indicator, it should be picking up the previous value and only alerting if the lines have crossed back over. ANy ideas on what is wrong? //+------------------------------------------------------------------+
In my EA, I buy at the ASk, sell at the bid. On all SELL orders, I set a target profit and a stop loss both with 3 pips added due to the spread. However, when I run this in the strategy tester , BUY trades show profits of 400, losses of 400, yet SELL
I need to get the following code to also look at 0.25, 0.5, and 0.75 (ie 2 decimal places) in the range but not sure how to check that as well as checking the 1 st decimal place only. For example, it should alert me at all main 1.x numbers (1.1, 1.2
Any ideas how to round the JPY pairs here? If price is at 85, I'm trying to find how far it is away from a number in the array, eg 80 and 90, it should round up . It works for the 5 decimal place pairs. I am trying to round to tens so 80, 90, 100
I have an EA that I want to start when price nears a specified level in an array: double stops_array[11] = {1.0, 1.1, 1.2, 1.25, 1.3, 1.4, 1.5, 1.6, 1.75, 1.8, 1.9, 2.0}; So, I need to check the current Bid or Ask and round it to see which level it
Is there a way to work out if say the last 10 hourly candles are in a trend up or down? What I want to do is find a trend when price nears major points like 1.1, 1.5, 1.6, etc. and then add some orders if the price action has been in an uptrend or