Various - page 25

 

Manual Orders Manager EA

Good morning everyone;

I beg you pardon my English.

Mr. mrtools or sr . mladen, could you build this EA for me please?.

I need a EA that could manage manual orders. Entry orders are triggered manually; however exits (profit and stop loss orders) are triggered by the strategy according to my parameters. I explain the variables. Pray what is not understood please feel free to ask.

variables:

Type broker = It automatically recognizes it .

EcnBroker extern bool = true ;

UseAutoMagic extern bool = true ;

extern int ManualMagic = 19283745 ;

Option 1 :

Opcion1_Starts = True or False

TakeProfit_Pips = x ( If we put 0 the operation will close when the price reaches the Trailing Stop or the stop order )

StopLoss_Pips = X

TrailingStop_Pips = X

Option 2 :

Opcion2_Starts = True or False

TakeProfit_Pips = X ( If we put 0 the operation will close when the price reaches Trailing StopLoss or the stop loss order )

StopLoss_Pips = x

MoveToBreakEvenAt_Pips = X ( When you have reached x pips profit , move stop to BreakEven ).

MoveToBreakEvenLock_Pips = X ( When you move the stop to BreakEven , the number of pips that we want to place the stop above or below our entry price )

TrailStopToBreakEven_Pips = x ( BreakEven Once reached , activates a trailstop from that point ). If this value equals 0 then this option will not apply.

Option 3:

Opcion3_Starts = True or False

TakeProfit_Pips = X ( if we put 0 the operation will close only by the Volty , if we put an amount , it could close by the Volty or get the number of pips that we put into the takeprofit )

( " Volty trailing stop settings ( if used ) " )

extern int vol.timeFrame = 240;

extern int Price = 0;

extern double Length = 2;

extern double Phase = 0;

Double extern bool = false ;

extern int AtrLength = 10;

extern double Kv = 4;

extern double MoneyRisk = 1;

extern int vol.barToUse = 1;

extern int Volty.initialStopLoss = 50;

I pray also creating an information panel that can be put on the bottom right of the main metatrater panel, where it appears the following information :

Balance $ = x

Equity $ = x

Margin $ = x

Free Margin $ = x

MarginLevel % = x

**************

Option = 1,2 or 3 .

For option1

TP = x

SL = x

TS = x

For option2

TP = x

SL = x

BreakEvenAt_Pips = x

BreakEvenLock_Pips = x

TS_ToBreakEven_Pips = x

To OPTION3

TP = x

Volty.initialStopLoss = x

The information panel I would like to be able to put in the bottom right corner.

*The Volty algorithm that I wanna include is the same that is used at “ EA Concentrated ”

Thank you for time folks and have a nice weekend

For what it facilitates the work I attach the EA I am using

Files:
 
Hermo:
Good morning everyone;

I beg you pardon my English.

Mr. mrtools or sr . mladen, could you build this EA for me please?.

I need a EA that could manage manual orders. Entry orders are triggered manually; however exits (profit and stop loss orders) are triggered by the strategy according to my parameters. I explain the variables. Pray what is not understood please feel free to ask.

variables:

Type broker = It automatically recognizes it .

EcnBroker extern bool = true ;

UseAutoMagic extern bool = true ;

extern int ManualMagic = 19283745 ;

Option 1 :

Opcion1_Starts = True or False

TakeProfit_Pips = x ( If we put 0 the operation will close when the price reaches the Trailing Stop or the stop order )

StopLoss_Pips = X

TrailingStop_Pips = X

Option 2 :

Opcion2_Starts = True or False

TakeProfit_Pips = X ( If we put 0 the operation will close when the price reaches Trailing StopLoss or the stop loss order )

StopLoss_Pips = x

MoveToBreakEvenAt_Pips = X ( When you have reached x pips profit , move stop to BreakEven ).

MoveToBreakEvenLock_Pips = X ( When you move the stop to BreakEven , the number of pips that we want to place the stop above or below our entry price )

TrailStopToBreakEven_Pips = x ( BreakEven Once reached , activates a trailstop from that point ). If this value equals 0 then this option will not apply.

Option 3:

Opcion3_Starts = True or False

TakeProfit_Pips = X ( if we put 0 the operation will close only by the Volty , if we put an amount , it could close by the Volty or get the number of pips that we put into the takeprofit )

( " Volty trailing stop settings ( if used ) " )

extern int vol.timeFrame = 240;

extern int Price = 0;

extern double Length = 2;

extern double Phase = 0;

Double extern bool = false ;

extern int AtrLength = 10;

extern double Kv = 4;

extern double MoneyRisk = 1;

