You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
spottygegasus:
your question gives reason to reorganize the header Transaction_5.mqh and to make it semantically cleaner.
Decisions between buy and sell are shifted into the client callback functions.
spottygegasus:
your question gives reason to reorganize the header Transaction_5.mqh and to make it semantically cleaner.
Decisions between buy and sell are shifted into the client callback functions.
Great, it looks more structured...
How would we catch OnModifyTPSL event?
What are the DEAL constants to watch out for?
Thanks & Regards...
How would we catch OnModifyTPSL event?
SInce the modification of SL/TP happens actively either by calling CTrade.PositionModify in an expert advisor or manually in the terminal by shifting thew SL/TP line in the chart I see no need to catch this event.
But if you want to catch this event you have to extend the signature of the event functions typedef_ed in Transaction_5.mqh to
Then in CTransaction.OnTradeTransaction look for
trans.type == TRADE_TRANSACTION_REQUEST
and
request.action == TRADE_ACTION_SLTP
What are the DEAL constants to watch out for?
For the deal constants please see the documentation MQL5 Reference/Constants, Enumerations and Structures/Trade Constants/Deal Properties
Sincerely
Matthias
Great, it looks more structured...
How would we catch OnModifyTPSL event?
What are the DEAL constants to watch out for?
Thanks & Regards...
I have found theTRADE_TRANSACTION_POSITION constant for catching the OnModifyTPSL event...
It works fine...
Regards...
I need to extend this to catch pending orders (STOPs & LIMITs)
I understand I need to play with the request as well...
But I think my knowledge of all the constants si minimal.... So I need help as to which request constants I should consentrate on....
Thanks & Regards,
Herman
How would we catch OnModifyTPSL event?
SInce the modification of SL/TP happens actively either by calling CTrade.PositionModify in an expert advisor or manually in the terminal by shifting thew SL/TP line in the chart I see no need to catch this event.
But if you want to catch this event you have to extend the signature of the event functions typedef_ed in Transaction_5.mqh to
Then in CTransaction.OnTradeTransaction look for
trans.type == TRADE_TRANSACTION_REQUEST
and
request.action == TRADE_ACTION_SLTP
What are the DEAL constants to watch out for?
For the deal constants please see the documentation MQL5 Reference/Constants, Enumerations and Structures/Trade Constants/Deal Properties
Sincerely
Matthias
You can use my class
Thanks!