Download MetaTrader 5

Need Help in #property strict

To add comments, please log in or register
Arif Chowdhury
134
Arif Chowdhury  

When I tried to publish my EA it is said that - I have to add #property strict code in my EA

However, after I did that & when I tried to compile new 43 warnings & 6 errors came out from nowhere!!

Here are some example:

1st warning says: implicit conversion from "number" to "string" & it indicate "OrderTicket ()" & "GetLastError()" these are 2 warnings

2nd warning says: same as first but it indicates "ticket" this time

I am still very much noob in coding please I need help.

Mladen Rakic
61872
Mladen Rakic  
Arif Chowdhury:

When I tried to publish my EA it is said that - I have to add #property strict code in my EA

However, after I did that & when I tried to compile new 43 warnings & 6 errors came out from nowhere!!

Here are some example:

1st warning says: implicit conversion from "number" to "string" & it indicate "OrderTicket ()" & "GetLastError()" these are 2 warnings

2nd warning says: same as first but it indicates "ticket" this time

I am still very much noob in coding please I need help.

Make the code compatible with the requirements when using strict

After all : aren't you the one that made the code (since you are trying to sell it) - it should take no time that you change the code

Yohana Parmi
3088
Yohana Parmi  
Arif Chowdhury:

When I tried to publish my EA it is said that - I have to add #property strict code in my EA

However, after I did that & when I tried to compile new 43 warnings & 6 errors came out from nowhere!!

Here are some example:

1st warning says: implicit conversion from "number" to "string" & it indicate "OrderTicket ()" & "GetLastError()" these are 2 warnings

2nd warning says: same as first but it indicates "ticket" this time

I am still very much noob in coding please I need help.


Hi,

Did you tried converting the ticket number and/or OrderTicket() any numbers become string before use it on string requirement ?

... +IntegerToString(ticket,0)
To add comments, please log in or register