extern int vol.barToUse = 1;

extern int Volty.initialStopLoss = 50;

I pray also creating an information panel that can be put on the bottom right of the main metatrater panel, where it appears the following information :

Balance $ = x

Equity $ = x

Margin $ = x

Free Margin $ = x

MarginLevel % = x

**************

Option = 1,2 or 3 .

For option1

TP = x

SL = x

TS = x

For option2

TP = x

SL = x

BreakEvenAt_Pips = x

BreakEvenLock_Pips = x

TS_ToBreakEven_Pips = x

To OPTION3

TP = x

Volty.initialStopLoss = x

The information panel I would like to be able to put in the bottom right corner.

*The Volty algorithm that I wanna include is the same that is used at “ EA Concentrated ”

Thank you for time folks and have a nice weekend

For what it facilitates the work I attach the EA I am using

Hermo

Some remarks, and one question.

Remarks : if it should manage manual orders then ecn option (for ecn brokers only the way how orders are opened is different - once when the order is opened, nothing is different), anything related to magic number (manual orders do not have magic numbers) are not needed.

A question : why did you attach the TrailMe EA? Do you wish that it is used as a basis for what you need?

 
mladen:
Hermo

Some remarks, and one question.

Remarks : if it should manage manual orders then ecn option (for ecn brokers only the way how orders are opened is different - once when the order is opened, nothing is different), anything related to magic number (manual orders do not have magic numbers) are not needed.

A question : why did you attach the TrailMe EA? Do you wish that it is used as a basis for what you need?

Good afternoon everyone;

I beg you pardon my English.

Hello mladen, thanks for your quick response.

Let me see if I can clarify you the conflicting points.

When I saytype broker I mean 4-5 digit broker. When we talk about ECN I used it because I see that it is being used by other EA's in which the system had to identify if where are talking about ECN or not ECN broker. So, why I inserted magic number it is because of the same reason; I have seen that it is being used in other EA's. So not trouble if you consider those options are of not use.

So about the question aboutthe TrailMe EA. I had attached it as an example but I will be happier if the code is being developed from head to tail by you because I trust you more than the code written by people that I don't know.

Thank you for your time and have great day

Best wishes

Hermo

 

Hello again,

I have a developer question: In an indicator like MACD in MT4, how can I get the levels? I want know when the line cross the unique level (specified by a parameter). How can I do it?

The function call will be:

iMACD(NULL,0,12,26,9,PRICE_CLOSE,MODE_MAIN,0)

But the result I don't know to what to compare with (I want compare it with a level!).

Also I want to know how to select a good indicator to do not repaint it! I mean: get a MACD, CCI, or another indicator that don't repaint the last value.

Thank you in advance!

Hermo

 
Hermo:
Hello again,

I have a developer question: In an indicator like MACD in MT4, how can I get the levels? I want know when the line cross the unique level (specified by a parameter). How can I do it?

The function call will be:

iMACD(NULL,0,12,26,9,PRICE_CLOSE,MODE_MAIN,0)

But the result I don't know to what to compare with (I want compare it with a level!).

Also I want to know how to select a good indicator to do not repaint it! I mean: get a MACD, CCI, or another indicator that don't repaint the last value.

Thank you in advance!

Hermo

Hermo

Of levels : MACD as such does not have levels, so you simply compare it to some value that you chose. But be careful with MACD because MACD values fro 1 minute charts are much, much smaller then the values on a monthly chart, for example (the rule of thumb for MACD is that the longer the time frame the bigger the values of MACD are)

As of repainting the last value : each and every indicator must recalculate the last value if you do not use open price (which can not be changed any more) in calculation. As long as the bar is niot closed, indicator must recalculate the changed values. It is not a matter of indicators but simply a matter of a price that changes

 

Thank you mladen for the clarification!

I said MACD but can be another one indicator...I mean, I just want get the levels values. How can do it with code?

About the TrailMe EA, I've been seeing the code but I think you can do it better, because as I said, I trust you more than other developers. Let me know if you have questions about please. I try to answer you asap.

Thank you again mladen. I appreciate a lot your work.

Hermo

mladen:
Hermo

Of levels : MACD as such does not have levels, so you simply compare it to some value that you chose. But be careful with MACD because MACD values fro 1 minute charts are much, much smaller then the values on a monthly chart, for example (the rule of thumb for MACD is that the longer the time frame the bigger the values of MACD are)

As of repainting the last value : each and every indicator must recalculate the last value if you do not use open price (which can not be changed any more) in calculation. As long as the bar is niot closed, indicator must recalculate the changed values. It is not a matter of indicators but simply a matter of a price that changes
 
