FIELD GUIDE / 02

Install MT4 and MT5 source in the right place

MT4・MT5ソースの正しい導入

Choose the platform before copying files

コピーする前に対応環境を確認

.mq4 targets MT4; .mq5 targets MT5. A source-language file is different from .ex4/.ex5 compiled output. Renaming a file does not port its code.

.mq4はMT4、.mq5はMT5向けです。ソースファイルと実行形式の.ex4/.ex5は別で、ファイル名変更だけでは移植できません。

Use the terminal’s File → Open Data Folder. Indicators belong in MQL4/Indicators or MQL5/Indicators; EAs and trade managers in Experts; one-shot scripts in Scripts. Keep matching Include, Files and resource folders in the author’s intended structure.

ターミナルの「ファイル→データフォルダを開く」を使います。インジケーターはMQL4/IndicatorsまたはMQL5/Indicators、EA・取引管理はExperts、単発スクリプトはScriptsへ。Include・Filesなどの階層も原作者の指定を維持します。

Compile before enabling anything

有効化の前にコンパイルします

Use the matching MetaEditor and compile the main .mq4/.mq5 file. A missing .mqh dependency must be located in the documented package or the platform’s standard library. Do not substitute a binary from an unrelated site.

対応するMetaEditorで本体の.mq4/.mq5をコンパイルします。不足する.mqhは作者の配布物かターミナル標準ライブラリで確認し、無関係なサイトの実行ファイルで代用しないでください。

Check all compiler errors and warnings. A successful compile still does not prove that price units, volume steps, symbol selection, account mode, stop distance or order result handling are correct.

エラーと警告を確認します。コンパイル成功だけでは、価格単位・ロット刻み・対象銘柄・口座方式・ストップ距離・注文結果の処理が正しいことの証明にはなりません。

Keep permission and trade scope narrow

権限と操作対象を確認

An indicator normally calculates or displays values; an EA can open, modify or close positions. Trade managers can affect existing trades even when they do not generate entries. Check the exact source rather than trusting its name.

インジケーターは通常計算・表示を行いますが、EAは新規注文・変更・決済を行えます。取引管理EAは新規シグナルがなくても既存の注文へ作用します。名前だけでなく実際のソースを確認します。

Do not enable DLL imports or add WebRequest destinations without understanding the code and the documented need. Check symbol and magic-number filters, and test with no unrelated positions in the account.

コードと必要性を理解しないままDLLやWebRequestの接続先を許可しないでください。銘柄とマジックナンバーの絞り込みを確認し、無関係なポジションがない環境で試します。

Test failures, not only profitable history

良い過去成績だけでなく失敗時を確認

In Strategy Tester and a demo terminal, inspect insufficient history, disconnections, rejected orders, spread changes, restart behavior and accidental duplicate instances. A source library is not an installation or live-performance certification.

テスターとデモ端末で、履歴不足・切断・注文拒否・スプレッド変化・再起動・二重起動も確認します。ソースライブラリは、インストールや実運用の認証ではありません。

Primary references

一次資料