MQL4 Learning - page 137

 
Kamui.:
Hi, I want to write an indy. It shall point an arrow at bar when cci goes below 0 after it was over 100.

So cci goes over 100 and when it goes below 0 I want an arrow there.

The arrow itself in no problem.

How do I find the bar over 100 and save it till it goes below 0?

Add a buffer and store values in it.

Something like :

above100Buffer = above100Buffer;

if (cciValue>100) above100Buffer = 1;

if (cciValue<0)

{

if (above100Buffer==1)drawArrow();

above100Buffer = 0;

}

 

Many many thx. It works!

 

Hi, next problem/question.

I have this indicator Digital filters - separate 600+ written by igorad and I want to call the 5 values from its data window with another indicator, but how? I tried to call the Buffers, but they all have the same valure.

Can someone help me pls?

Many THX

 
Kamui.:
Hi, next problem/question.

I have this indicator Digital filters - separate 600+ written by igorad and I want to call the 5 values from its data window with another indicator, but how? I tried to call the Buffers, but they all have the same valure.

Can someone help me pls?

Many THX

Kamui

That indicator was written by me, not igorad - changing the stringUpperCase to be compatible with new mql hardly classifies as writing the indicator

As of buffer : don't know what code you use, but it is almost sure that you forgot the first parameter in the iCustom() call - the TimeFrame parameter. Place one "" (empty string) for that parameter in the iCustom() call and it will work

 
mladen:
Kamui

That indicator was written by me, not igorad - changing the stringUpperCase to be compatible with new mql hardly classifies as writing the indicator

As of buffer : don't know what code you use, but it is almost sure that you forgot the first parameter in the iCustom() call - the TimeFrame parameter. Place one "" (empty string) for that parameter in the iCustom() call and it will work

Oh, sorry for my mistake.

My call lookes like this:

double values =

iCustom(NULL,0,"Digital filters - separate 600+",FilterType,Price,LengthForBands,true,4,0);

Can you tell me what it shall look like?

 
Kamui.:
Oh, sorry for my mistake.

My call lookes like this:

double values =

iCustom(NULL,0,"Digital filters - separate 600+",FilterType,Price,LengthForBands,true,4,0);

Can you tell me what it shall look like?

Kamui

It should be like this :

iCustom(NULL,0,"Digital filters - separate 600+","",FilterType,Price,LengthForBands,true,4,0);

 

Again, many many Thanks . And a happy new Year

 

Hi,

I have a question regarding dll.

Is there a way to check "allow dll imports" directly in the code of the script, so that we don't need to check it when we run the script?

Best regards

Yoseph

 
YosephStein:
Hi,

I have a question regarding dll.

Is there a way to check "allow dll imports" directly in the code of the script, so that we don't need to check it when we run the script?

Best regards

Yoseph

YosephStein

No, there is no way to do that automatically from the code

 

Hi to everyone, I am studying now the MQL4 course, and I feel that what I need mostly is a bunch of live and real examples of indicators and experts code. I know that the best way to lern somthing is by good and qualitative examples. Do you have ones? Do you know where can I find some? Thanks a lot