This script allows you to assemble a zip-file of your MQL5-program with all dependencies automatically.
The dependencies are:
The script is based on a file scanner initially published in the article MQL Parsing by Means of MQL.
In order the script to work properly, user should make a simple yet important preparation step.
Create the file makelink.bat in the MQL5/Files folder with the following command and run it:
mklink /J MQL5 "..\..\MQL5\"
The file is provided (bound) with the script but bears txt-extension because bat-files are prohibited in MQL5 resources. You should copy makelink.txt to makelink.bat manually.
The command will create virtual pseudo-folder "MQL5" (so called file system junction point) inside real MQL5/Files folder. The pseudo-folder is actually a link/jump to the real MQL5 folder, accessible from the MQL5 sandbox. Do not mix up the real MQL5 folder and "MQL5" link (it's usually marked with a shortcut overlay on the icon).
The first occurence of "MQL5" in the abovementioned command is the pseudonym. You can choose another one at the expence of non-standard directory structure in the resulting ZIP-files (top-level folder in the ZIPs will have this name). The second occurence of "MQL5" in the command is the name of the real MQL5 folder - this part should be kept intact. Run the command in the MQL5/Files folder.
MQL5 sandbox access from MQL5/Files folder via junction point (symlink)
Important! Please note that the command creates the cyclic reference from subordinate folder MQL5/Files to upper level MQL5 folder. This may be danagerous if you use a software not smart enough to detect the recursion in the path. For example, loosely written backup programs, antiviruses or file managers can hang in an infinite loop and probably damage your operating system. Check your software for compatibility, include MQL5 into an exceptions list, or remove the link/jump just after you finished the packing task.
The pseudo-folder "MQL5" link is just a special file, you can remove it freely if you don't need it anymore, just make sure you're deleting the link inside MQL5/Files folder, not the real MQL5 folder in the terminal data path.
The zip will contain full structure of subfolders and files in your MQL5, which are referenced from your MQL5 program.
The script utilizes the ZIP-library published in the article Handling ZIP Archives in Pure MQL5, but with minor fixes and improvements.
Here is an example of log:
#property icon "mql5pack.png"
#resource "\\Files\\makelink.txt" as string __cmd1Folder
#resource "\\Files\\mql5pack.txt" as string __exceptionListExample
Files processed: 19
Source length: 152757
Packed file saved: MQL5/Scripts/mql5pack.mq5.zip
Files marked by '+' are added, marked by '-' are skipped as they are from the exceptions list.
The Rapid Doji EA is a fully functional MetaTrader 5 Expert Advisor that uses pending orders (one BUY and one STOP) around each Doji candlestick on the Daily (PERIOD_D1) time frame. This is a great introduction to how to build a simple, profitable EA. You can watch, step-by-step, how this EA was built via YouTube videos. See the link in the code for details.Smart Lines
Converts trendlines into horizontal lines.
NZD/USD (M30). Historical Data 18 September 2014 to 18 February 2020. Initial Deposit of US$500 acquires a Profit of US$1625.40 or Profit Return of 225% after 5½ Years. Result : Investment Gain $1,125.40 ROI 225.08% Annualized ROI 24.30% Investment Length 5.42 years MQ5 Software Program Attached. Visit these websites : https://352422.e-junkie.com/product/1645482 https://www.facebook.com/TheSoftwareSuite/MelBar EuroSwiss 1.85 Expert Advisor
The MelBar™ EuroSwiss 1.85x 2Y™ Expert Advisor is a specific purpose profit-scalping tool which success depends on your understanding of its underlying strategy and your ability to configure it. Backtest results using historical data from 6 February 2018 15:00 to 19 February 2020 00:00 for the EUR/CHF (M30) currency pair proves very highly profitable. Initial Deposit : US$500 Investment returns : US$1426.20 Net Profit : US$926.20 ROI : 185.24% Annualized ROI : 67.16% Investment Length : 2 years 14 days (2.04 years) Visit these websites : https://352422.e-junkie.com/product/1645482 https://www.facebook.com/TheSoftwareSuite/