MQL4 Learning - page 64

 

Look at the Help

bool OrderModify( int ticket, double price, double stoploss, double takeprofit, datetime expiration, color arrow_color=CLR_NONE)

You can change:

price - only for pending orders

stoploss

takeprofit

expiration - only for pending orders (some brokers prohibit it)

and put arrows.

That's all.

 
 

How to add my customer indicator in my E.A. ?

I want to creat my own indicator which can be called and return a value for E.A.. How can i to do about the Indicator and E.A. ?

BR,

CY

 

Hi,

you can use the icustom() command. It will return you the value of your indicator at the current, previous...nbar.

 
mudar:
Hi, you can use the icustom() command. It will return you the value of your indicator at the current, previous...nbar.

Many thanks, I will try it.

 

how to pass String type reference parameter from MQL4 to VC++ DLL?

Anybody can help me how to pass String type reference parameter from MQL4 to VC++ DLL?

tx

 

my partial close is not working properly

Pls guy find below my EA which calculates LOT size as a % to freemargin and closes 50% of orderlots() at breakeven. But the problem is that it keeps on closing 50% of the balance until there is a balance of 0.01 lot. please make it close only the first 50% of the opened position and let the rest run for profit.

Please help I really need this. I am still learning mql4 and I must say that its really challenging especially that there are very few tutorial books on this language.

sabri

Files:
00000.mq4  11 kb
 

how to make this indicator?

I am learning a few things and I would like to make an indicator that I have external inputs of a high and low trend line plus percentage.

I want to input my high and low s/r line then shade the % area to the inside...if I entered 20% then 20% from the top line and 20% from the bottom line would be shaded (still want to see the area underneath)...been looking around to see an example that I could work off of, but I guess I don't know the proper terms to search for...any ideas would be appreciated.

Thank you!

 

Hello Coding Experts,

Someone please explain:

when code should be written within the function init() ?

when code should be written within the function deinit() ?

I have been looking for the answer to these questions on the internet but I got nothing that explains it in clear practical application terms.

examples would help...

Thanks in advance.

 
pgd:
Hello Coding Experts,

Someone please explain:

when code should be written within the function init() ?

when code should be written within the function deinit() ?

I have been looking for the answer to these questions on the internet but I got nothing that explains it in clear practical application terms.

examples would help...

Thanks in advance.

Special Functions - Program in MQL4 - MQL4 Tutorial