Forum

Error 10030 when closing position?

Hi, i get a nice fat 10030 error when i try to close a position for a given currency. Any ideas why? for ( int i= 0 ; i<NumOfCurrencyPairs; i++) { SymbolInfo.Select(currencyPairs[i].pairName); PositionSelect (currencyPairs[i].pairName);

Minimun goal for backtesting?

What do you guys think is an minimum for an EA before it should be tested on a live account? Whats the minimun profits, wins and things like that in your opinion

EA miss candles?

Hi! I were testing an EA and in i have a hardcoded rule that if the PSAR value is below the price there should be a sell. Now at more than one point this does not happen. As far as i can see my EA misses some candles. Forexample i have printed every tick and the values that are of intrest. It looks

Time calculations

I have an EA that looks for a signal to buy. When this signal is found it waits for a confirmation that the price is moving in a proftible direction. If the price has not changed in a good direction for a certan amounts of seconds. It signale is discarded. This check is done every tick, but. Im

Calculating cost of a trade

Hi I have a s ystem that can buy several lots of the currency at different times. What i would like to know is what the total trade has cost. For example trading EURUSD and buying at 4 different spots and selling all in one shot. Is there a way of doing the calculations? i will have been paying the

CPositionInfo fails

Hi Im trying to make an EA, but some how i cant get the CPositionInfo class to work. I have also tried to use the GetPositionXXX functions but with no luck. When i call int t = PositionsTotal(); It returns 1. PositionSelect(_Symbol) returns true. But it is impossible to get the information back