Forum

Array Question

Is there a way to search an array and see how many times a value range happens? Example in SQL would be something like: Select count(*) From table Group By Column What I am trying to do is search last 100 bars search how many bars comes within a certain range of the highest bar for the time frame

Tester

Anyone else seen issues where the tester closes trades right after opening the trade? I look but I can't figure out why it does it but other trades go fine. I looked at journal and can't see any reason for it to close

Sar & Bollinger Bands

For some reason it keeps placing the order at the end of the SAR run right before it switches over. double UpperBand = iBands ( NULL , 0 , 20 , 2 , 0 , PRICE_CLOSE , MODE_UPPER , 1 ); double MiddleBand = iMA ( NULL , 0 , 20 , 0 , MODE_SMA , PRICE_CLOSE , 1 ); double LowerBand = iBands ( NULL , 0

Heikin Ashi

Can anyone tell me how to detect when the trend direction changes from within an EA

Heiken Ashi Candlestick Strength

Anyone know how to check the fullness of a candle? Trying to avoid opening trades when candle is weak

How to get last close price

Anyone have any insight on getting the close price of the last order? I tried: if ( OrderSelect (OrdersHistoryTotal(),SELECT_BY_POS,MODE_HISTORY)== true ) { double LastOrderClosePrice = OrderClosePrice(); }

Function trigger time based

Is there a way to make a function trigger every 10 mins

Order info by Symbol

Anyone know of a way to call up order info by symbol? I don't need to call up an exact order just any order with a certain symbol to check the takeprofit point

TakeProfit adjustment

I am noticing when new orders are open on the same pair that the TakeProfit point for all orders are adjusted to the same point causing some orders to takeprofit at a loss. So how would I get what the current take profit point is for a certain open pair? That way I could evaluated it verse what the

Get account info

double MarginFree = AccountInfoDouble( ACCOUNT_MARGIN_FREE ); double Margin = AccountInfoDouble(ACCOUNT_MARGIN); double MarginCheck = MarginFree / Margin; When I use this I get a division by zero error