Amir Yacoby:
Is it me or it still seems buggy?
I try to call CDealInfo::Ticket(const ulong ticket) from another class which has an instance variable of CDealInfo;
And get compilation error as stated.
In addition the compiler says: It can't decide which of two methods void Ticket(const ulong ticket) or void Ticket() - to choose from.
I am no expert by any means, but this
deal.Ticket(deal);
looks like a self reference to me. Can not be good.
Enrique Dangeroux:
you are right, but it is just a tipo. I edited it, should be deal.Ticket(ticket); // - still the error
I am no expert by any means, but this
looks like a self reference to me. Can not be good.
Amir Yacoby:
with pointer (CDealInfo *m_deal_info) it works fine, but why is that have to be a pointer?
with pointer (CDealInfo *m_deal_info) it works fine, but why is that have to be a pointer?
The following compiles fine for me in an MQL5 script.
#include <Trade\DealInfo.mqh> // <<<< Maybe this? class a { private: CDealInfo deal; public: void Delegate(); }; void a::Delegate() { ulong ticket=123; deal.Ticket(ticket); }
Maybe it's your #include statement. See what I used.
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
Is it me or it still seems buggy?
I try to call CDealInfo::Ticket(const ulong ticket) from another class which has an instance variable of CDealInfo;
And get compilation error as stated.
In addition the compiler says: It can't decide which of two methods void Ticket(const ulong ticket) or void Ticket() - to choose from.