L-I-V / MQL-Tools

42 stars 15 forks source link

IntelliSence doesn't work for MQL 4 after #include #19

Closed RenIfx closed 1 year ago

RenIfx commented 1 year ago

Hello, I started using your extension, I noticed that IntelliSense does not work for MQL4. after #include <C:\Users\User\AppData....... Doesn't offer references to functions and variables, and doesn't work for renaming variables and functions. But for MQL5 everything works. But does not work after editing MQL4 with #include....... Except for String, String does not work in MQL5 and MQL4. Are you planning to solve the issue with INCLUDE for MQL4. And decide with a string? Thank you so much for writing this extension.

L-I-V commented 1 year ago

Hi RenIfx, there is no difference between MQL4 and MQL5 in working with #include. Perhaps there is a problem with the path to the include files. 'MQL Tools' is not responsible for providing links to functions, variables, and renaming them. This is done by the 'C/C++' extension. Regarding IntelliSense for MQL4, variable, constant, and function descriptions for MQL4 will be added in the update. The 'String' problem will also be resolved in update.

RenIfx commented 1 year ago

Hi L-I-V. There are no problems with the path to include files. (the path is written in full <c: / / / / /mqh>). Because in MetaEditor 4 everything works fine. image

At the moment, I only solve this problem by commenting out #include: //#include <c: / / / / /mqh> image

Thanks a lot for your works.

L-I-V commented 1 year ago

Why do you specify the full path to the 'mqh' file <C:\Users\User\AppData\Roaming\MetaQuotes\Terminal\A80FB02CDD193132189CFCD69D34C571\MQL4\Include\Drow_ar.mqh>? If 'C:\Users\User\AppData\Roaming\MetaQuotes\Terminal\A80FB02CDD193132189CFCD69D34C571\MQL4' is your working directory, in the settings.json file which is in the .vscode folder specify the following settings: "C_Cpp.default.includePath": [ "${workspaceFolder}/**", "${workspaceFolder}/Include" ] After that you can use an abbreviated notation in your code: #include .

As for your problem, it is probably caused by an error of 'string', 'datetime' or 'color' types in the 'Drow_ar.mqh' file. The problem with the types will be partially solved in an update which will be released within a few days.

RenIfx commented 1 year ago

OK. Thank you I will wait for the update.