Here’s an enhancement to the process outlined in post #132, thanks to the ideas supplied by Euclid. It removes one step from the process. I have it working OK on Windows XP; I can’t test it on later Windows versions.
For programmers who wish to continue developing in build 509
[NOTE: MetaQuotes assure us that .ex4 files compiled on build 509 will run 'as is', and without any problems, on build 600.]
Proceed as follows:
1. Allow your br0ker to install MT4 build 600 (or later). Then exit MT4.
2. Find your MQL4 folder. If anybody is still running Win XP, it’s immediately under the ‘parent’ MT4 folder (where terminal.exe resides). For later Windows versions, it might be under the Applications Data or My Documents folders; this video will help you to locate it.
3. Unzip the attached ZIP file, ‘as is’, into this MQL4 folder.
4. Then:
--- Copy any indicators (like My_Indicator.mq4) that you want to compile in build 509 into the MQL4/Indicators folder.
--- Copy any scripts (like My_Script.mq4) that you want to compile in build 509 into the MQL4/Scripts folder.
--- Copy any EAs (like My_EA.mq4) that you want to compile in build 509 into the MQL4/Experts folder.
5. Restart MT4.
6. Run MetaEditor.exe from the MQL4 folder. (This is the build 509 version which you unzipped. If you try to call MetaEditor from MT4, you’ll get the build 600+ editor).
7. MetaEditor build 509’s Navigator (obtained by typing Ctrl-D) is now unusable, because it is looking for indicators/scripts/EAs in the wrong folder locations. So you need to type Ctrl-O (or menu option: File/Open) to load the indicators/scripts/EAs that you wish to edit and compile. Load these, and press F5 (or click the ‘Compile’ button) to compile them. (Since they were originally coded in build 509, and this is the build 509 compiler, there should be no problem). It seems that MetaEditor creates the EX4 file in the same folder from which the MQ4 file is loaded; hence the EX4s will be created in the folder that MT4 build 600+ expects to find them (hence you don’t have to move them, eliminating one step from the process outlined in post #132).
8. However, MT4 build 600+ will still be running the old EX4 file, hence you need to force a refresh. You can try running RefreshCrapT4 (attached to this post), but if — like me — you can’t get it to work, you’ll need to delete (de-attach) the indicator/EA from your chart(s), and re-attach it. Or if it’s a new indicator/EA, you’ll need to exit and restart MT4.
A possible problem with this approach is that (if I understand correctly) prior versions of MT4, upon startup, attempted to compile any MQ4 files that it found in the experts, indicators and scripts folders. If this likewise happens with MT4 build 600+, then you’ll possibly get dozens of errors as some build 509 code syntax is incompatible with the build 600 compiler. In which case you can always revert to the solution outlined in post #132.
Good luck,
David
For programmers who wish to continue developing in build 509
[NOTE: MetaQuotes assure us that .ex4 files compiled on build 509 will run 'as is', and without any problems, on build 600.]
Proceed as follows:
1. Allow your br0ker to install MT4 build 600 (or later). Then exit MT4.
2. Find your MQL4 folder. If anybody is still running Win XP, it’s immediately under the ‘parent’ MT4 folder (where terminal.exe resides). For later Windows versions, it might be under the Applications Data or My Documents folders; this video will help you to locate it.
3. Unzip the attached ZIP file, ‘as is’, into this MQL4 folder.
4. Then:
--- Copy any indicators (like My_Indicator.mq4) that you want to compile in build 509 into the MQL4/Indicators folder.
--- Copy any scripts (like My_Script.mq4) that you want to compile in build 509 into the MQL4/Scripts folder.
--- Copy any EAs (like My_EA.mq4) that you want to compile in build 509 into the MQL4/Experts folder.
5. Restart MT4.
6. Run MetaEditor.exe from the MQL4 folder. (This is the build 509 version which you unzipped. If you try to call MetaEditor from MT4, you’ll get the build 600+ editor).
7. MetaEditor build 509’s Navigator (obtained by typing Ctrl-D) is now unusable, because it is looking for indicators/scripts/EAs in the wrong folder locations. So you need to type Ctrl-O (or menu option: File/Open) to load the indicators/scripts/EAs that you wish to edit and compile. Load these, and press F5 (or click the ‘Compile’ button) to compile them. (Since they were originally coded in build 509, and this is the build 509 compiler, there should be no problem). It seems that MetaEditor creates the EX4 file in the same folder from which the MQ4 file is loaded; hence the EX4s will be created in the folder that MT4 build 600+ expects to find them (hence you don’t have to move them, eliminating one step from the process outlined in post #132).
8. However, MT4 build 600+ will still be running the old EX4 file, hence you need to force a refresh. You can try running RefreshCrapT4 (attached to this post), but if — like me — you can’t get it to work, you’ll need to delete (de-attach) the indicator/EA from your chart(s), and re-attach it. Or if it’s a new indicator/EA, you’ll need to exit and restart MT4.
A possible problem with this approach is that (if I understand correctly) prior versions of MT4, upon startup, attempted to compile any MQ4 files that it found in the experts, indicators and scripts folders. If this likewise happens with MT4 build 600+, then you’ll possibly get dozens of errors as some build 509 code syntax is incompatible with the build 600 compiler. In which case you can always revert to the solution outlined in post #132.
Good luck,
David
Attached File(s)
MetaEditor b509.zip
3.4 MB
|
1,395 downloads
RefreshCrapT4.zip
5 KB
|
721 downloads