Hermo:
Thank you mladen for the clarification!

I said MACD but can be another one indicator...I mean, I just want get the levels values. How can do it with code?

About the TrailMe EA, I've been seeing the code but I think you can do it better, because as I said, I trust you more than other developers. Let me know if you have questions about please. I try to answer you asap.

Thank you again mladen. I appreciate a lot your work.

Hermo

Hermo

If you are referring to the actual levels that you set on an indicator, there is no way how it can be found out from the code (metatrader 4 simply does not have some function that would be something like GetLevelValue() for the levels of some indicator, it can only set level values from the code)

 

Good evening mladen,

I don't know if you are building the EA that I've requested, but if it is, I would like that you add in the info panel, the lot size calculator, like this: Position Size Calculator, Forex Position Size Calculator . I saw the code in mql4, but it didn't work to me.

Sorry for my english and a big hug.

Hermo

Hermo:
Good morning everyone;

I beg you pardon my English.

Mr. mrtools or sr . mladen, could you build this EA for me please?.

I need a EA that could manage manual orders. Entry orders are triggered manually; however exits (profit and stop loss orders) are triggered by the strategy according to my parameters. I explain the variables. Pray what is not understood please feel free to ask.

variables:

Type broker = It automatically recognizes it .

EcnBroker extern bool = true ;

UseAutoMagic extern bool = true ;

extern int ManualMagic = 19283745 ;

Option 1 :

Opcion1_Starts = True or False

TakeProfit_Pips = x ( If we put 0 the operation will close when the price reaches the Trailing Stop or the stop order )

StopLoss_Pips = X

TrailingStop_Pips = X

Option 2 :

Opcion2_Starts = True or False

TakeProfit_Pips = X ( If we put 0 the operation will close when the price reaches Trailing StopLoss or the stop loss order )

StopLoss_Pips = x

MoveToBreakEvenAt_Pips = X ( When you have reached x pips profit , move stop to BreakEven ).

MoveToBreakEvenLock_Pips = X ( When you move the stop to BreakEven , the number of pips that we want to place the stop above or below our entry price )

TrailStopToBreakEven_Pips = x ( BreakEven Once reached , activates a trailstop from that point ). If this value equals 0 then this option will not apply.

Option 3:

Opcion3_Starts = True or False

TakeProfit_Pips = X ( if we put 0 the operation will close only by the Volty , if we put an amount , it could close by the Volty or get the number of pips that we put into the takeprofit )

( " Volty trailing stop settings ( if used ) " )

extern int vol.timeFrame = 240;

extern int Price = 0;

extern double Length = 2;

extern double Phase = 0;

Double extern bool = false ;

extern int AtrLength = 10;

extern double Kv = 4;

extern double MoneyRisk = 1;

extern int vol.barToUse = 1;

extern int Volty.initialStopLoss = 50;

I pray also creating an information panel that can be put on the bottom right of the main metatrater panel, where it appears the following information :

Balance $ = x

Equity $ = x

Margin $ = x

Free Margin $ = x

MarginLevel % = x

**************

Option = 1,2 or 3 .

For option1

TP = x

SL = x

TS = x

For option2

TP = x

SL = x

BreakEvenAt_Pips = x

BreakEvenLock_Pips = x

TS_ToBreakEven_Pips = x

To OPTION3

TP = x

Volty.initialStopLoss = x

The information panel I would like to be able to put in the bottom right corner.

*The Volty algorithm that I wanna include is the same that is used at “ EA Concentrated ”

Thank you for time folks and have a nice weekend

For what it facilitates the work I attach the EA I am using

 
Hermo:
Good evening mladen,

I don't know if you are building the EA that I've requested, but if it is, I would like that you add in the info panel, the lot size calculator, like this: Position Size Calculator, Forex Position Size Calculator . I saw the code in mql4, but it didn't work to me.

Sorry for my english and a big hug.

Hermo

Hermo

As far as lot calculator is concerned, did you see this post : https://www.mql5.com/en/forum/179807/page23

As far as the EA is concerned : did you check this EA as the basis for your idea https://www.mql5.com/en/forum/175843/page2

 
mladen:
Hermo

As far as lot calculator is concerned, did you see this post : https://www.mql5.com/en/forum/179807/page23

As far as the EA is concerned : did you check this EA as the basis for your idea https://www.mql5.com/en/forum/175843/page2

Hello mladen,

I appreciate the answer about the calculator. Is what I wanted it. Thank you.

About the EA, is not what I need. I didn't find the EA which the params that I need. I would like that, if you can, create the EA I've requested. I would appreciate it a lot.

Thank you again mladen!

Hermo

Reason: