[ARCHIVE] Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Nowhere without you - 3. - page 311

 
artmedia70:

Do you have weekend/holiday candles on your chart? They are skipped anyway. No?

Then count how many candles have passed since you opened the position

Semyon Semyonich! I was counting time, but I have to count candles! So let me ask you a question. Should I use iBarShift to solve this problem?

 
Professionals, please help! the multic is running on 3 currencies. I noticed that it opens trades in all currencies at the same time. I put different timeframes on each of the charts, but the EA itself changed the timeframe to the same for all. Is there any way to solve this problem ?
 

Help. I want to write an EA using AMA optimized indicator. I am using Print to check the indicator value. When I run the Expert Advisor on a chart, in the Experts tab it is displayed:

2011.11.02 23:40:02 Expert USDCHFX,M1: 0


Code of start of the Expert Advisor:

////////////////////////////////////////////////////////////////////////////////////////////

int start()

{

//calculate initial indicator parameters for finding entry conditions

double ma55=iMA(NULL,0,55,0,MODE_EMA,PRICE_CLOSE,0);

double ma21=iMA(NULL,0,21,0,MODE_EMA,PRICE_CLOSE,0);

double AMA=iCustom(NULL,0,AMA_optimized,1,0);

double m=TimeSeconds(TimeCurrent());

Print(AMA);

 
olis 02.11.2011 22:43 am | delete

Hi all!

I would like to test the idea, but I do not know how to code. The idea is very simple.

1. a position is opened
2. say 14 pips stop loss and 14 take profit
3. when the price goes down to stop loss, it closes
4. if price goes up to 12 pips, both take profit and stop loss are re-positioned upwards (plus 12 pips both)
Moves up until stop loss is hit.

According to the idea, the losses should be a lot, but the profits will sometimes be very nice.

I would be very grateful for the time spent.

 
Operr:
Semyon Semenych! I was counting time, but I have to count candles! That's why I'm asking. Should iBarShift be used to solve this problem?

Yes
 
skyjet:
Professionals, please help! the multic is running on 3 currencies. I noticed that it opens trades in all currencies at the same time. I put different timeframes on each of the charts, but the EA itself changed the timeframe to the same for all. Is there any way to solve this problem ?
Check out
 
Tarion:

Help. I want to write an EA using AMA optimized indicator. I am using Print to check the indicator value. When I run the Expert Advisor on a chart, in the Experts tab it is displayed:

2011.11.02 23:40:02 Expert USDCHFX,M1: 0


Code of start of the Expert Advisor:

////////////////////////////////////////////////////////////////////////////////////////////

int start()

{

//calculate initial indicator parameters for finding entry conditions

double ma55=iMA(NULL,0,55,0,MODE_EMA,PRICE_CLOSE,0);

double ma21=iMA(NULL,0,21,0,MODE_EMA,PRICE_CLOSE,0);

double AMA=iCustom(NULL,0,AMA_optimized,1,0);

double m=TimeSeconds(TimeCurrent());

Print(AMA);

Need help writing?
 
FAQ:
olis 02.11.2011 22:43 am | delete

Hi all!

I would like to test the idea, but I do not know how to code. The idea is very simple.

1. a position is opened
2. say 14 pips stop loss and 14 take profit
3. when the price goes down to stop loss, it closes
4. if price goes up to 12 pips, both take profit and stop loss are re-positioned upwards (plus 12 pips both)
Moves up until stop loss is hit.

According to the idea, the losses should be a lot, but the profits will sometimes be very nice.

I would be very grateful for the time spent.

For a reward, time is usually wasted... :) Or just out of boredom...
 
artmedia70:
For a reward, it's usually a waste of time... :) Or just out of boredom...
Is gratitude no longer appreciated?
 
FAQ:
olis 02.11.2011 22:43 am | delete

Hi all!

I would like to test the idea, but I do not know how to code. The idea is very simple.

1. a position is opened
2. say 14 pips stop loss and 14 take profit
3. when the price goes down to stop loss, it closes the position
4. if price goes up to 12 pips, both take profit and stop loss are re-positioned upwards (plus 12 pips both)
Moves up until stop loss is hit.

According to the idea, the losses should be a lot, but the profits will sometimes be very nice.

I will be very grateful to you for your time.

The new knowledge gained, despite the personal time spent, is the most valuable prize.

The best investment is an investment in knowledge/knowledge.