PageSourceSearch

https://forexdec.com/assets/index-QD35xxT_.js

js forexdec.com collected 2026-10-10 01:21:12 UTC 1,740,432 bytes, 9,089 lines download raw bytes

vendor: 4,348 bytes, lines 1-9
1var vc=e=>{throw TypeError(e)};var ts=(e,t,r)=>t.has(e)||vc("Cannot "+r);var M=(e,t,r)=>(ts(e,t,"read from private field"),r?r.call(e):t.get(e)),$=(e,t,r)=>t.has(e)?vc("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),Q=(e,t,r,a)=>(ts(e,t,"write to private field"),a?a.call(e,r):t.set(e,r),r),we=(e,t,r)=>(ts(e,t,"access private method"),r);var sn=(e,t,r,a)=>({set _(i){Q(e,t,i,r)},get _(){return M(e,t,a)}});function Dv(e,t){for(var r=0;r<t.length;r++){const a=t[r];if(typeof a!="string"&&!Array.isArray(a)){for(const i in a)if(i!=="default"&&!(i in e)){const n=Object.getOwnPropertyDescriptor(a,i);n&&Object.defineProperty(e,i,n.get?n:{enumerable:!0,get:()=>a[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))a(i);new MutationObserver(i=>{for(const n of i)if(n.type==="childList")for(const s of n.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&a(s)}).observe(document,{childList:!0,subtree:!0});function r(i){const n={};return i.integrity&&(n.integrity=i.integrity),i.referrerPolicy&&(n.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?n.credentials="include":i.crossOrigin==="anonymous"?n.credentials="omit":n.credentials="same-origin",n}function a(i){if(i.ep)return;i.ep=!0;const n=r(i);fetch(i.href,n)}})();function Ua(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Tp={exports:{}},Eo={},Ep={exports:{}},_={};/**
2 * @license React
3 * react.production.min.js
4 *
5 * Copyright (c) Facebook, Inc. and its affiliates.
6 *
7 * This source code is licensed under the MIT license found in the
8 * LICENSE file in the root directory of this source tree.
9 */var Yi=Symbol.for("react.element"),Lv=Symbol.for("react.portal"),Nv=Symbol.for("react.fragment"),Ov=Symbol.for("react.strict_mode"),Fv=Symbol.for("react.profiler"),Qv=Symbol.for("react.provider"),Wv=Symbol.for("react.context"),zv=Symbol.for("react.forward_ref"),Bv=Symbol.for("react.suspense"),_v=Symbol.for("react.memo"),Uv=Symbol.for("react.lazy"),yc=Symbol.iterator;function Xv(e){return e===null||typeof e!="object"?null:(e=yc&&e[yc]||e["@@iterator"],typeof e=="function"?e:null)}var Mp={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Sp=Object.assign,Cp={};function Xa(e,t,r){this.props=e,this.context=t,this.refs=Cp,this.updater=r||Mp}Xa.prototype.isReactComponent={};Xa.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};Xa.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Ip(){}Ip.prototype=Xa.prototype;function Yl(e,t,r){this.props=e,this.context=t,this.refs=Cp,this.updater=r||Mp}var Jl=Yl.prototype=new Ip;Jl.constructor=Yl;Sp(Jl,Xa.prototype);Jl.isPureReactComponent=!0;var bc=Array.isArray,Rp=Object.prototype.hasOwnProperty,Zl={current:null},jp={key:!0,ref:!0,__self:!0,__source:!0};function qp(e,t,r){var a,i={},n=null,s=null;if(t!=null)for(a in t.ref!==void 0&&(s=t.ref),t.key!==void 0&&(n=""+t.key),t)Rp.call(t,a)&&!jp.hasOwnProperty(a)&&(i[a]=t[a]);var l=arguments.length-2;if(l===1)i.children=r;else if(1<l){for(var d=Array(l),c=0;c<l;c++)d[c]=arguments[c+2];i.children=d}if(e&&e.defaultProps)for(a in l=e.defaultProps,l)i[a]===void 0&&(i[a]=l[a]);return{$$typeof:Yi,type:e,key:n,ref:s,props:i,_owner:Zl.current}}function Vv(e,t){return{$$typeof:Yi,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function ed(e){return typeof e=="object"&&e!==null&&e.$$typeof===Yi}function Hv(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(r){return t[r]})}var wc=/\/+/g;function rs(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Hv(""+e.key):t.toString(36)}function jn(e,t,r,a,i){var n=typeof e;(n==="undefined"||n==="boolean")&&(e=null);var s=!1;if(e===null)s=!0;else switch(n){case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case Yi:case Lv:s=!0}
vendor: 4,539 bytes, lines 9-17
9}if(s)return s=e,i=i(s),e=a===""?"."+rs(s,0):a,bc(i)?(r="",e!=null&&(r=e.replace(wc,"$&/")+"/"),jn(i,t,r,"",function(c){return c})):i!=null&&(ed(i)&&(i=Vv(i,r+(!i.key||s&&s.key===i.key?"":(""+i.key).replace(wc,"$&/")+"/")+e)),t.push(i)),1;if(s=0,a=a===""?".":a+":",bc(e))for(var l=0;l<e.length;l++){n=e[l];var d=a+rs(n,l);s+=jn(n,t,r,d,i)}else if(d=Xv(e),typeof d=="function")for(e=d.call(e),l=0;!(n=e.next()).done;)n=n.value,d=a+rs(n,l++),s+=jn(n,t,r,d,i);else if(n==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return s}function ln(e,t,r){if(e==null)return e;var a=[],i=0;return jn(e,a,"","",function(n){return t.call(r,n,i++)}),a}function $v(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(r){(e._status===0||e._status===-1)&&(e._status=1,e._result=r)},function(r){(e._status===0||e._status===-1)&&(e._status=2,e._result=r)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var je={current:null},qn={transition:null},Gv={ReactCurrentDispatcher:je,ReactCurrentBatchConfig:qn,ReactCurrentOwner:Zl};function Pp(){throw Error("act(...) is not supported in production builds of React.")}_.Children={map:ln,forEach:function(e,t,r){ln(e,function(){t.apply(this,arguments)},r)},count:function(e){var t=0;return ln(e,function(){t++}),t},toArray:function(e){return ln(e,function(t){return t})||[]},only:function(e){if(!ed(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};_.Component=Xa;_.Fragment=Nv;_.Profiler=Fv;_.PureComponent=Yl;_.StrictMode=Ov;_.Suspense=Bv;_.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Gv;_.act=Pp;_.cloneElement=function(e,t,r){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var a=Sp({},e.props),i=e.key,n=e.ref,s=e._owner;if(t!=null){if(t.ref!==void 0&&(n=t.ref,s=Zl.current),t.key!==void 0&&(i=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(d in t)Rp.call(t,d)&&!jp.hasOwnProperty(d)&&(a[d]=t[d]===void 0&&l!==void 0?l[d]:t[d])}var d=arguments.length-2;if(d===1)a.children=r;else if(1<d){l=Array(d);for(var c=0;c<d;c++)l[c]=arguments[c+2];a.children=l}return{$$typeof:Yi,type:e.type,key:i,ref:n,props:a,_owner:s}};_.createContext=function(e){return e={$$typeof:Wv,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:Qv,_context:e},e.Consumer=e};_.createElement=qp;_.createFactory=function(e){var t=qp.bind(null,e);return t.type=e,t};_.createRef=function(){return{current:null}};_.forwardRef=function(e){return{$$typeof:zv,render:e}};_.isValidElement=ed;_.lazy=function(e){return{$$typeof:Uv,_payload:{_status:-1,_result:e},_init:$v}};_.memo=function(e,t){return{$$typeof:_v,type:e,compare:t===void 0?null:t}};_.startTransition=function(e){var t=qn.transition;qn.transition={};try{e()}finally{qn.transition=t}};_.unstable_act=Pp;_.useCallback=function(e,t){return je.current.useCallback(e,t)};_.useContext=function(e){return je.current.useContext(e)};_.useDebugValue=function(){};_.useDeferredValue=function(e){return je.current.useDeferredValue(e)};_.useEffect=function(e,t){return je.current.useEffect(e,t)};_.useId=function(){return je.current.useId()};_.useImperativeHandle=function(e,t,r){return je.current.useImperativeHandle(e,t,r)};_.useInsertionEffect=function(e,t){return je.current.useInsertionEffect(e,t)};_.useLayoutEffect=function(e,t){return je.current.useLayoutEffect(e,t)};_.useMemo=function(e,t){return je.current.useMemo(e,t)};_.useReducer=function(e,t,r){return je.current.useReducer(e,t,r)};_.useRef=function(e){return je.current.useRef(e)};_.useState=function(e){return je.current.useState(e)};_.useSyncExternalStore=function(e,t,r){return je.current.useSyncExternalStore(e,t,r)};_.useTransition=function(){return je.current.useTransition()};_.version="18.3.1";Ep.exports=_;var w=Ep.exports;const Xe=Ua(w),Kv=Dv({__proto__:null,default:Xe},[w]);/**
10 * @license React
11 * react-jsx-runtime.production.min.js
12 *
13 * Copyright (c) Facebook, Inc. and its affiliates.
14 *
15 * This source code is licensed under the MIT license found in the
16 * LICENSE file in the root directory of this source tree.
17 */var Yv=w,Jv=Symbol.for("react.element"),Zv=Symbol.for("react.fragment"),ey=Object.prototype.hasOwnProperty,ty=Yv.__SECRET_INT
vendor: 11,437 bytes, lines 17-34
17ERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,ry={key:!0,ref:!0,__self:!0,__source:!0};function Dp(e,t,r){var a,i={},n=null,s=null;r!==void 0&&(n=""+r),t.key!==void 0&&(n=""+t.key),t.ref!==void 0&&(s=t.ref);for(a in t)ey.call(t,a)&&!ry.hasOwnProperty(a)&&(i[a]=t[a]);if(e&&e.defaultProps)for(a in t=e.defaultProps,t)i[a]===void 0&&(i[a]=t[a]);return{$$typeof:Jv,type:e,key:n,ref:s,props:i,_owner:ty.current}}Eo.Fragment=Zv;Eo.jsx=Dp;Eo.jsxs=Dp;Tp.exports=Eo;var o=Tp.exports,Lp={exports:{}},Ye={},Np={exports:{}},Op={};/**
18 * @license React
19 * scheduler.production.min.js
20 *
21 * Copyright (c) Facebook, Inc. and its affiliates.
22 *
23 * This source code is licensed under the MIT license found in the
24 * LICENSE file in the root directory of this source tree.
25 */(function(e){function t(S,R){var N=S.length;S.push(R);e:for(;0<N;){var z=N-1>>>1,te=S[z];if(0<i(te,R))S[z]=R,S[N]=te,N=z;else break e}}function r(S){return S.length===0?null:S[0]}function a(S){if(S.length===0)return null;var R=S[0],N=S.pop();if(N!==R){S[0]=N;e:for(var z=0,te=S.length,st=te>>>1;z<st;){var Ze=2*(z+1)-1,Ya=S[Ze],Dt=Ze+1,qr=S[Dt];if(0>i(Ya,N))Dt<te&&0>i(qr,Ya)?(S[z]=qr,S[Dt]=N,z=Dt):(S[z]=Ya,S[Ze]=N,z=Ze);else if(Dt<te&&0>i(qr,N))S[z]=qr,S[Dt]=N,z=Dt;else break e}}return R}function i(S,R){var N=S.sortIndex-R.sortIndex;return N!==0?N:S.id-R.id}if(typeof performance=="object"&&typeof performance.now=="function"){var n=performance;e.unstable_now=function(){return n.now()}}else{var s=Date,l=s.now();e.unstable_now=function(){return s.now()-l}}var d=[],c=[],h=1,u=null,p=3,v=!1,b=!1,y=!1,x=typeof setTimeout=="function"?setTimeout:null,f=typeof clearTimeout=="function"?clearTimeout:null,m=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function g(S){for(var R=r(c);R!==null;){if(R.callback===null)a(c);else if(R.startTime<=S)a(c),R.sortIndex=R.expirationTime,t(d,R);else break;R=r(c)}}function k(S){if(y=!1,g(S),!b)if(r(d)!==null)b=!0,B(A);else{var R=r(c);R!==null&&V(k,R.startTime-S)}}function A(S,R){b=!1,y&&(y=!1,f(C),C=-1),v=!0;var N=p;try{for(g(R),u=r(d);u!==null&&(!(u.expirationTime>R)||S&&!W());){var z=u.callback;if(typeof z=="function"){u.callback=null,p=u.priorityLevel;var te=z(u.expirationTime<=R);R=e.unstable_now(),typeof te=="function"?u.callback=te:u===r(d)&&a(d),g(R)}else a(d);u=r(d)}if(u!==null)var st=!0;else{var Ze=r(c);Ze!==null&&V(k,Ze.startTime-R),st=!1}return st}finally{u=null,p=N,v=!1}}var T=!1,E=null,C=-1,D=5,q=-1;function W(){return!(e.unstable_now()-q<D)}function L(){if(E!==null){var S=e.unstable_now();q=S;var R=!0;try{R=E(!0,S)}finally{R?U():(T=!1,E=null)}}else T=!1}var U;if(typeof m=="function")U=function(){m(L)};else if(typeof MessageChannel<"u"){var P=new MessageChannel,H=P.port2;P.port1.onmessage=L,U=function(){H.postMessage(null)}}else U=function(){x(L,0)};function B(S){E=S,T||(T=!0,U())}function V(S,R){C=x(function(){S(e.unstable_now())},R)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(S){S.callback=null},e.unstable_continueExecution=function(){b||v||(b=!0,B(A))},e.unstable_forceFrameRate=function(S){0>S||125<S?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):D=0<S?Math.floor(1e3/S):5},e.unstable_getCurrentPriorityLevel=function(){return p},e.unstable_getFirstCallbackNode=function(){return r(d)},e.unstable_next=function(S){switch(p){case 1:case 2:case 3:var R=3;break;default:R=p}var N=p;p=R;try{return S()}finally{p=N}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(S,R){switch(S){case 1:case 2:case 3:case 4:case 5:break;default:S=3}var N=p;p=S;try{return R()}finally{p=N}},e.unstable_scheduleCallback=function(S,R,N){var z=e.unstable_now();switch(typeof N=="object"&&N!==null?(N=N.delay,N=typeof N=="number"&&0<N?z+N:z):N=z,S){case 1:var te=-1;break;case 2:te=250;break;case 5:te=1073741823;break;case 4:te=1e4;break;default:te=5e3}return te=N+te,S={id:h++,callback:R,priorityLevel:S,startTime:N,expirationTime:te,sortIndex:-1},N>z?(S.sortIndex=N,t(c,S),r(d)===null&&S===r(c)&&(y?(f(C),C=-1):y=!0,V(k,N-z))):(S.sortIndex=te,t(d,S),b||v||(b=!0,B(A))),S},e.unstable_shouldYield=W,e.unstable_wrapCallback=function(S){var R=p;return function(){var N=p;p=R;try{return S.apply(this,arguments)}finally{p=N}}}})(Op);Np.exports=Op;var ay=Np.exports;/**
26 * @license React
27 * react-dom.production.min.js
28 *
29 * Copyright (c) Facebook, Inc. and its affiliates.
30 *
31 * This source code is licensed under the MIT license found in the
32 * LICENSE file in the root directory of this source tree.
33 */var iy=w,Ke=ay;function I(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var Fp=new Set,Ei={};function Zr(e,t){Pa(e,t),Pa(e+"Capture",t)}function Pa(e,t){for(Ei[e]=t,e=0;e<t.length;e++)Fp.add(t[e])}var Xt=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Xs=Object.prototype.hasOwnProperty,ny=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,xc={},kc={};function oy(e){return Xs.call(kc,e)?!0:Xs.call(xc,e)?!1:ny.test(e)?kc[e]=!0:(xc[e]=!0,!1)}function sy(e,t,r,a){if(r!==null&&r.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return a?!1:r!==null?!r.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function ly(e,t,r,a){if(t===null||typeof t>"u"||sy(e,t,r,a))return!0;if(a)return!1;if(r!==null)switch(r.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function qe(e,t,r,a,i,n,s){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=a,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=n,this.removeEmptyString=s}var be={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){be[e]=new qe(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];be[t]=new qe(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){be[e]=new qe(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){be[e]=new qe(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){be[e]=new qe(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){be[e]=new qe(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){be[e]=new qe(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){be[e]=new qe(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){be[e]=new qe(e,5,!1,e.toLowerCase(),null,!1,!1)});var td=/[\-:]([a-z])/g;function rd(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(td,rd);be[t]=new qe(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(td,rd);be[t]=new qe(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(td,rd);be[t]=new qe(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){be[e]=new qe(e,1,!1,e.toLowerCase(),null,!1,!1)});be.xlinkHref=new qe("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){be[e]=new qe(e,1,!1,e.toLowerCase(),null,!0,!0)});function ad(e,t,r,a){var i=be.hasOwnProperty(t)?be[t]:null;(i!==null?i.type!==0:a||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(ly(t,r,i,a)&&(r=null),a||i===null?oy(t)&&(r===null?e.removeAttribute(t):e.setAttribute(t,""+r)):i.mustUseProperty?e[i.propertyName]=r===null?i.type===3?!1:"":r:(t=i.attributeName,a=i.attributeNamespace,r===null?e.removeAttribute(t):(i=i.type,r=i===3||i===4&&r===!0?"":""+r,a?e.setAttributeNS(a,t,r):e.setAttribute(t,r))))}var Yt=iy.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,dn=Symbol.for("react.element"),aa=Symbol.for("react.portal"),ia=Symbol.for("react.fragment"),id=Symbol.for("react.strict_mode"),Vs=Symbol.for("react.profiler"),Qp=Symbol.for("react.provider"),Wp=Symbol.for("react.context"),nd=Symbol.for("react.forward_ref"),Hs=Symbol.for("react.suspense"),$s=Symbol.for("react.suspense_list"),od=Symbol.for("react.memo"),rr=Symbol.for("react.lazy"),zp=Symbol.for("react.offscreen"),Ac=Symbol.iterator;function Za(e){return e===null||typeof e!="object"?null:(e=Ac&&e[Ac]||e["@@iterator"],typeof e=="function"?e:null)}var se=Object.assign,as;function hi(e){if(as===void 0)try{throw Error()}catch(r){var t=r.stack.trim().match(/\n( *(at )?)/);as=t&&t[1]||""}return`
34`+as+e}var is=!1;function ns(e,t){if(!e||is)return"";is=!0;var r=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(c){var a=c}Reflect.construct(e,[],t)}else{try{t.call()}catch(c){a=c}e.call(t.prototype)}else{try{throw Error()}catch(c){a=c}e()}}
vendor: 18,170 bytes, lines 34-37
34catch(c){if(c&&a&&typeof c.stack=="string"){for(var i=c.stack.split(`
35`),n=a.stack.split(`
36`),s=i.length-1,l=n.length-1;1<=s&&0<=l&&i[s]!==n[l];)l--;for(;1<=s&&0<=l;s--,l--)if(i[s]!==n[l]){if(s!==1||l!==1)do if(s--,l--,0>l||i[s]!==n[l]){var d=`
37`+i[s].replace(" at new "," at ");return e.displayName&&d.includes("<anonymous>")&&(d=d.replace("<anonymous>",e.displayName)),d}while(1<=s&&0<=l);break}}}finally{is=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?hi(e):""}function dy(e){switch(e.tag){case 5:return hi(e.type);case 16:return hi("Lazy");case 13:return hi("Suspense");case 19:return hi("SuspenseList");case 0:case 2:case 15:return e=ns(e.type,!1),e;case 11:return e=ns(e.type.render,!1),e;case 1:return e=ns(e.type,!0),e;default:return""}}function Gs(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case ia:return"Fragment";case aa:return"Portal";case Vs:return"Profiler";case id:return"StrictMode";case Hs:return"Suspense";case $s:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Wp:return(e.displayName||"Context")+".Consumer";case Qp:return(e._context.displayName||"Context")+".Provider";case nd:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case od:return t=e.displayName||null,t!==null?t:Gs(e.type)||"Memo";case rr:t=e._payload,e=e._init;try{return Gs(e(t))}catch{}}return null}function cy(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Gs(t);case 8:return t===id?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function kr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Bp(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function hy(e){var t=Bp(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),a=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var i=r.get,n=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(s){a=""+s,n.call(this,s)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return a},setValue:function(s){a=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function cn(e){e._valueTracker||(e._valueTracker=hy(e))}function _p(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),a="";return e&&(a=Bp(e)?e.checked?"true":"false":e.value),e=a,e!==r?(t.setValue(e),!0):!1}function Hn(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Ks(e,t){var r=t.checked;return se({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??e._wrapperState.initialChecked})}function Tc(e,t){var r=t.defaultValue==null?"":t.defaultValue,a=t.checked!=null?t.checked:t.defaultChecked;r=kr(t.value!=null?t.value:r),e._wrapperState={initialChecked:a,initialValue:r,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Up(e,t){t=t.checked,t!=null&&ad(e,"checked",t,!1)}function Ys(e,t){Up(e,t);var r=kr(t.value),a=t.type;if(r!=null)a==="number"?(r===0&&e.value===""||e.value!=r)&&(e.value=""+r):e.value!==""+r&&(e.value=""+r);else if(a==="submit"||a==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Js(e,t.type,r):t.hasOwnProperty("defaultValue")&&Js(e,t.type,kr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Ec(e,t,r){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var a=t.type;if(!(a!=="submit"&&a!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,r||t===e.value||(e.value=t),e.defaultValue=t}r=e.name,r!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,r!==""&&(e.name=r)}function Js(e,t,r){(t!=="number"||Hn(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var ui=Array.isArray;function fa(e,t,r,a){if(e=e.options,t){t={};for(var i=0;i<r.length;i++)t["$"+r[i]]=!0;for(r=0;r<e.length;r++)i=t.hasOwnProperty("$"+e[r].value),e[r].selected!==i&&(e[r].selected=i),i&&a&&(e[r].defaultSelected=!0)}else{for(r=""+kr(r),t=null,i=0;i<e.length;i++){if(e[i].value===r){e[i].selected=!0,a&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Zs(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(I(91));return se({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Mc(e,t){var r=t.value;if(r==null){if(r=t.children,t=t.defaultValue,r!=null){if(t!=null)throw Error(I(92));if(ui(r)){if(1<r.length)throw Error(I(93));r=r[0]}t=r}t==null&&(t=""),r=t}e._wrapperState={initialValue:kr(r)}}function Xp(e,t){var r=kr(t.value),a=kr(t.defaultValue);r!=null&&(r=""+r,r!==e.value&&(e.value=r),t.defaultValue==null&&e.defaultValue!==r&&(e.defaultValue=r)),a!=null&&(e.defaultValue=""+a)}function Sc(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function Vp(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function el(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?Vp(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var hn,Hp=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,r,a,i){MSApp.execUnsafeLocalFunction(function(){return e(t,r,a,i)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(hn=hn||document.createElement("div"),hn.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=hn.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Mi(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var fi={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},uy=["Webkit","ms","Moz","O"];Object.keys(fi).forEach(function(e){uy.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),fi[t]=fi[e]})});function $p(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||fi.hasOwnProperty(e)&&fi[e]?(""+t).trim():t+"px"}function Gp(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var a=r.indexOf("--")===0,i=$p(r,t[r],a);r==="float"&&(r="cssFloat"),a?e.setProperty(r,i):e[r]=i}}var py=se({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function tl(e,t){if(t){if(py[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(I(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(I(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(I(61))}if(t.style!=null&&typeof t.style!="object")throw Error(I(62))}}function rl(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var al=null;function sd(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var il=null,ga=null,va=null;function Cc(e){if(e=en(e)){if(typeof il!="function")throw Error(I(280));var t=e.stateNode;t&&(t=Ro(t),il(e.stateNode,e.type,t))}}function Kp(e){ga?va?va.push(e):va=[e]:ga=e}function Yp(){if(ga){var e=ga,t=va;if(va=ga=null,Cc(e),t)for(e=0;e<t.length;e++)Cc(t[e])}}function Jp(e,t){return e(t)}function Zp(){}var os=!1;function em(e,t,r){if(os)return e(t,r);os=!0;try{return Jp(e,t,r)}finally{os=!1,(ga!==null||va!==null)&&(Zp(),Yp())}}function Si(e,t){var r=e.stateNode;if(r===null)return null;var a=Ro(r);if(a===null)return null;r=a[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(a=!a.disabled)||(e=e.type,a=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!a;break e;default:e=!1}if(e)return null;if(r&&typeof r!="function")throw Error(I(231,t,typeof r));return r}var nl=!1;if(Xt)try{var ei={};Object.defineProperty(ei,"passive",{get:function(){nl=!0}}),window.addEventListener("test",ei,ei),window.removeEventListener("test",ei,ei)}catch{nl=!1}function my(e,t,r,a,i,n,s,l,d){var c=Array.prototype.slice.call(arguments,3);try{t.apply(r,c)}catch(h){this.onError(h)}}var gi=!1,$n=null,Gn=!1,ol=null,fy={onError:function(e){gi=!0,$n=e}};function gy(e,t,r,a,i,n,s,l,d){gi=!1,$n=null,my.apply(fy,arguments)}function vy(e,t,r,a,i,n,s,l,d){if(gy.apply(this,arguments),gi){if(gi){var c=$n;gi=!1,$n=null}else throw Error(I(198));Gn||(Gn=!0,ol=c)}}function ea(e){var t=e,r=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(r=t.return),e=t.return;while(e)}return t.tag===3?r:null}function tm(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function Ic(e){if(ea(e)!==e)throw Error(I(188))}function yy(e){var t=e.alternate;if(!t){if(t=ea(e),t===null)throw Error(I(188));return t!==e?null:e}for(var r=e,a=t;;){var i=r.return;if(i===null)break;var n=i.alternate;if(n===null){if(a=i.return,a!==null){r=a;continue}break}if(i.child===n.child){for(n=i.child;n;){if(n===r)return Ic(i),e;if(n===a)return Ic(i),t;n=n.sibling}throw Error(I(188))}if(r.return!==a.return)r=i,a=n;else{for(var s=!1,l=i.child;l;){if(l===r){s=!0,r=i,a=n;break}if(l===a){s=!0,a=i,r=n;break}l=l.sibling}if(!s){for(l=n.child;l;){if(l===r){s=!0,r=n,a=i;break}if(l===a){s=!0,a=n,r=i;break}l=l.sibling}if(!s)throw Error(I(189))}}if(r.alternate!==a)throw Error(I(190))}if(r.tag!==3)throw Error(I(188));return r.stateNode.current===r?e:t}function rm(e){return e=yy(e),e!==null?am(e):null}function am(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=am(e);if(t!==null)return t;e=e.sibling}return null}var im=Ke.unstable_scheduleCallback,Rc=Ke.unstable_cancelCallback,by=Ke.unstable_shouldYield,wy=Ke.unstable_requestPaint,ce=Ke.unstable_now,xy=Ke.unstable_getCurrentPriorityLevel,ld=Ke.unstable_ImmediatePriority,nm=Ke.unstable_UserBlockingPriority,Kn=Ke.unstable_NormalPriority,ky=Ke.unstable_LowPriority,om=Ke.unstable_IdlePriority,Mo=null,St=null;function Ay(e){if(St&&typeof St.onCommitFiberRoot=="function")try{St.onCommitFiberRoot(Mo,e,void 0,(e.current.flags&128)===128)}catch{}}var ft=Math.clz32?Math.clz32:My,Ty=Math.log,Ey=Math.LN2;function My(e){return e>>>=0,e===0?32:31-(Ty(e)/Ey|0)|0}var un=64,pn=4194304;function pi(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Yn(e,t){var r=e.pendingLanes;if(r===0)return 0;var a=0,i=e.suspendedLanes,n=e.pingedLanes,s=r&268435455;if(s!==0){var l=s&~i;l!==0?a=pi(l):(n&=s,n!==0&&(a=pi(n)))}else s=r&~i,s!==0?a=pi(s):n!==0&&(a=pi(n));if(a===0)return 0;if(t!==0&&t!==a&&!(t&i)&&(i=a&-a,n=t&-t,i>=n||i===16&&(n&4194240)!==0))return t;if(a&4&&(a|=r&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=a;0<t;)r=31-ft(t),i=1<<r,a|=e[r],t&=~i;return a}function Sy(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Cy(e,t){for(var r=e.suspendedLanes,a=e.pingedLanes,i=e.expirationTimes,n=e.pendingLanes;0<n;){var s=31-ft(n),l=1<<s,d=i[s];d===-1?(!(l&r)||l&a)&&(i[s]=Sy(l,t)):d<=t&&(e.expiredLanes|=l),n&=~l}}function sl(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function sm(){var e=un;return un<<=1,!(un&4194240)&&(un=64),e}function ss(e){for(var t=[],r=0;31>r;r++)t.push(e);return t}function Ji(e,t,r){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-ft(t),e[t]=r}function Iy(e,t){var r=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var a=e.eventTimes;for(e=e.expirationTimes;0<r;){var i=31-ft(r),n=1<<i;t[i]=0,a[i]=-1,e[i]=-1,r&=~n}}function dd(e,t){var r=e.entangledLanes|=t;for(e=e.entanglements;r;){var a=31-ft(r),i=1<<a;i&t|e[a]&t&&(e[a]|=t),r&=~i}}var G=0;function lm(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var dm,cd,cm,hm,um,ll=!1,mn=[],pr=null,mr=null,fr=null,Ci=new Map,Ii=new Map,ir=[],Ry="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function jc(e,t){switch(e){case"focusin":case"focusout":pr=null;break;case"dragenter":case"dragleave":mr=null;break;case"mouseover":case"mouseout":fr=null;break;case"pointerover":case"pointerout":Ci.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ii.delete(t.pointerId)}}function ti(e,t,r,a,i,n){return e===null||e.nativeEvent!==n?(e={blockedOn:t,domEventName:r,eventSystemFlags:a,nativeEvent:n,targetContainers:[i]},t!==null&&(t=en(t),t!==null&&cd(t)),e):(e.eventSystemFlags|=a,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function jy(e,t,r,a,i){switch(t){case"focusin":return pr=ti(pr,e,t,r,a,i),!0;case"dragenter":return mr=ti(mr,e,t,r,a,i),!0;case"mouseover":return fr=ti(fr,e,t,r,a,i),!0;case"pointerover":var n=i.pointerId;return Ci.set(n,ti(Ci.get(n)||null,e,t,r,a,i)),!0;case"gotpointercapture":return n=i.pointerId,Ii.set(n,ti(Ii.get(n)||null,e,t,r,a,i)),!0}return!1}function pm(e){var t=Nr(e.target);if(t!==null){var r=ea(t);if(r!==null){if(t=r.tag,t===13){if(t=tm(r),t!==null){e.blockedOn=t,um(e.priority,function(){cm(r)});return}}else if(t===3&&r.stateNode.current.memoizedState.isDehydrated){e.blockedOn=r.tag===3?r.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Pn(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var r=dl(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(r===null){r=e.nativeEvent;var a=new r.constructor(r.type,r);al=a,r.target.dispatchEvent(a),al=null}else return t=en(r),t!==null&&cd(t),e.blockedOn=r,!1;t.shift()}return!0}function qc(e,t,r){Pn(e)&&r.delete(t)}function qy(){ll=!1,pr!==null&&Pn(pr)&&(pr=null),mr!==null&&Pn(mr)&&(mr=null),fr!==null&&Pn(fr)&&(fr=null),Ci.forEach(qc),Ii.forEach(qc)}function ri(e,t){e.blockedOn===t&&(e.blockedOn=null,ll||(ll=!0,Ke.unstable_scheduleCallback(Ke.unstable_NormalPriority,qy)))}function Ri(e){function t(i){return ri(i,e)}if(0<mn.length){ri(mn[0],e);for(var r=1;r<mn.length;r++){var a=mn[r];a.blockedOn===e&&(a.blockedOn=null)}}for(pr!==null&&ri(pr,e),mr!==null&&ri(mr,e),fr!==null&&ri(fr,e),Ci.forEach(t),Ii.forEach(t),r=0;r<ir.length;r++)a=ir[r],a.blockedOn===e&&(a.blockedOn=null);for(;0<ir.length&&(r=ir[0],r.blockedOn===null);)pm(r),r.blockedOn===null&&ir.shift()}var ya=Yt.ReactCurrentBatchConfig,Jn=!0;function Py(e,t,r,a){var i=G,n=ya.transition;ya.transition=null;try{G=1,hd(e,t,r,a)}finally{G=i,ya.transition=n}}function Dy(e,t,r,a){var i=G,n=ya.transition;ya.transition=null;try{G=4,hd(e,t,r,a)}finally{G=i,ya.transition=n}}function hd(e,t,r,a){if(Jn){var i=dl(e,t,r,a);if(i===null)vs(e,t,a,Zn,r),jc(e,a);else if(jy(i,e,t,r,a))a.stopPropagation();else if(jc(e,a),t&4&&-1<Ry.indexOf(e)){for(;i!==null;){var n=en(i);if(n!==null&&dm(n),n=dl(e,t,r,a),n===null&&vs(e,t,a,Zn,r),n===i)break;i=n}i!==null&&a.stopPropagation()}else vs(e,t,a,null,r)}}var Zn=null;function dl(e,t,r,a){if(Zn=null,e=sd(a),e=Nr(e),e!==null)if(t=ea(e),t===null)e=null;else if(r=t.tag,r===13){if(e=tm(t),e!==null)return e;e=null}else if(r===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return Zn=e,null}
vendor: 10,163 bytes, line 37
37function mm(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(xy()){case ld:return 1;case nm:return 4;case Kn:case ky:return 16;case om:return 536870912;default:return 16}default:return 16}}var hr=null,ud=null,Dn=null;function fm(){if(Dn)return Dn;var e,t=ud,r=t.length,a,i="value"in hr?hr.value:hr.textContent,n=i.length;for(e=0;e<r&&t[e]===i[e];e++);var s=r-e;for(a=1;a<=s&&t[r-a]===i[n-a];a++);return Dn=i.slice(e,1<a?1-a:void 0)}function Ln(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function fn(){return!0}function Pc(){return!1}function Je(e){function t(r,a,i,n,s){this._reactName=r,this._targetInst=i,this.type=a,this.nativeEvent=n,this.target=s,this.currentTarget=null;for(var l in e)e.hasOwnProperty(l)&&(r=e[l],this[l]=r?r(n):n[l]);return this.isDefaultPrevented=(n.defaultPrevented!=null?n.defaultPrevented:n.returnValue===!1)?fn:Pc,this.isPropagationStopped=Pc,this}return se(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var r=this.nativeEvent;r&&(r.preventDefault?r.preventDefault():typeof r.returnValue!="unknown"&&(r.returnValue=!1),this.isDefaultPrevented=fn)},stopPropagation:function(){var r=this.nativeEvent;r&&(r.stopPropagation?r.stopPropagation():typeof r.cancelBubble!="unknown"&&(r.cancelBubble=!0),this.isPropagationStopped=fn)},persist:function(){},isPersistent:fn}),t}var Va={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},pd=Je(Va),Zi=se({},Va,{view:0,detail:0}),Ly=Je(Zi),ls,ds,ai,So=se({},Zi,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:md,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==ai&&(ai&&e.type==="mousemove"?(ls=e.screenX-ai.screenX,ds=e.screenY-ai.screenY):ds=ls=0,ai=e),ls)},movementY:function(e){return"movementY"in e?e.movementY:ds}}),Dc=Je(So),Ny=se({},So,{dataTransfer:0}),Oy=Je(Ny),Fy=se({},Zi,{relatedTarget:0}),cs=Je(Fy),Qy=se({},Va,{animationName:0,elapsedTime:0,pseudoElement:0}),Wy=Je(Qy),zy=se({},Va,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),By=Je(zy),_y=se({},Va,{data:0}),Lc=Je(_y),Uy={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Xy={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Vy={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Hy(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Vy[e])?!!t[e]:!1}function md(){return Hy}var $y=se({},Zi,{key:function(e){if(e.key){var t=Uy[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Ln(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Xy[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:md,charCode:function(e){return e.type==="keypress"?Ln(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Ln(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Gy=Je($y),Ky=se({},So,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Nc=Je(Ky),Yy=se({},Zi,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:md}),Jy=Je(Yy),Zy=se({},Va,{propertyName:0,elapsedTime:0,pseudoElement:0}),eb=Je(Zy),tb=se({},So,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),rb=Je(tb),ab=[9,13,27,32],fd=Xt&&"CompositionEvent"in window,vi=null;Xt&&"documentMode"in document&&(vi=document.documentMode);var ib=Xt&&"TextEvent"in window&&!vi,gm=Xt&&(!fd||vi&&8<vi&&11>=vi),Oc=" ",Fc=!1;function vm(e,t){switch(e){case"keyup":return ab.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function ym(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var na=!1;function nb(e,t){switch(e){case"compositionend":return ym(t);case"keypress":return t.which!==32?null:(Fc=!0,Oc);case"textInput":return e=t.data,e===Oc&&Fc?null:e;default:return null}}function ob(e,t){if(na)return e==="compositionend"||!fd&&vm(e,t)?(e=fm(),Dn=ud=hr=null,na=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return gm&&t.locale!=="ko"?null:t.data;default:return null}}var sb={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Qc(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!sb[e.type]:t==="textarea"}function bm(e,t,r,a){Kp(a),t=eo(t,"onChange"),0<t.length&&(r=new pd("onChange","change",null,r,a),e.push({event:r,listeners:t}))}var yi=null,ji=null;function lb(e){Rm(e,0)}function Co(e){var t=la(e);if(_p(t))return e}function db(e,t){if(e==="change")return t}var wm=!1;if(Xt){var hs;if(Xt){var us="oninput"in document;if(!us){var Wc=document.createElement("div");Wc.setAttribute("oninput","return;"),us=typeof Wc.oninput=="function"}hs=us}else hs=!1;wm=hs&&(!document.documentMode||9<document.documentMode)}function zc(){yi&&(yi.detachEvent("onpropertychange",xm),ji=yi=null)}function xm(e){if(e.propertyName==="value"&&Co(ji)){var t=[];bm(t,ji,e,sd(e)),em(lb,t)}}function cb(e,t,r){e==="focusin"?(zc(),yi=t,ji=r,yi.attachEvent("onpropertychange",xm)):e==="focusout"&&zc()}function hb(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Co(ji)}function ub(e,t){if(e==="click")return Co(t)}function pb(e,t){if(e==="input"||e==="change")return Co(t)}function mb(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var vt=typeof Object.is=="function"?Object.is:mb;function qi(e,t){if(vt(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var r=Object.keys(e),a=Object.keys(t);if(r.length!==a.length)return!1;for(a=0;a<r.length;a++){var i=r[a];if(!Xs.call(t,i)||!vt(e[i],t[i]))return!1}return!0}function Bc(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function _c(e,t){var r=Bc(e);e=0;for(var a;r;){if(r.nodeType===3){if(a=e+r.textContent.length,e<=t&&a>=t)return{node:r,offset:t-e};e=a}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=Bc(r)}}function km(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?km(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Am(){for(var e=window,t=Hn();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=Hn(e.document)}return t}function gd(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function fb(e){var t=Am(),r=e.focusedElem,a=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&km(r.ownerDocument.documentElement,r)){if(a!==null&&gd(r)){if(t=a.start,e=a.end,e===void 0&&(e=t),"selectionStart"in r)r.selectionStart=t,r.selectionEnd=Math.min(e,r.value.length);else if(e=(t=r.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=r.textContent.length,n=Math.min(a.start,i);a=a.end===void 0?n:Math.min(a.end,i),!e.extend&&n>a&&(i=a,a=n,n=i),i=_c(r,n);var s=_c(r,a);i&&s&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==s.node||e.focusOffset!==s.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),n>a?(e.addRange(t),e.extend(s.node,s.offset)):(t.setEnd(s.node,s.offset),e.addRange(t)))}}for(t=[],e=r;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r<t.length;r++)e=t[r],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var gb=Xt&&"documentMode"in document&&11>=document.documentMode,oa=null,cl=null,bi=null,hl=!1;function Uc(e,t,r){var a=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;
vendor: 4,738 bytes, line 37
37hl||oa==null||oa!==Hn(a)||(a=oa,"selectionStart"in a&&gd(a)?a={start:a.selectionStart,end:a.selectionEnd}:(a=(a.ownerDocument&&a.ownerDocument.defaultView||window).getSelection(),a={anchorNode:a.anchorNode,anchorOffset:a.anchorOffset,focusNode:a.focusNode,focusOffset:a.focusOffset}),bi&&qi(bi,a)||(bi=a,a=eo(cl,"onSelect"),0<a.length&&(t=new pd("onSelect","select",null,t,r),e.push({event:t,listeners:a}),t.target=oa)))}function gn(e,t){var r={};return r[e.toLowerCase()]=t.toLowerCase(),r["Webkit"+e]="webkit"+t,r["Moz"+e]="moz"+t,r}var sa={animationend:gn("Animation","AnimationEnd"),animationiteration:gn("Animation","AnimationIteration"),animationstart:gn("Animation","AnimationStart"),transitionend:gn("Transition","TransitionEnd")},ps={},Tm={};Xt&&(Tm=document.createElement("div").style,"AnimationEvent"in window||(delete sa.animationend.animation,delete sa.animationiteration.animation,delete sa.animationstart.animation),"TransitionEvent"in window||delete sa.transitionend.transition);function Io(e){if(ps[e])return ps[e];if(!sa[e])return e;var t=sa[e],r;for(r in t)if(t.hasOwnProperty(r)&&r in Tm)return ps[e]=t[r];return e}var Em=Io("animationend"),Mm=Io("animationiteration"),Sm=Io("animationstart"),Cm=Io("transitionend"),Im=new Map,Xc="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Sr(e,t){Im.set(e,t),Zr(t,[e])}for(var ms=0;ms<Xc.length;ms++){var fs=Xc[ms],vb=fs.toLowerCase(),yb=fs[0].toUpperCase()+fs.slice(1);Sr(vb,"on"+yb)}Sr(Em,"onAnimationEnd");Sr(Mm,"onAnimationIteration");Sr(Sm,"onAnimationStart");Sr("dblclick","onDoubleClick");Sr("focusin","onFocus");Sr("focusout","onBlur");Sr(Cm,"onTransitionEnd");Pa("onMouseEnter",["mouseout","mouseover"]);Pa("onMouseLeave",["mouseout","mouseover"]);Pa("onPointerEnter",["pointerout","pointerover"]);Pa("onPointerLeave",["pointerout","pointerover"]);Zr("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Zr("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Zr("onBeforeInput",["compositionend","keypress","textInput","paste"]);Zr("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Zr("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Zr("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var mi="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),bb=new Set("cancel close invalid load scroll toggle".split(" ").concat(mi));function Vc(e,t,r){var a=e.type||"unknown-event";e.currentTarget=r,vy(a,t,void 0,e),e.currentTarget=null}function Rm(e,t){t=(t&4)!==0;for(var r=0;r<e.length;r++){var a=e[r],i=a.event;a=a.listeners;e:{var n=void 0;if(t)for(var s=a.length-1;0<=s;s--){var l=a[s],d=l.instance,c=l.currentTarget;if(l=l.listener,d!==n&&i.isPropagationStopped())break e;Vc(i,l,c),n=d}else for(s=0;s<a.length;s++){if(l=a[s],d=l.instance,c=l.currentTarget,l=l.listener,d!==n&&i.isPropagationStopped())break e;Vc(i,l,c),n=d}}}if(Gn)throw e=ol,Gn=!1,ol=null,e}function J(e,t){var r=t[gl];r===void 0&&(r=t[gl]=new Set);var a=e+"__bubble";r.has(a)||(jm(t,e,2,!1),r.add(a))}function gs(e,t,r){var a=0;t&&(a|=4),jm(r,e,a,t)}var vn="_reactListening"+Math.random().toString(36).slice(2);function Pi(e){if(!e[vn]){e[vn]=!0,Fp.forEach(function(r){r!=="selectionchange"&&(bb.has(r)||gs(r,!1,e),gs(r,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[vn]||(t[vn]=!0,gs("selectionchange",!1,t))}}function jm(e,t,r,a){switch(mm(t)){case 1:var i=Py;break;case 4:i=Dy;break;default:i=hd}r=i.bind(null,t,r,e),i=void 0,!nl||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(i=!0),a?i!==void 0?e.addEventListener(t,r,{capture:!0,passive:i}):e.addEventListener(t,r,!0):i!==void 0?e.addEventListener(t,r,{passive:i}):e.addEventListener(t,r,!1)}function vs(e,t,r,a,i){var n=a;if(!(t&1)&&!(t&2)&&a!==null)e:for(;;){if(a===null)return;var s=a.tag;if(s===3||s===4){var l=a.stateNode.containerInfo;
vendor: 4,410 bytes, line 37
37if(l===i||l.nodeType===8&&l.parentNode===i)break;if(s===4)for(s=a.return;s!==null;){var d=s.tag;if((d===3||d===4)&&(d=s.stateNode.containerInfo,d===i||d.nodeType===8&&d.parentNode===i))return;s=s.return}for(;l!==null;){if(s=Nr(l),s===null)return;if(d=s.tag,d===5||d===6){a=n=s;continue e}l=l.parentNode}}a=a.return}em(function(){var c=n,h=sd(r),u=[];e:{var p=Im.get(e);if(p!==void 0){var v=pd,b=e;switch(e){case"keypress":if(Ln(r)===0)break e;case"keydown":case"keyup":v=Gy;break;case"focusin":b="focus",v=cs;break;case"focusout":b="blur",v=cs;break;case"beforeblur":case"afterblur":v=cs;break;case"click":if(r.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":v=Dc;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":v=Oy;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":v=Jy;break;case Em:case Mm:case Sm:v=Wy;break;case Cm:v=eb;break;case"scroll":v=Ly;break;case"wheel":v=rb;break;case"copy":case"cut":case"paste":v=By;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":v=Nc}var y=(t&4)!==0,x=!y&&e==="scroll",f=y?p!==null?p+"Capture":null:p;y=[];for(var m=c,g;m!==null;){g=m;var k=g.stateNode;if(g.tag===5&&k!==null&&(g=k,f!==null&&(k=Si(m,f),k!=null&&y.push(Di(m,k,g)))),x)break;m=m.return}0<y.length&&(p=new v(p,b,null,r,h),u.push({event:p,listeners:y}))}}if(!(t&7)){e:{if(p=e==="mouseover"||e==="pointerover",v=e==="mouseout"||e==="pointerout",p&&r!==al&&(b=r.relatedTarget||r.fromElement)&&(Nr(b)||b[Vt]))break e;if((v||p)&&(p=h.window===h?h:(p=h.ownerDocument)?p.defaultView||p.parentWindow:window,v?(b=r.relatedTarget||r.toElement,v=c,b=b?Nr(b):null,b!==null&&(x=ea(b),b!==x||b.tag!==5&&b.tag!==6)&&(b=null)):(v=null,b=c),v!==b)){if(y=Dc,k="onMouseLeave",f="onMouseEnter",m="mouse",(e==="pointerout"||e==="pointerover")&&(y=Nc,k="onPointerLeave",f="onPointerEnter",m="pointer"),x=v==null?p:la(v),g=b==null?p:la(b),p=new y(k,m+"leave",v,r,h),p.target=x,p.relatedTarget=g,k=null,Nr(h)===c&&(y=new y(f,m+"enter",b,r,h),y.target=g,y.relatedTarget=x,k=y),x=k,v&&b)t:{for(y=v,f=b,m=0,g=y;g;g=ta(g))m++;for(g=0,k=f;k;k=ta(k))g++;for(;0<m-g;)y=ta(y),m--;for(;0<g-m;)f=ta(f),g--;for(;m--;){if(y===f||f!==null&&y===f.alternate)break t;y=ta(y),f=ta(f)}y=null}else y=null;v!==null&&Hc(u,p,v,y,!1),b!==null&&x!==null&&Hc(u,x,b,y,!0)}}e:{if(p=c?la(c):window,v=p.nodeName&&p.nodeName.toLowerCase(),v==="select"||v==="input"&&p.type==="file")var A=db;else if(Qc(p))if(wm)A=pb;else{A=hb;var T=cb}else(v=p.nodeName)&&v.toLowerCase()==="input"&&(p.type==="checkbox"||p.type==="radio")&&(A=ub);if(A&&(A=A(e,c))){bm(u,A,r,h);break e}T&&T(e,p,c),e==="focusout"&&(T=p._wrapperState)&&T.controlled&&p.type==="number"&&Js(p,"number",p.value)}switch(T=c?la(c):window,e){case"focusin":(Qc(T)||T.contentEditable==="true")&&(oa=T,cl=c,bi=null);break;case"focusout":bi=cl=oa=null;break;case"mousedown":hl=!0;break;case"contextmenu":case"mouseup":case"dragend":hl=!1,Uc(u,r,h);break;case"selectionchange":if(gb)break;case"keydown":case"keyup":Uc(u,r,h)}var E;if(fd)e:{switch(e){case"compositionstart":var C="onCompositionStart";break e;case"compositionend":C="onCompositionEnd";break e;case"compositionupdate":C="onCompositionUpdate";break e}C=void 0}else na?vm(e,r)&&(C="onCompositionEnd"):e==="keydown"&&r.keyCode===229&&(C="onCompositionStart");C&&(gm&&r.locale!=="ko"&&(na||C!=="onCompositionStart"?C==="onCompositionEnd"&&na&&(E=fm()):(hr=h,ud="value"in hr?hr.value:hr.textContent,na=!0)),T=eo(c,C),0<T.length&&(C=new Lc(C,e,null,r,h),u.push({event:C,listeners:T}),E?C.data=E:(E=ym(r),E!==null&&(C.data=E)))),(E=ib?nb(e,r):ob(e,r))&&(c=eo(c,"onBeforeInput"),0<c.length&&(h=new Lc("onBeforeInput","beforeinput",null,r,h),u.push({event:h,listeners:c}),h.data=E))}Rm(u,t)})}function Di(e,t,r){return{instance:e,listener:t,currentTarget:r}}function eo(e,t){for(var r=t+"Capture",a=[];e!==null;){var i=e,n=i.stateNode;i.tag===5&&n!==null&&(i=n,n=Si(e,r),n!=null&&a.unshift(Di(e,n,i)),n=Si(e,t),n!=null&&a.push(Di(e,n,i))),e=e.return}return a}function ta(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Hc(e,t,r,a,i){for(var n=t._reactName,s=[];r!==null&&r!==a;){var l=r,d=l.alternate,c=l.stateNode;
vendor: 5,689 bytes, lines 37-38
37if(d!==null&&d===a)break;l.tag===5&&c!==null&&(l=c,i?(d=Si(r,n),d!=null&&s.unshift(Di(r,d,l))):i||(d=Si(r,n),d!=null&&s.push(Di(r,d,l)))),r=r.return}s.length!==0&&e.push({event:t,listeners:s})}var wb=/\r\n?/g,xb=/\u0000|\uFFFD/g;function $c(e){return(typeof e=="string"?e:""+e).replace(wb,`
38`).replace(xb,"")}function yn(e,t,r){if(t=$c(t),$c(e)!==t&&r)throw Error(I(425))}function to(){}var ul=null,pl=null;function ml(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var fl=typeof setTimeout=="function"?setTimeout:void 0,kb=typeof clearTimeout=="function"?clearTimeout:void 0,Gc=typeof Promise=="function"?Promise:void 0,Ab=typeof queueMicrotask=="function"?queueMicrotask:typeof Gc<"u"?function(e){return Gc.resolve(null).then(e).catch(Tb)}:fl;function Tb(e){setTimeout(function(){throw e})}function ys(e,t){var r=t,a=0;do{var i=r.nextSibling;if(e.removeChild(r),i&&i.nodeType===8)if(r=i.data,r==="/$"){if(a===0){e.removeChild(i),Ri(t);return}a--}else r!=="$"&&r!=="$?"&&r!=="$!"||a++;r=i}while(r);Ri(t)}function gr(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function Kc(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="$"||r==="$!"||r==="$?"){if(t===0)return e;t--}else r==="/$"&&t++}e=e.previousSibling}return null}var Ha=Math.random().toString(36).slice(2),Mt="__reactFiber$"+Ha,Li="__reactProps$"+Ha,Vt="__reactContainer$"+Ha,gl="__reactEvents$"+Ha,Eb="__reactListeners$"+Ha,Mb="__reactHandles$"+Ha;function Nr(e){var t=e[Mt];if(t)return t;for(var r=e.parentNode;r;){if(t=r[Vt]||r[Mt]){if(r=t.alternate,t.child!==null||r!==null&&r.child!==null)for(e=Kc(e);e!==null;){if(r=e[Mt])return r;e=Kc(e)}return t}e=r,r=e.parentNode}return null}function en(e){return e=e[Mt]||e[Vt],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function la(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(I(33))}function Ro(e){return e[Li]||null}var vl=[],da=-1;function Cr(e){return{current:e}}function ee(e){0>da||(e.current=vl[da],vl[da]=null,da--)}function K(e,t){da++,vl[da]=e.current,e.current=t}var Ar={},Ee=Cr(Ar),Fe=Cr(!1),Vr=Ar;function Da(e,t){var r=e.type.contextTypes;if(!r)return Ar;var a=e.stateNode;if(a&&a.__reactInternalMemoizedUnmaskedChildContext===t)return a.__reactInternalMemoizedMaskedChildContext;var i={},n;for(n in r)i[n]=t[n];return a&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Qe(e){return e=e.childContextTypes,e!=null}function ro(){ee(Fe),ee(Ee)}function Yc(e,t,r){if(Ee.current!==Ar)throw Error(I(168));K(Ee,t),K(Fe,r)}function qm(e,t,r){var a=e.stateNode;if(t=t.childContextTypes,typeof a.getChildContext!="function")return r;a=a.getChildContext();for(var i in a)if(!(i in t))throw Error(I(108,cy(e)||"Unknown",i));return se({},r,a)}function ao(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Ar,Vr=Ee.current,K(Ee,e),K(Fe,Fe.current),!0}function Jc(e,t,r){var a=e.stateNode;if(!a)throw Error(I(169));r?(e=qm(e,t,Vr),a.__reactInternalMemoizedMergedChildContext=e,ee(Fe),ee(Ee),K(Ee,e)):ee(Fe),K(Fe,r)}var Wt=null,jo=!1,bs=!1;function Pm(e){Wt===null?Wt=[e]:Wt.push(e)}function Sb(e){jo=!0,Pm(e)}function Ir(){if(!bs&&Wt!==null){bs=!0;var e=0,t=G;try{var r=Wt;for(G=1;e<r.length;e++){var a=r[e];do a=a(!0);while(a!==null)}Wt=null,jo=!1}catch(i){throw Wt!==null&&(Wt=Wt.slice(e+1)),im(ld,Ir),i}finally{G=t,bs=!1}}return null}var ca=[],ha=0,io=null,no=0,tt=[],rt=0,Hr=null,Bt=1,_t="";function Pr(e,t){ca[ha++]=no,ca[ha++]=io,io=e,no=t}function Dm(e,t,r){tt[rt++]=Bt,tt[rt++]=_t,tt[rt++]=Hr,Hr=e;var a=Bt;e=_t;var i=32-ft(a)-1;a&=~(1<<i),r+=1;var n=32-ft(t)+i;if(30<n){var s=i-i%5;n=(a&(1<<s)-1).toString(32),a>>=s,i-=s,Bt=1<<32-ft(t)+i|r<<i|a,_t=n+e}else Bt=1<<n|r<<i|a,_t=e}function vd(e){e.return!==null&&(Pr(e,1),Dm(e,1,0))}function yd(e){for(;e===io;)io=ca[--ha],ca[ha]=null,no=ca[--ha],ca[ha]=null;for(;e===Hr;)Hr=tt[--rt],tt[rt]=null,_t=tt[--rt],tt[rt]=null,Bt=tt[--rt],tt[rt]=null}var $e=null,He=null,ie=!1,pt=null;function Lm(e,t){var r=at(5,null,null,0);r.elementType="DELETED",r.stateNode=t,r.return=e,t=e.deletions,t===null?(e.deletions=[r],e.flags|=16):t.push(r)}function Zc(e,t){switch(e.tag){case 5:var r=e.type;return t=t.nodeType!==1||r.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,$e=e,He=gr(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,$e=e,He=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(r=Hr!==null?{id:Bt,overflow:_t}:null,e.memoizedState={dehydrated:t,treeContext:r,retryLane:1073741824},r=at(18,null,null,0),r.stateNode=t,r.return=e,e.child=r,$e=e,He=null,!0):!1;default:return!1}}function yl(e){return(e.mode&1)!==0&&(e.flags&128)===0}function bl(e){if(ie){var t=He;if(t){var r=t;if(!Zc(e,t)){if(yl(e))throw Error(I(418));t=gr(r.nextSibling);var a=$e;t&&Zc(e,t)?Lm(a,r):(e.flags=e.flags&-4097|2,ie=!1,$e=e)}}else{if(yl(e))throw Error(I(418));e.flags=e.flags&-4097|2,ie=!1,$e=e}}}function eh(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;$e=e}function bn(e){if(e!==$e)return!1;if(!ie)return eh(e),ie=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!ml(e.type,e.memoizedProps)),t&&(t=He)){if(yl(e))throw Nm(),Error(I(418));for(;t;)Lm(e,t),t=gr(t.nextSibling)}if(eh(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(I(317)
vendor: 12,501 bytes, line 38
38);e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="/$"){if(t===0){He=gr(e.nextSibling);break e}t--}else r!=="$"&&r!=="$!"&&r!=="$?"||t++}e=e.nextSibling}He=null}}else He=$e?gr(e.stateNode.nextSibling):null;return!0}function Nm(){for(var e=He;e;)e=gr(e.nextSibling)}function La(){He=$e=null,ie=!1}function bd(e){pt===null?pt=[e]:pt.push(e)}var Cb=Yt.ReactCurrentBatchConfig;function ii(e,t,r){if(e=r.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(r._owner){if(r=r._owner,r){if(r.tag!==1)throw Error(I(309));var a=r.stateNode}if(!a)throw Error(I(147,e));var i=a,n=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===n?t.ref:(t=function(s){var l=i.refs;s===null?delete l[n]:l[n]=s},t._stringRef=n,t)}if(typeof e!="string")throw Error(I(284));if(!r._owner)throw Error(I(290,e))}return e}function wn(e,t){throw e=Object.prototype.toString.call(t),Error(I(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function th(e){var t=e._init;return t(e._payload)}function Om(e){function t(f,m){if(e){var g=f.deletions;g===null?(f.deletions=[m],f.flags|=16):g.push(m)}}function r(f,m){if(!e)return null;for(;m!==null;)t(f,m),m=m.sibling;return null}function a(f,m){for(f=new Map;m!==null;)m.key!==null?f.set(m.key,m):f.set(m.index,m),m=m.sibling;return f}function i(f,m){return f=wr(f,m),f.index=0,f.sibling=null,f}function n(f,m,g){return f.index=g,e?(g=f.alternate,g!==null?(g=g.index,g<m?(f.flags|=2,m):g):(f.flags|=2,m)):(f.flags|=1048576,m)}function s(f){return e&&f.alternate===null&&(f.flags|=2),f}function l(f,m,g,k){return m===null||m.tag!==6?(m=Ms(g,f.mode,k),m.return=f,m):(m=i(m,g),m.return=f,m)}function d(f,m,g,k){var A=g.type;return A===ia?h(f,m,g.props.children,k,g.key):m!==null&&(m.elementType===A||typeof A=="object"&&A!==null&&A.$$typeof===rr&&th(A)===m.type)?(k=i(m,g.props),k.ref=ii(f,m,g),k.return=f,k):(k=Bn(g.type,g.key,g.props,null,f.mode,k),k.ref=ii(f,m,g),k.return=f,k)}function c(f,m,g,k){return m===null||m.tag!==4||m.stateNode.containerInfo!==g.containerInfo||m.stateNode.implementation!==g.implementation?(m=Ss(g,f.mode,k),m.return=f,m):(m=i(m,g.children||[]),m.return=f,m)}function h(f,m,g,k,A){return m===null||m.tag!==7?(m=Ur(g,f.mode,k,A),m.return=f,m):(m=i(m,g),m.return=f,m)}function u(f,m,g){if(typeof m=="string"&&m!==""||typeof m=="number")return m=Ms(""+m,f.mode,g),m.return=f,m;if(typeof m=="object"&&m!==null){switch(m.$$typeof){case dn:return g=Bn(m.type,m.key,m.props,null,f.mode,g),g.ref=ii(f,null,m),g.return=f,g;case aa:return m=Ss(m,f.mode,g),m.return=f,m;case rr:var k=m._init;return u(f,k(m._payload),g)}if(ui(m)||Za(m))return m=Ur(m,f.mode,g,null),m.return=f,m;wn(f,m)}return null}function p(f,m,g,k){var A=m!==null?m.key:null;if(typeof g=="string"&&g!==""||typeof g=="number")return A!==null?null:l(f,m,""+g,k);if(typeof g=="object"&&g!==null){switch(g.$$typeof){case dn:return g.key===A?d(f,m,g,k):null;case aa:return g.key===A?c(f,m,g,k):null;case rr:return A=g._init,p(f,m,A(g._payload),k)}if(ui(g)||Za(g))return A!==null?null:h(f,m,g,k,null);wn(f,g)}return null}function v(f,m,g,k,A){if(typeof k=="string"&&k!==""||typeof k=="number")return f=f.get(g)||null,l(m,f,""+k,A);if(typeof k=="object"&&k!==null){switch(k.$$typeof){case dn:return f=f.get(k.key===null?g:k.key)||null,d(m,f,k,A);case aa:return f=f.get(k.key===null?g:k.key)||null,c(m,f,k,A);case rr:var T=k._init;return v(f,m,g,T(k._payload),A)}if(ui(k)||Za(k))return f=f.get(g)||null,h(m,f,k,A,null);wn(m,k)}return null}function b(f,m,g,k){for(var A=null,T=null,E=m,C=m=0,D=null;E!==null&&C<g.length;C++){E.index>C?(D=E,E=null):D=E.sibling;var q=p(f,E,g[C],k);if(q===null){E===null&&(E=D);break}e&&E&&q.alternate===null&&t(f,E),m=n(q,m,C),T===null?A=q:T.sibling=q,T=q,E=D}if(C===g.length)return r(f,E),ie&&Pr(f,C),A;if(E===null){for(;C<g.length;C++)E=u(f,g[C],k),E!==null&&(m=n(E,m,C),T===null?A=E:T.sibling=E,T=E);return ie&&Pr(f,C),A}for(E=a(f,E);C<g.length;C++)D=v(E,f,C,g[C],k),D!==null&&(e&&D.alternate!==null&&E.delete(D.key===null?C:D.key),m=n(D,m,C),T===null?A=D:T.sibling=D,T=D);return e&&E.forEach(function(W){return t(f,W)}),ie&&Pr(f,C),A}function y(f,m,g,k){var A=Za(g);if(typeof A!="function")throw Error(I(150));if(g=A.call(g),g==null)throw Error(I(151));for(var T=A=null,E=m,C=m=0,D=null,q=g.next();E!==null&&!q.done;C++,q=g.next()){E.index>C?(D=E,E=null):D=E.sibling;var W=p(f,E,q.value,k);if(W===null){E===null&&(E=D);break}e&&E&&W.alternate===null&&t(f,E),m=n(W,m,C),T===null?A=W:T.sibling=W,T=W,E=D}if(q.done)return r(f,E),ie&&Pr(f,C),A;if(E===null){for(;!q.done;C++,q=g.next())q=u(f,q.value,k),q!==null&&(m=n(q,m,C),T===null?A=q:T.sibling=q,T=q);return ie&&Pr(f,C),A}for(E=a(f,E);!q.done;C++,q=g.next())q=v(E,f,C,q.value,k),q!==null&&(e&&q.alternate!==null&&E.delete(q.key===null?C:q.key),m=n(q,m,C),T===null?A=q:T.sibling=q,T=q);return e&&E.forEach(function(L){return t(f,L)}),ie&&Pr(f,C),A}function x(f,m,g,k){if(typeof g=="object"&&g!==null&&g.type===ia&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case dn:e:{for(var A=g.key,T=m;T!==null;){if(T.key===A){if(A=g.type,A===ia){if(T.tag===7){r(f,T.sibling),m=i(T,g.props.children),m.return=f,f=m;break e}}else if(T.elementType===A||typeof A=="object"&&A!==null&&A.$$typeof===rr&&th(A)===T.type){r(f,T.sibling),m=i(T,g.props),m.ref=ii(f,T,g),m.return=f,f=m;break e}r(f,T);break}else t(f,T);T=T.sibling}g.type===ia?(m=Ur(g.props.children,f.mode,k,g.key),m.return=f,f=m):(k=Bn(g.type,g.key,g.props,null,f.mode,k),k.ref=ii(f,m,g),k.return=f,f=k)}return s(f);case aa:e:{for(T=g.key;m!==null;){if(m.key===T)if(m.tag===4&&m.stateNode.containerInfo===g.containerInfo&&m.stateNode.implementation===g.implementation){r(f,m.sibling),m=i(m,g.children||[]),m.return=f,f=m;break e}else{r(f,m);break}else t(f,m);m=m.sibling}m=Ss(g,f.mode,k),m.return=f,f=m}return s(f);case rr:return T=g._init,x(f,m,T(g._payload),k)}if(ui(g))return b(f,m,g,k);if(Za(g))return y(f,m,g,k);wn(f,g)}return typeof g=="string"&&g!==""||typeof g=="number"?(g=""+g,m!==null&&m.tag===6?(r(f,m.sibling),m=i(m,g),m.return=f,f=m):(r(f,m),m=Ms(g,f.mode,k),m.return=f,f=m),s(f)):r(f,m)}return x}var Na=Om(!0),Fm=Om(!1),oo=Cr(null),so=null,ua=null,wd=null;function xd(){wd=ua=so=null}function kd(e){var t=oo.current;ee(oo),e._currentValue=t}function wl(e,t,r){for(;e!==null;){var a=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,a!==null&&(a.childLanes|=t)):a!==null&&(a.childLanes&t)!==t&&(a.childLanes|=t),e===r)break;e=e.return}}function ba(e,t){so=e,wd=ua=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Oe=!0),e.firstContext=null)}function nt(e){var t=e._currentValue;if(wd!==e)if(e={context:e,memoizedValue:t,next:null},ua===null){if(so===null)throw Error(I(308));ua=e,so.dependencies={lanes:0,firstContext:e}}else ua=ua.next=e;return t}var Or=null;function Ad(e){Or===null?Or=[e]:Or.push(e)}function Qm(e,t,r,a){var i=t.interleaved;return i===null?(r.next=r,Ad(t)):(r.next=i.next,i.next=r),t.interleaved=r,Ht(e,a)}function Ht(e,t){e.lanes|=t;var r=e.alternate;for(r!==null&&(r.lanes|=t),r=e,e=e.return;e!==null;)e.childLanes|=t,r=e.alternate,r!==null&&(r.childLanes|=t),r=e,e=e.return;return r.tag===3?r.stateNode:null}var ar=!1;function Td(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Wm(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Ut(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function vr(e,t,r){var a=e.updateQueue;if(a===null)return null;if(a=a.shared,X&2){var i=a.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),a.pending=t,Ht(e,r)}return i=a.interleaved,i===null?(t.next=t,Ad(a)):(t.next=i.next,i.next=t),a.interleaved=t,Ht(e,r)}function Nn(e,t,r){if(t=t.updateQueue,t!==null&&(t=t.shared,(r&4194240)!==0)){var a=t.lanes;a&=e.pendingLanes,r|=a,t.lanes=r,dd(e,r)}}function rh(e,t){var r=e.updateQueue,a=e.alternate;if(a!==null&&(a=a.updateQueue,r===a)){var i=null,n=null;if(r=r.firstBaseUpdate,r!==null){do{var s={eventTime:r.eventTime,lane:r.lane,tag:r.tag,payload:r.payload,callback:r.callback,next:null};n===null?i=n=s:n=n.next=s,r=r.next}while(r!==null);n===null?i=n=t:n=n.next=t}else i=n=t;r={baseState:a.baseState,firstBaseUpdate:i,lastBaseUpdate:n,shared:a.shared,effects:a.effects},e.updateQueue=r;return}e=r.lastBaseUpdate,e===null?r.firstBaseUpdate=t:e.next=t,r.lastBaseUpdate=t}function lo(e,t,r,a){var i=e.updateQueue;ar=!1;var n=i.firstBaseUpdate,s=i.lastBaseUpdate,l=i.shared.pending;if(l!==null){i.shared.pending=null;var d=l,c=d.next;d.next=null,s===null?n=c:s.next=c,s=d;var h=e.alternate;h!==null&&(h=h.updateQueue,l=h.lastBaseUpdate,l!==s&&(l===null?h.firstBaseUpdate=c:l.next=c,h.lastBaseUpdate=d))}if(n!==null){var u=i.baseState;s=0,h=c=d=null,l=n;do{var p=l.lane,v=l.eventTime;if((a&p)===p){h!==null&&(h=h.next={eventTime:v,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});e:{var b=e,y=l;switch(p=t,v=r,y.tag){case 1:if(b=y.payload,typeof b=="function"){u=b.call(v,u,p);break e}u=b;break e;case 3:b.flags=b.flags&-65537|128;case 0:if(b=y.payload,p=typeof b=="function"?b.call(v,u,p):b,p==null)break e;u=se({},u,p);break e;case 2:ar=!0}}l.callback!==null&&l.lane!==0&&(e.flags|=64,p=i.effects,p===null?i.effects=[l]:p.push(l))}else v={eventTime:v,lane:p,tag:l.tag,payload:l.payload,callback:l.callback,next:null},h===null?(c=h=v,d=u):h=h.next=v,s|=p;if(l=l.next,l===null){if(l=i.shared.pending,l===null)break;p=l,l=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(!0);if(h===null&&(d=u),i.baseState=d,i.firstBaseUpdate=c,i.lastBaseUpdate=h,t=i.shared.interleaved,t!==null){i=t;do s|=i.lane,i=i.next;while(i!==t)}else n===null&&(i.shared.lanes=0);Gr|=s,e.lanes=s,e.memoizedState=u}}function ah(e,t,r){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var a=e[t],i=a.callback;if(i!==null){if(a.callback=null,a=r,typeof i!="function")throw Error(I(191,i));i.call(a)}}}var tn={},Ct=Cr(tn),Ni=Cr(tn),Oi=Cr(tn);function Fr(e){if(e===tn)throw Error(I(174));return e}function Ed(e,t){switch(K(Oi,t),K(Ni,e),K(Ct,tn),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:el(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=el(t,e)}ee(Ct),K(Ct,t)}function Oa(){ee(Ct),ee(Ni),ee(Oi)}function zm(e){Fr(Oi.current);var t=Fr(Ct.current),r=el(t,e.type);t!==r&&(K(Ni,e),K(Ct,r))}function Md(e){Ni.current===e&&(ee(Ct),ee(Ni))}var ne=Cr(0);function co(e){for(var t=e;t!==null;){if(t.tag===13){var r=t.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||r.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var ws=[];function Sd(){for(var e=0;e<ws.length;e++)ws[e]._workInProgressVersionPrimary=null;ws.length=0}var On=Yt.ReactCurrentDispatcher,xs=Yt.ReactCurrentBatchConfig,$r=0,oe=null,ue=null,fe=null,ho=!1,wi=!1,Fi=0,Ib=0;function xe(){throw Error(I(321))}function Cd(e,t){if(t===null)return!1;for(var r=0;r<t.length&&r<e.length;r++)if(!vt(e[r],t[r]))return!1;return!0}function Id(e,t,r,a,i,n){if($r=n,oe=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,On.current=e===null||e.memoizedState===null?Pb:Db,e=r(a,i),wi){n=0;do{if(wi=!1,Fi=0,25<=n)throw Error(I(301));n+=1,fe=ue=null,t.updateQueue=null,On.current=Lb,e=r(a,i)}while(wi)}if(On.current=uo,t=ue!==null&&ue.next!==null,$r=0,fe=ue=oe=null,ho=!1,t)throw Error(I(300));return e}function Rd(){var e=Fi!==0;return Fi=0,e}function kt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return fe===null?oe.memoizedState=fe=e:fe=fe.next=e,fe}function ot(){if(ue===null){var e=oe.alternate;e=e!==null?e.memoizedState:null}else e=ue.next;var t=fe===null?oe.memoizedState:fe.next;if(t!==null)fe=t,ue=e;else{if(e===null)throw Error(I(310));ue=e,e={memoizedState:ue.memoizedState,baseState:ue.baseState,baseQueue:ue.baseQueue,queue:ue.queue,next:null},fe===null?oe.memoizedState=fe=e:fe=fe.next=e}return fe}function Qi(e,t){return typeof t=="function"?t(e):t}function ks(e){var t=ot(),r=t.queue;if(r===null)throw Error(I(311));r.lastRenderedReducer=e;
vendor: 5,685 bytes, line 38
38var a=ue,i=a.baseQueue,n=r.pending;if(n!==null){if(i!==null){var s=i.next;i.next=n.next,n.next=s}a.baseQueue=i=n,r.pending=null}if(i!==null){n=i.next,a=a.baseState;var l=s=null,d=null,c=n;do{var h=c.lane;if(($r&h)===h)d!==null&&(d=d.next={lane:0,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null}),a=c.hasEagerState?c.eagerState:e(a,c.action);else{var u={lane:h,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null};d===null?(l=d=u,s=a):d=d.next=u,oe.lanes|=h,Gr|=h}c=c.next}while(c!==null&&c!==n);d===null?s=a:d.next=l,vt(a,t.memoizedState)||(Oe=!0),t.memoizedState=a,t.baseState=s,t.baseQueue=d,r.lastRenderedState=a}if(e=r.interleaved,e!==null){i=e;do n=i.lane,oe.lanes|=n,Gr|=n,i=i.next;while(i!==e)}else i===null&&(r.lanes=0);return[t.memoizedState,r.dispatch]}function As(e){var t=ot(),r=t.queue;if(r===null)throw Error(I(311));r.lastRenderedReducer=e;var a=r.dispatch,i=r.pending,n=t.memoizedState;if(i!==null){r.pending=null;var s=i=i.next;do n=e(n,s.action),s=s.next;while(s!==i);vt(n,t.memoizedState)||(Oe=!0),t.memoizedState=n,t.baseQueue===null&&(t.baseState=n),r.lastRenderedState=n}return[n,a]}function Bm(){}function _m(e,t){var r=oe,a=ot(),i=t(),n=!vt(a.memoizedState,i);if(n&&(a.memoizedState=i,Oe=!0),a=a.queue,jd(Vm.bind(null,r,a,e),[e]),a.getSnapshot!==t||n||fe!==null&&fe.memoizedState.tag&1){if(r.flags|=2048,Wi(9,Xm.bind(null,r,a,i,t),void 0,null),ge===null)throw Error(I(349));$r&30||Um(r,t,i)}return i}function Um(e,t,r){e.flags|=16384,e={getSnapshot:t,value:r},t=oe.updateQueue,t===null?(t={lastEffect:null,stores:null},oe.updateQueue=t,t.stores=[e]):(r=t.stores,r===null?t.stores=[e]:r.push(e))}function Xm(e,t,r,a){t.value=r,t.getSnapshot=a,Hm(t)&&$m(e)}function Vm(e,t,r){return r(function(){Hm(t)&&$m(e)})}function Hm(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!vt(e,r)}catch{return!0}}function $m(e){var t=Ht(e,1);t!==null&&gt(t,e,1,-1)}function ih(e){var t=kt();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Qi,lastRenderedState:e},t.queue=e,e=e.dispatch=qb.bind(null,oe,e),[t.memoizedState,e]}function Wi(e,t,r,a){return e={tag:e,create:t,destroy:r,deps:a,next:null},t=oe.updateQueue,t===null?(t={lastEffect:null,stores:null},oe.updateQueue=t,t.lastEffect=e.next=e):(r=t.lastEffect,r===null?t.lastEffect=e.next=e:(a=r.next,r.next=e,e.next=a,t.lastEffect=e)),e}function Gm(){return ot().memoizedState}function Fn(e,t,r,a){var i=kt();oe.flags|=e,i.memoizedState=Wi(1|t,r,void 0,a===void 0?null:a)}function qo(e,t,r,a){var i=ot();a=a===void 0?null:a;var n=void 0;if(ue!==null){var s=ue.memoizedState;if(n=s.destroy,a!==null&&Cd(a,s.deps)){i.memoizedState=Wi(t,r,n,a);return}}oe.flags|=e,i.memoizedState=Wi(1|t,r,n,a)}function nh(e,t){return Fn(8390656,8,e,t)}function jd(e,t){return qo(2048,8,e,t)}function Km(e,t){return qo(4,2,e,t)}function Ym(e,t){return qo(4,4,e,t)}function Jm(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function Zm(e,t,r){return r=r!=null?r.concat([e]):null,qo(4,4,Jm.bind(null,t,e),r)}function qd(){}function ef(e,t){var r=ot();t=t===void 0?null:t;var a=r.memoizedState;return a!==null&&t!==null&&Cd(t,a[1])?a[0]:(r.memoizedState=[e,t],e)}function tf(e,t){var r=ot();t=t===void 0?null:t;var a=r.memoizedState;return a!==null&&t!==null&&Cd(t,a[1])?a[0]:(e=e(),r.memoizedState=[e,t],e)}function rf(e,t,r){return $r&21?(vt(r,t)||(r=sm(),oe.lanes|=r,Gr|=r,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,Oe=!0),e.memoizedState=r)}function Rb(e,t){var r=G;G=r!==0&&4>r?r:4,e(!0);var a=xs.transition;xs.transition={};try{e(!1),t()}finally{G=r,xs.transition=a}}function af(){return ot().memoizedState}function jb(e,t,r){var a=br(e);if(r={lane:a,action:r,hasEagerState:!1,eagerState:null,next:null},nf(e))of(t,r);else if(r=Qm(e,t,r,a),r!==null){var i=Re();gt(r,e,a,i),sf(r,t,a)}}function qb(e,t,r){var a=br(e),i={lane:a,action:r,hasEagerState:!1,eagerState:null,next:null};if(nf(e))of(t,i);else{var n=e.alternate;if(e.lanes===0&&(n===null||n.lanes===0)&&(n=t.lastRenderedReducer,n!==null))try{var s=t.lastRenderedState,l=n(s,r);if(i.hasEagerState=!0,i.eagerState=l,vt(l,s)){var d=t.interleaved;d===null?(i.next=i,Ad(t)):(i.next=d.next,d.next=i),t.interleaved=i;return}}catch{}finally{}r=Qm(e,t,i,a),r!==null&&(i=Re(),gt(r,e,a,i),sf(r,t,a))}}function nf(e){var t=e.alternate;return e===oe||t!==null&&t===oe}function of(e,t){wi=ho=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function sf(e,t,r){if(r&4194240){var a=t.lanes;a&=e.pendingLanes,r|=a,t.lanes=r,dd(e,r)}}var uo={readContext:nt,useCallback:xe,useContext:xe,useEffect:xe,useImperativeHandle:xe,useInsertionEffect:xe,useLayoutEffect:xe,useMemo:xe,useReducer:xe,useRef:xe,useState:xe,useDebugValue:xe,useDeferredValue:xe,useTransition:xe,useMutableSource:xe,useSyncExternalStore:xe,useId:xe,unstable_isNewReconciler:!1},Pb={readContext:nt,useCallback:function(e,t){return kt().memoizedState=[e,t===void 0?null:t],e},useContext:nt,useEffect:nh,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,Fn(4194308,4,Jm.bind(null,t,e),r)},useLayoutEffect:function(e,t){return Fn(4194308,4,e,t)},useInsertionEffect:function(e,t){return Fn(4,2,e,t)},useMemo:function(e,t){var r=kt();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var a=kt();return t=r!==void 0?r(t):t,a.memoizedState=a.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},a.queue=e,e=e.dispatch=jb.bind(null,oe,e),[a.memoizedState,e]}
vendor: 6,089 bytes, lines 38-40
38,useRef:function(e){var t=kt();return e={current:e},t.memoizedState=e},useState:ih,useDebugValue:qd,useDeferredValue:function(e){return kt().memoizedState=e},useTransition:function(){var e=ih(!1),t=e[0];return e=Rb.bind(null,e[1]),kt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var a=oe,i=kt();if(ie){if(r===void 0)throw Error(I(407));r=r()}else{if(r=t(),ge===null)throw Error(I(349));$r&30||Um(a,t,r)}i.memoizedState=r;var n={value:r,getSnapshot:t};return i.queue=n,nh(Vm.bind(null,a,n,e),[e]),a.flags|=2048,Wi(9,Xm.bind(null,a,n,r,t),void 0,null),r},useId:function(){var e=kt(),t=ge.identifierPrefix;if(ie){var r=_t,a=Bt;r=(a&~(1<<32-ft(a)-1)).toString(32)+r,t=":"+t+"R"+r,r=Fi++,0<r&&(t+="H"+r.toString(32)),t+=":"}else r=Ib++,t=":"+t+"r"+r.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},Db={readContext:nt,useCallback:ef,useContext:nt,useEffect:jd,useImperativeHandle:Zm,useInsertionEffect:Km,useLayoutEffect:Ym,useMemo:tf,useReducer:ks,useRef:Gm,useState:function(){return ks(Qi)},useDebugValue:qd,useDeferredValue:function(e){var t=ot();return rf(t,ue.memoizedState,e)},useTransition:function(){var e=ks(Qi)[0],t=ot().memoizedState;return[e,t]},useMutableSource:Bm,useSyncExternalStore:_m,useId:af,unstable_isNewReconciler:!1},Lb={readContext:nt,useCallback:ef,useContext:nt,useEffect:jd,useImperativeHandle:Zm,useInsertionEffect:Km,useLayoutEffect:Ym,useMemo:tf,useReducer:As,useRef:Gm,useState:function(){return As(Qi)},useDebugValue:qd,useDeferredValue:function(e){var t=ot();return ue===null?t.memoizedState=e:rf(t,ue.memoizedState,e)},useTransition:function(){var e=As(Qi)[0],t=ot().memoizedState;return[e,t]},useMutableSource:Bm,useSyncExternalStore:_m,useId:af,unstable_isNewReconciler:!1};function dt(e,t){if(e&&e.defaultProps){t=se({},t),e=e.defaultProps;for(var r in e)t[r]===void 0&&(t[r]=e[r]);return t}return t}function xl(e,t,r,a){t=e.memoizedState,r=r(a,t),r=r==null?t:se({},t,r),e.memoizedState=r,e.lanes===0&&(e.updateQueue.baseState=r)}var Po={isMounted:function(e){return(e=e._reactInternals)?ea(e)===e:!1},enqueueSetState:function(e,t,r){e=e._reactInternals;var a=Re(),i=br(e),n=Ut(a,i);n.payload=t,r!=null&&(n.callback=r),t=vr(e,n,i),t!==null&&(gt(t,e,i,a),Nn(t,e,i))},enqueueReplaceState:function(e,t,r){e=e._reactInternals;var a=Re(),i=br(e),n=Ut(a,i);n.tag=1,n.payload=t,r!=null&&(n.callback=r),t=vr(e,n,i),t!==null&&(gt(t,e,i,a),Nn(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var r=Re(),a=br(e),i=Ut(r,a);i.tag=2,t!=null&&(i.callback=t),t=vr(e,i,a),t!==null&&(gt(t,e,a,r),Nn(t,e,a))}};function oh(e,t,r,a,i,n,s){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(a,n,s):t.prototype&&t.prototype.isPureReactComponent?!qi(r,a)||!qi(i,n):!0}function lf(e,t,r){var a=!1,i=Ar,n=t.contextType;return typeof n=="object"&&n!==null?n=nt(n):(i=Qe(t)?Vr:Ee.current,a=t.contextTypes,n=(a=a!=null)?Da(e,i):Ar),t=new t(r,n),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Po,e.stateNode=t,t._reactInternals=e,a&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=n),t}function sh(e,t,r,a){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(r,a),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(r,a),t.state!==e&&Po.enqueueReplaceState(t,t.state,null)}function kl(e,t,r,a){var i=e.stateNode;i.props=r,i.state=e.memoizedState,i.refs={},Td(e);var n=t.contextType;typeof n=="object"&&n!==null?i.context=nt(n):(n=Qe(t)?Vr:Ee.current,i.context=Da(e,n)),i.state=e.memoizedState,n=t.getDerivedStateFromProps,typeof n=="function"&&(xl(e,t,n,r),i.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(t=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),t!==i.state&&Po.enqueueReplaceState(i,i.state,null),lo(e,r,i,a),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308)}function Fa(e,t){try{var r="",a=t;do r+=dy(a),a=a.return;while(a);var i=r}catch(n){i=`
39Error generating stack: `+n.message+`
40`+n.stack}return{value:e,source:t,stack:i,digest:null}}function Ts(e,t,r){return{value:e,source:null,stack:r??null,digest:t??null}}function Al(e,t){try{console.error(t.value)}catch(r){setTimeout(function(){throw r})}}var Nb=typeof WeakMap=="function"?WeakMap:Map;function df(e,t,r){r=Ut(-1,r),r.tag=3,r.payload={element:null};var a=t.value;return r.callback=function(){mo||(mo=!0,Pl=a),Al(e,t)},r}function cf(e,t,r){r=Ut(-1,r),r.tag=3;var a=e.type.getDerivedStateFromError;if(typeof a=="function"){var i=t.value;r.payload=function(){return a(i)},r.callback=function(){Al(e,t)}}var n=e.stateNode;return n!==null&&typeof n.componentDidCatch=="function"&&(r.callback=function(){Al(e,t),typeof a!="function"&&(yr===null?yr=new Set([this]):yr.add(this));var s=t.stack;this.componentDidCatch(t.value,{componentStack:s!==null?s:""})}),r}function lh(e,t,r){var a=e.pingCache;if(a===null){a=e.pingCache=new Nb;var i=new Set;a.set(t,i)}else i=a.get(t),i===void 0&&(i=new Set,a.set(t,i));i.has(r)||(i.add(r),e=Kb.bind(null,e,t,r),t.then(e,e))}function dh(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function ch(e,t,r,a,i){return e.mode&1?(e.flags|=65536,e.lanes=i,e):(e===t?e.flags|=65536:(e.flags|=128,r.flags|=131072,r.flags&=-52805,r.tag===1&&(r.alternate===null?r.tag=17:(t=Ut(-1,1),t.tag=2,vr(r,t,1))),r.lanes|=1),e)}var Ob=Yt.ReactCurrentOwner,Oe=!1;function Se(e,t,r,a){t.child=e===null?Fm(t,null,r,a):Na(t,e.child,r,a)}function hh(e,t,r,a,i){r=r.render;var n=t.ref;return ba(t,i),a=Id(e,t,r,a,n,i),r=Rd(),e!==null&&!Oe?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,$t(e,t,i)):(ie&&r&&vd(t),t.flags|=1,Se(e,t,a,i),t.child)}
vendor: 5,908 bytes, line 40
40function uh(e,t,r,a,i){if(e===null){var n=r.type;return typeof n=="function"&&!Wd(n)&&n.defaultProps===void 0&&r.compare===null&&r.defaultProps===void 0?(t.tag=15,t.type=n,hf(e,t,n,a,i)):(e=Bn(r.type,null,a,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(n=e.child,!(e.lanes&i)){var s=n.memoizedProps;if(r=r.compare,r=r!==null?r:qi,r(s,a)&&e.ref===t.ref)return $t(e,t,i)}return t.flags|=1,e=wr(n,a),e.ref=t.ref,e.return=t,t.child=e}function hf(e,t,r,a,i){if(e!==null){var n=e.memoizedProps;if(qi(n,a)&&e.ref===t.ref)if(Oe=!1,t.pendingProps=a=n,(e.lanes&i)!==0)e.flags&131072&&(Oe=!0);else return t.lanes=e.lanes,$t(e,t,i)}return Tl(e,t,r,a,i)}function uf(e,t,r){var a=t.pendingProps,i=a.children,n=e!==null?e.memoizedState:null;if(a.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},K(ma,Ue),Ue|=r;else{if(!(r&1073741824))return e=n!==null?n.baseLanes|r:r,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,K(ma,Ue),Ue|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},a=n!==null?n.baseLanes:r,K(ma,Ue),Ue|=a}else n!==null?(a=n.baseLanes|r,t.memoizedState=null):a=r,K(ma,Ue),Ue|=a;return Se(e,t,i,r),t.child}function pf(e,t){var r=t.ref;(e===null&&r!==null||e!==null&&e.ref!==r)&&(t.flags|=512,t.flags|=2097152)}function Tl(e,t,r,a,i){var n=Qe(r)?Vr:Ee.current;return n=Da(t,n),ba(t,i),r=Id(e,t,r,a,n,i),a=Rd(),e!==null&&!Oe?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,$t(e,t,i)):(ie&&a&&vd(t),t.flags|=1,Se(e,t,r,i),t.child)}function ph(e,t,r,a,i){if(Qe(r)){var n=!0;ao(t)}else n=!1;if(ba(t,i),t.stateNode===null)Qn(e,t),lf(t,r,a),kl(t,r,a,i),a=!0;else if(e===null){var s=t.stateNode,l=t.memoizedProps;s.props=l;var d=s.context,c=r.contextType;typeof c=="object"&&c!==null?c=nt(c):(c=Qe(r)?Vr:Ee.current,c=Da(t,c));var h=r.getDerivedStateFromProps,u=typeof h=="function"||typeof s.getSnapshotBeforeUpdate=="function";u||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(l!==a||d!==c)&&sh(t,s,a,c),ar=!1;var p=t.memoizedState;s.state=p,lo(t,a,s,i),d=t.memoizedState,l!==a||p!==d||Fe.current||ar?(typeof h=="function"&&(xl(t,r,h,a),d=t.memoizedState),(l=ar||oh(t,r,l,a,p,d,c))?(u||typeof s.UNSAFE_componentWillMount!="function"&&typeof s.componentWillMount!="function"||(typeof s.componentWillMount=="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&s.UNSAFE_componentWillMount()),typeof s.componentDidMount=="function"&&(t.flags|=4194308)):(typeof s.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=a,t.memoizedState=d),s.props=a,s.state=d,s.context=c,a=l):(typeof s.componentDidMount=="function"&&(t.flags|=4194308),a=!1)}else{s=t.stateNode,Wm(e,t),l=t.memoizedProps,c=t.type===t.elementType?l:dt(t.type,l),s.props=c,u=t.pendingProps,p=s.context,d=r.contextType,typeof d=="object"&&d!==null?d=nt(d):(d=Qe(r)?Vr:Ee.current,d=Da(t,d));var v=r.getDerivedStateFromProps;(h=typeof v=="function"||typeof s.getSnapshotBeforeUpdate=="function")||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(l!==u||p!==d)&&sh(t,s,a,d),ar=!1,p=t.memoizedState,s.state=p,lo(t,a,s,i);var b=t.memoizedState;l!==u||p!==b||Fe.current||ar?(typeof v=="function"&&(xl(t,r,v,a),b=t.memoizedState),(c=ar||oh(t,r,c,a,p,b,d)||!1)?(h||typeof s.UNSAFE_componentWillUpdate!="function"&&typeof s.componentWillUpdate!="function"||(typeof s.componentWillUpdate=="function"&&s.componentWillUpdate(a,b,d),typeof s.UNSAFE_componentWillUpdate=="function"&&s.UNSAFE_componentWillUpdate(a,b,d)),typeof s.componentDidUpdate=="function"&&(t.flags|=4),typeof s.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof s.componentDidUpdate!="function"||l===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&p===e.memoizedState||(t.flags|=1024),t.memoizedProps=a,t.memoizedState=b),s.props=a,s.state=b,s.context=d,a=c):(typeof s.componentDidUpdate!="function"||l===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&p===e.memoizedState||(t.flags|=1024),a=!1)}return El(e,t,r,a,n,i)}function El(e,t,r,a,i,n){pf(e,t);var s=(t.flags&128)!==0;if(!a&&!s)return i&&Jc(t,r,!1),$t(e,t,n);a=t.stateNode,Ob.current=t;var l=s&&typeof r.getDerivedStateFromError!="function"?null:a.render();return t.flags|=1,e!==null&&s?(t.child=Na(t,e.child,null,n),t.child=Na(t,null,l,n)):Se(e,t,l,n),t.memoizedState=a.state,i&&Jc(t,r,!0),t.child}function mf(e){var t=e.stateNode;t.pendingContext?Yc(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Yc(e,t.context,!1),Ed(e,t.containerInfo)}function mh(e,t,r,a,i){return La(),bd(i),t.flags|=256,Se(e,t,r,a),t.child}var Ml={dehydrated:null,treeContext:null,retryLane:0};function Sl(e){return{baseLanes:e,cachePool:null,transitions:null}}function ff(e,t,r){var a=t.pendingProps,i=ne.current,n=!1,s=(t.flags&128)!==0,l;if((l=s)||(l=e!==null&&e.memoizedState===null?!1:(i&2)!==0),l?(n=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(i|=1),K(ne,i&1),e===null)return bl(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(s=a.children,e=a.fallback,n?(a=t.mode,n=t.child,s={mode:"hidden",children:s},!(a&1)&&n!==null?(n.childLanes=0,n.pendingProps=s):n=No(s,a,0,null),e=Ur(e,a,r,null),n.return=t,e.return=t,n.sibling=e,t.child=n,t.child.memoizedState=Sl(r),t.memoizedState=Ml,e):Pd(t,s));if(i=e.memoizedState,i!==null&&(l=i.dehydrated,l!==null))return Fb(e,t,s,a,l,i,r);if(n){n=a.fallback,s=t.mode,i=e.child,l=i.sibling;var d={mode:"hidden",children:a.children};return!(s&1)&&t.child!==i?(a=t.child,a.childLanes=0,a.pendingProps=d,t.deletions=null):(a=wr(i,d),a.subtreeFlags=i.subtreeFlags&14680064),l!==null?n=wr
vendor: 6,771 bytes, line 40
40(l,n):(n=Ur(n,s,r,null),n.flags|=2),n.return=t,a.return=t,a.sibling=n,t.child=a,a=n,n=t.child,s=e.child.memoizedState,s=s===null?Sl(r):{baseLanes:s.baseLanes|r,cachePool:null,transitions:s.transitions},n.memoizedState=s,n.childLanes=e.childLanes&~r,t.memoizedState=Ml,a}return n=e.child,e=n.sibling,a=wr(n,{mode:"visible",children:a.children}),!(t.mode&1)&&(a.lanes=r),a.return=t,a.sibling=null,e!==null&&(r=t.deletions,r===null?(t.deletions=[e],t.flags|=16):r.push(e)),t.child=a,t.memoizedState=null,a}function Pd(e,t){return t=No({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function xn(e,t,r,a){return a!==null&&bd(a),Na(t,e.child,null,r),e=Pd(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Fb(e,t,r,a,i,n,s){if(r)return t.flags&256?(t.flags&=-257,a=Ts(Error(I(422))),xn(e,t,s,a)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(n=a.fallback,i=t.mode,a=No({mode:"visible",children:a.children},i,0,null),n=Ur(n,i,s,null),n.flags|=2,a.return=t,n.return=t,a.sibling=n,t.child=a,t.mode&1&&Na(t,e.child,null,s),t.child.memoizedState=Sl(s),t.memoizedState=Ml,n);if(!(t.mode&1))return xn(e,t,s,null);if(i.data==="$!"){if(a=i.nextSibling&&i.nextSibling.dataset,a)var l=a.dgst;return a=l,n=Error(I(419)),a=Ts(n,a,void 0),xn(e,t,s,a)}if(l=(s&e.childLanes)!==0,Oe||l){if(a=ge,a!==null){switch(s&-s){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(a.suspendedLanes|s)?0:i,i!==0&&i!==n.retryLane&&(n.retryLane=i,Ht(e,i),gt(a,e,i,-1))}return Qd(),a=Ts(Error(I(421))),xn(e,t,s,a)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=Yb.bind(null,e),i._reactRetry=t,null):(e=n.treeContext,He=gr(i.nextSibling),$e=t,ie=!0,pt=null,e!==null&&(tt[rt++]=Bt,tt[rt++]=_t,tt[rt++]=Hr,Bt=e.id,_t=e.overflow,Hr=t),t=Pd(t,a.children),t.flags|=4096,t)}function fh(e,t,r){e.lanes|=t;var a=e.alternate;a!==null&&(a.lanes|=t),wl(e.return,t,r)}function Es(e,t,r,a,i){var n=e.memoizedState;n===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:a,tail:r,tailMode:i}:(n.isBackwards=t,n.rendering=null,n.renderingStartTime=0,n.last=a,n.tail=r,n.tailMode=i)}function gf(e,t,r){var a=t.pendingProps,i=a.revealOrder,n=a.tail;if(Se(e,t,a.children,r),a=ne.current,a&2)a=a&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&fh(e,r,t);else if(e.tag===19)fh(e,r,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}a&=1}if(K(ne,a),!(t.mode&1))t.memoizedState=null;else switch(i){case"forwards":for(r=t.child,i=null;r!==null;)e=r.alternate,e!==null&&co(e)===null&&(i=r),r=r.sibling;r=i,r===null?(i=t.child,t.child=null):(i=r.sibling,r.sibling=null),Es(t,!1,i,r,n);break;case"backwards":for(r=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&co(e)===null){t.child=i;break}e=i.sibling,i.sibling=r,r=i,i=e}Es(t,!0,r,null,n);break;case"together":Es(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Qn(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function $t(e,t,r){if(e!==null&&(t.dependencies=e.dependencies),Gr|=t.lanes,!(r&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(I(153));if(t.child!==null){for(e=t.child,r=wr(e,e.pendingProps),t.child=r,r.return=t;e.sibling!==null;)e=e.sibling,r=r.sibling=wr(e,e.pendingProps),r.return=t;r.sibling=null}return t.child}function Qb(e,t,r){switch(t.tag){case 3:mf(t),La();break;case 5:zm(t);break;case 1:Qe(t.type)&&ao(t);break;case 4:Ed(t,t.stateNode.containerInfo);break;case 10:var a=t.type._context,i=t.memoizedProps.value;K(oo,a._currentValue),a._currentValue=i;break;case 13:if(a=t.memoizedState,a!==null)return a.dehydrated!==null?(K(ne,ne.current&1),t.flags|=128,null):r&t.child.childLanes?ff(e,t,r):(K(ne,ne.current&1),e=$t(e,t,r),e!==null?e.sibling:null);K(ne,ne.current&1);break;case 19:if(a=(r&t.childLanes)!==0,e.flags&128){if(a)return gf(e,t,r);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),K(ne,ne.current),a)break;return null;case 22:case 23:return t.lanes=0,uf(e,t,r)}return $t(e,t,r)}var vf,Cl,yf,bf;vf=function(e,t){for(var r=t.child;r!==null;){if(r.tag===5||r.tag===6)e.appendChild(r.stateNode);else if(r.tag!==4&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return;r=r.return}r.sibling.return=r.return,r=r.sibling}};Cl=function(){};yf=function(e,t,r,a){var i=e.memoizedProps;if(i!==a){e=t.stateNode,Fr(Ct.current);var n=null;switch(r){case"input":i=Ks(e,i),a=Ks(e,a),n=[];break;case"select":i=se({},i,{value:void 0}),a=se({},a,{value:void 0}),n=[];break;case"textarea":i=Zs(e,i),a=Zs(e,a),n=[];break;default:typeof i.onClick!="function"&&typeof a.onClick=="function"&&(e.onclick=to)}tl(r,a);var s;r=null;for(c in i)if(!a.hasOwnProperty(c)&&i.hasOwnProperty(c)&&i[c]!=null)if(c==="style"){var l=i[c];for(s in l)l.hasOwnProperty(s)&&(r||(r={}),r[s]="")}else c!=="dangerouslySetInnerHTML"&&c!=="children"&&c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&c!=="autoFocus"&&(Ei.hasOwnProperty(c)?n||(n=[]):(n=n||[]).push(c,null));for(c in a){var d=a[c];if(l=i!=null?i[c]:void 0,a.hasOwnProperty(c)&&d!==l&&(d!=null||l!=null))if(c==="style")if(l){for(s in l)!l.hasOwnProperty(s)||d&&d.hasOwnProperty(s)||(r||(r={}),r[s]="");for(s in d)d.hasOwnProperty(s)&&l[s]!==d[s]&&(r||(r={}),r[s]=d[s])}else r||(n||(n=[]),n.push(c,r)),r=d;else c==="dangerouslySetInnerHTML"?(d=d?d.__html:void 0,l=l?l.__html:void 0,d!=null&&l!==d&&(n=n||[]).push(c,d)):c==="children"?typeof d!="string"&&typeof d!="number"||(n=n||[]).push(c,""+d):c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&(Ei.hasOwnProperty(c)?(d!=null&&c==="onScroll"&&J("scroll",e),n||l===d||(n=[])):(n=n||[]).push(c,d))}r&&(n=n||[]).push("style",r);var c=n;(t.updateQueue=c)&&(t.flags|=4)}};bf=function(e,t,r,a){r!==a&&(t.flags|=4)};function ni(e,t){if(!ie)switch(e.tailMode){case"hidden":t=e.tail;for(var r=null;t!==null;)t.alternate!==null&&(r=t),t=t.sibling;r===null?e.tail=null:r.sibling=null;break;case"collapsed":r=e.tail;for(var a=null;r!==null;)r.alternate!==null&&(a=r),r=r.sibling;a===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:a.sibling=null}}function ke(e){var t=e.alternate!==null&&e.alternate.child===e.child,r=0,a=0;if(t)for(var i=e.child;i!==null;
vendor: 34,133 bytes, line 40
40)r|=i.lanes|i.childLanes,a|=i.subtreeFlags&14680064,a|=i.flags&14680064,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)r|=i.lanes|i.childLanes,a|=i.subtreeFlags,a|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=a,e.childLanes=r,t}function Wb(e,t,r){var a=t.pendingProps;switch(yd(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return ke(t),null;case 1:return Qe(t.type)&&ro(),ke(t),null;case 3:return a=t.stateNode,Oa(),ee(Fe),ee(Ee),Sd(),a.pendingContext&&(a.context=a.pendingContext,a.pendingContext=null),(e===null||e.child===null)&&(bn(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,pt!==null&&(Nl(pt),pt=null))),Cl(e,t),ke(t),null;case 5:Md(t);var i=Fr(Oi.current);if(r=t.type,e!==null&&t.stateNode!=null)yf(e,t,r,a,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!a){if(t.stateNode===null)throw Error(I(166));return ke(t),null}if(e=Fr(Ct.current),bn(t)){a=t.stateNode,r=t.type;var n=t.memoizedProps;switch(a[Mt]=t,a[Li]=n,e=(t.mode&1)!==0,r){case"dialog":J("cancel",a),J("close",a);break;case"iframe":case"object":case"embed":J("load",a);break;case"video":case"audio":for(i=0;i<mi.length;i++)J(mi[i],a);break;case"source":J("error",a);break;case"img":case"image":case"link":J("error",a),J("load",a);break;case"details":J("toggle",a);break;case"input":Tc(a,n),J("invalid",a);break;case"select":a._wrapperState={wasMultiple:!!n.multiple},J("invalid",a);break;case"textarea":Mc(a,n),J("invalid",a)}tl(r,n),i=null;for(var s in n)if(n.hasOwnProperty(s)){var l=n[s];s==="children"?typeof l=="string"?a.textContent!==l&&(n.suppressHydrationWarning!==!0&&yn(a.textContent,l,e),i=["children",l]):typeof l=="number"&&a.textContent!==""+l&&(n.suppressHydrationWarning!==!0&&yn(a.textContent,l,e),i=["children",""+l]):Ei.hasOwnProperty(s)&&l!=null&&s==="onScroll"&&J("scroll",a)}switch(r){case"input":cn(a),Ec(a,n,!0);break;case"textarea":cn(a),Sc(a);break;case"select":case"option":break;default:typeof n.onClick=="function"&&(a.onclick=to)}a=i,t.updateQueue=a,a!==null&&(t.flags|=4)}else{s=i.nodeType===9?i:i.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=Vp(r)),e==="http://www.w3.org/1999/xhtml"?r==="script"?(e=s.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof a.is=="string"?e=s.createElement(r,{is:a.is}):(e=s.createElement(r),r==="select"&&(s=e,a.multiple?s.multiple=!0:a.size&&(s.size=a.size))):e=s.createElementNS(e,r),e[Mt]=t,e[Li]=a,vf(e,t,!1,!1),t.stateNode=e;e:{switch(s=rl(r,a),r){case"dialog":J("cancel",e),J("close",e),i=a;break;case"iframe":case"object":case"embed":J("load",e),i=a;break;case"video":case"audio":for(i=0;i<mi.length;i++)J(mi[i],e);i=a;break;case"source":J("error",e),i=a;break;case"img":case"image":case"link":J("error",e),J("load",e),i=a;break;case"details":J("toggle",e),i=a;break;case"input":Tc(e,a),i=Ks(e,a),J("invalid",e);break;case"option":i=a;break;case"select":e._wrapperState={wasMultiple:!!a.multiple},i=se({},a,{value:void 0}),J("invalid",e);break;case"textarea":Mc(e,a),i=Zs(e,a),J("invalid",e);break;default:i=a}tl(r,i),l=i;for(n in l)if(l.hasOwnProperty(n)){var d=l[n];n==="style"?Gp(e,d):n==="dangerouslySetInnerHTML"?(d=d?d.__html:void 0,d!=null&&Hp(e,d)):n==="children"?typeof d=="string"?(r!=="textarea"||d!=="")&&Mi(e,d):typeof d=="number"&&Mi(e,""+d):n!=="suppressContentEditableWarning"&&n!=="suppressHydrationWarning"&&n!=="autoFocus"&&(Ei.hasOwnProperty(n)?d!=null&&n==="onScroll"&&J("scroll",e):d!=null&&ad(e,n,d,s))}switch(r){case"input":cn(e),Ec(e,a,!1);break;case"textarea":cn(e),Sc(e);break;case"option":a.value!=null&&e.setAttribute("value",""+kr(a.value));break;case"select":e.multiple=!!a.multiple,n=a.value,n!=null?fa(e,!!a.multiple,n,!1):a.defaultValue!=null&&fa(e,!!a.multiple,a.defaultValue,!0);break;default:typeof i.onClick=="function"&&(e.onclick=to)}switch(r){case"button":case"input":case"select":case"textarea":a=!!a.autoFocus;break e;case"img":a=!0;break e;default:a=!1}}a&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return ke(t),null;case 6:if(e&&t.stateNode!=null)bf(e,t,e.memoizedProps,a);else{if(typeof a!="string"&&t.stateNode===null)throw Error(I(166));if(r=Fr(Oi.current),Fr(Ct.current),bn(t)){if(a=t.stateNode,r=t.memoizedProps,a[Mt]=t,(n=a.nodeValue!==r)&&(e=$e,e!==null))switch(e.tag){case 3:yn(a.nodeValue,r,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&yn(a.nodeValue,r,(e.mode&1)!==0)}n&&(t.flags|=4)}else a=(r.nodeType===9?r:r.ownerDocument).createTextNode(a),a[Mt]=t,t.stateNode=a}return ke(t),null;case 13:if(ee(ne),a=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(ie&&He!==null&&t.mode&1&&!(t.flags&128))Nm(),La(),t.flags|=98560,n=!1;else if(n=bn(t),a!==null&&a.dehydrated!==null){if(e===null){if(!n)throw Error(I(318));if(n=t.memoizedState,n=n!==null?n.dehydrated:null,!n)throw Error(I(317));n[Mt]=t}else La(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;ke(t),n=!1}else pt!==null&&(Nl(pt),pt=null),n=!0;if(!n)return t.flags&65536?t:null}return t.flags&128?(t.lanes=r,t):(a=a!==null,a!==(e!==null&&e.memoizedState!==null)&&a&&(t.child.flags|=8192,t.mode&1&&(e===null||ne.current&1?me===0&&(me=3):Qd())),t.updateQueue!==null&&(t.flags|=4),ke(t),null);case 4:return Oa(),Cl(e,t),e===null&&Pi(t.stateNode.containerInfo),ke(t),null;case 10:return kd(t.type._context),ke(t),null;case 17:return Qe(t.type)&&ro(),ke(t),null;case 19:if(ee(ne),n=t.memoizedState,n===null)return ke(t),null;if(a=(t.flags&128)!==0,s=n.rendering,s===null)if(a)ni(n,!1);else{if(me!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(s=co(e),s!==null){for(t.flags|=128,ni(n,!1),a=s.updateQueue,a!==null&&(t.updateQueue=a,t.flags|=4),t.subtreeFlags=0,a=r,r=t.child;r!==null;)n=r,e=a,n.flags&=14680066,s=n.alternate,s===null?(n.childLanes=0,n.lanes=e,n.child=null,n.subtreeFlags=0,n.memoizedProps=null,n.memoizedState=null,n.updateQueue=null,n.dependencies=null,n.stateNode=null):(n.childLanes=s.childLanes,n.lanes=s.lanes,n.child=s.child,n.subtreeFlags=0,n.deletions=null,n.memoizedProps=s.memoizedProps,n.memoizedState=s.memoizedState,n.updateQueue=s.updateQueue,n.type=s.type,e=s.dependencies,n.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),r=r.sibling;return K(ne,ne.current&1|2),t.child}e=e.sibling}n.tail!==null&&ce()>Qa&&(t.flags|=128,a=!0,ni(n,!1),t.lanes=4194304)}else{if(!a)if(e=co(s),e!==null){if(t.flags|=128,a=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),ni(n,!0),n.tail===null&&n.tailMode==="hidden"&&!s.alternate&&!ie)return ke(t),null}else 2*ce()-n.renderingStartTime>Qa&&r!==1073741824&&(t.flags|=128,a=!0,ni(n,!1),t.lanes=4194304);n.isBackwards?(s.sibling=t.child,t.child=s):(r=n.last,r!==null?r.sibling=s:t.child=s,n.last=s)}return n.tail!==null?(t=n.tail,n.rendering=t,n.tail=t.sibling,n.renderingStartTime=ce(),t.sibling=null,r=ne.current,K(ne,a?r&1|2:r&1),t):(ke(t),null);case 22:case 23:return Fd(),a=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==a&&(t.flags|=8192),a&&t.mode&1?Ue&1073741824&&(ke(t),t.subtreeFlags&6&&(t.flags|=8192)):ke(t),null;case 24:return null;case 25:return null}throw Error(I(156,t.tag))}function zb(e,t){switch(yd(t),t.tag){case 1:return Qe(t.type)&&ro(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Oa(),ee(Fe),ee(Ee),Sd(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Md(t),null;case 13:if(ee(ne),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(I(340));La()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ee(ne),null;case 4:return Oa(),null;case 10:return kd(t.type._context),null;case 22:case 23:return Fd(),null;case 24:return null;default:return null}}var kn=!1,Te=!1,Bb=typeof WeakSet=="function"?WeakSet:Set,j=null;function pa(e,t){var r=e.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(a){de(e,t,a)}else r.current=null}function Il(e,t,r){try{r()}catch(a){de(e,t,a)}}var gh=!1;function _b(e,t){if(ul=Jn,e=Am(),gd(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var a=r.getSelection&&r.getSelection();if(a&&a.rangeCount!==0){r=a.anchorNode;var i=a.anchorOffset,n=a.focusNode;a=a.focusOffset;try{r.nodeType,n.nodeType}catch{r=null;break e}var s=0,l=-1,d=-1,c=0,h=0,u=e,p=null;t:for(;;){for(var v;u!==r||i!==0&&u.nodeType!==3||(l=s+i),u!==n||a!==0&&u.nodeType!==3||(d=s+a),u.nodeType===3&&(s+=u.nodeValue.length),(v=u.firstChild)!==null;)p=u,u=v;for(;;){if(u===e)break t;if(p===r&&++c===i&&(l=s),p===n&&++h===a&&(d=s),(v=u.nextSibling)!==null)break;u=p,p=u.parentNode}u=v}r=l===-1||d===-1?null:{start:l,end:d}}else r=null}r=r||{start:0,end:0}}else r=null;for(pl={focusedElem:e,selectionRange:r},Jn=!1,j=t;j!==null;)if(t=j,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,j=e;else for(;j!==null;){t=j;try{var b=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(b!==null){var y=b.memoizedProps,x=b.memoizedState,f=t.stateNode,m=f.getSnapshotBeforeUpdate(t.elementType===t.type?y:dt(t.type,y),x);f.__reactInternalSnapshotBeforeUpdate=m}break;case 3:var g=t.stateNode.containerInfo;g.nodeType===1?g.textContent="":g.nodeType===9&&g.documentElement&&g.removeChild(g.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(I(163))}}catch(k){de(t,t.return,k)}if(e=t.sibling,e!==null){e.return=t.return,j=e;break}j=t.return}return b=gh,gh=!1,b}function xi(e,t,r){var a=t.updateQueue;if(a=a!==null?a.lastEffect:null,a!==null){var i=a=a.next;do{if((i.tag&e)===e){var n=i.destroy;i.destroy=void 0,n!==void 0&&Il(t,r,n)}i=i.next}while(i!==a)}}function Do(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var r=t=t.next;do{if((r.tag&e)===e){var a=r.create;r.destroy=a()}r=r.next}while(r!==t)}}function Rl(e){var t=e.ref;if(t!==null){var r=e.stateNode;switch(e.tag){case 5:e=r;break;default:e=r}typeof t=="function"?t(e):t.current=e}}function wf(e){var t=e.alternate;t!==null&&(e.alternate=null,wf(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Mt],delete t[Li],delete t[gl],delete t[Eb],delete t[Mb])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function xf(e){return e.tag===5||e.tag===3||e.tag===4}function vh(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||xf(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function jl(e,t,r){var a=e.tag;if(a===5||a===6)e=e.stateNode,t?r.nodeType===8?r.parentNode.insertBefore(e,t):r.insertBefore(e,t):(r.nodeType===8?(t=r.parentNode,t.insertBefore(e,r)):(t=r,t.appendChild(e)),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=to));else if(a!==4&&(e=e.child,e!==null))for(jl(e,t,r),e=e.sibling;e!==null;)jl(e,t,r),e=e.sibling}function ql(e,t,r){var a=e.tag;if(a===5||a===6)e=e.stateNode,t?r.insertBefore(e,t):r.appendChild(e);else if(a!==4&&(e=e.child,e!==null))for(ql(e,t,r),e=e.sibling;e!==null;)ql(e,t,r),e=e.sibling}var ve=null,ut=!1;function Jt(e,t,r){for(r=r.child;r!==null;)kf(e,t,r),r=r.sibling}function kf(e,t,r){if(St&&typeof St.onCommitFiberUnmount=="function")try{St.onCommitFiberUnmount(Mo,r)}catch{}switch(r.tag){case 5:Te||pa(r,t);case 6:var a=ve,i=ut;ve=null,Jt(e,t,r),ve=a,ut=i,ve!==null&&(ut?(e=ve,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):ve.removeChild(r.stateNode));break;case 18:ve!==null&&(ut?(e=ve,r=r.stateNode,e.nodeType===8?ys(e.parentNode,r):e.nodeType===1&&ys(e,r),Ri(e)):ys(ve,r.stateNode));break;case 4:a=ve,i=ut,ve=r.stateNode.containerInfo,ut=!0,Jt(e,t,r),ve=a,ut=i;break;case 0:case 11:case 14:case 15:if(!Te&&(a=r.updateQueue,a!==null&&(a=a.lastEffect,a!==null))){i=a=a.next;do{var n=i,s=n.destroy;n=n.tag,s!==void 0&&(n&2||n&4)&&Il(r,t,s),i=i.next}while(i!==a)}Jt(e,t,r);break;case 1:if(!Te&&(pa(r,t),a=r.stateNode,typeof a.componentWillUnmount=="function"))try{a.props=r.memoizedProps,a.state=r.memoizedState,a.componentWillUnmount()}catch(l){de(r,t,l)}Jt(e,t,r);break;case 21:Jt(e,t,r);break;case 22:r.mode&1?(Te=(a=Te)||r.memoizedState!==null,Jt(e,t,r),Te=a):Jt(e,t,r);break;default:Jt(e,t,r)}}function yh(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new Bb),t.forEach(function(a){var i=Jb.bind(null,e,a);r.has(a)||(r.add(a),a.then(i,i))})}}function lt(e,t){var r=t.deletions;if(r!==null)for(var a=0;a<r.length;a++){var i=r[a];try{var n=e,s=t,l=s;e:for(;l!==null;){switch(l.tag){case 5:ve=l.stateNode,ut=!1;break e;case 3:ve=l.stateNode.containerInfo,ut=!0;break e;case 4:ve=l.stateNode.containerInfo,ut=!0;break e}l=l.return}if(ve===null)throw Error(I(160));kf(n,s,i),ve=null,ut=!1;var d=i.alternate;d!==null&&(d.return=null),i.return=null}catch(c){de(i,t,c)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Af(t,e),t=t.sibling}function Af(e,t){var r=e.alternate,a=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(lt(t,e),xt(e),a&4){try{xi(3,e,e.return),Do(3,e)}catch(y){de(e,e.return,y)}try{xi(5,e,e.return)}catch(y){de(e,e.return,y)}}break;case 1:lt(t,e),xt(e),a&512&&r!==null&&pa(r,r.return);break;case 5:if(lt(t,e),xt(e),a&512&&r!==null&&pa(r,r.return),e.flags&32){var i=e.stateNode;try{Mi(i,"")}catch(y){de(e,e.return,y)}}if(a&4&&(i=e.stateNode,i!=null)){var n=e.memoizedProps,s=r!==null?r.memoizedProps:n,l=e.type,d=e.updateQueue;if(e.updateQueue=null,d!==null)try{l==="input"&&n.type==="radio"&&n.name!=null&&Up(i,n),rl(l,s);var c=rl(l,n);for(s=0;s<d.length;s+=2){var h=d[s],u=d[s+1];h==="style"?Gp(i,u):h==="dangerouslySetInnerHTML"?Hp(i,u):h==="children"?Mi(i,u):ad(i,h,u,c)}switch(l){case"input":Ys(i,n);break;case"textarea":Xp(i,n);break;case"select":var p=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!n.multiple;var v=n.value;v!=null?fa(i,!!n.multiple,v,!1):p!==!!n.multiple&&(n.defaultValue!=null?fa(i,!!n.multiple,n.defaultValue,!0):fa(i,!!n.multiple,n.multiple?[]:"",!1))}i[Li]=n}catch(y){de(e,e.return,y)}}break;case 6:if(lt(t,e),xt(e),a&4){if(e.stateNode===null)throw Error(I(162));i=e.stateNode,n=e.memoizedProps;try{i.nodeValue=n}catch(y){de(e,e.return,y)}}break;case 3:if(lt(t,e),xt(e),a&4&&r!==null&&r.memoizedState.isDehydrated)try{Ri(t.containerInfo)}catch(y){de(e,e.return,y)}break;case 4:lt(t,e),xt(e);break;case 13:lt(t,e),xt(e),i=e.child,i.flags&8192&&(n=i.memoizedState!==null,i.stateNode.isHidden=n,!n||i.alternate!==null&&i.alternate.memoizedState!==null||(Nd=ce())),a&4&&yh(e);break;case 22:if(h=r!==null&&r.memoizedState!==null,e.mode&1?(Te=(c=Te)||h,lt(t,e),Te=c):lt(t,e),xt(e),a&8192){if(c=e.memoizedState!==null,(e.stateNode.isHidden=c)&&!h&&e.mode&1)for(j=e,h=e.child;h!==null;){for(u=j=h;j!==null;){switch(p=j,v=p.child,p.tag){case 0:case 11:case 14:case 15:xi(4,p,p.return);break;case 1:pa(p,p.return);var b=p.stateNode;if(typeof b.componentWillUnmount=="function"){a=p,r=p.return;try{t=a,b.props=t.memoizedProps,b.state=t.memoizedState,b.componentWillUnmount()}catch(y){de(a,r,y)}}break;case 5:pa(p,p.return);break;case 22:if(p.memoizedState!==null){wh(u);continue}}v!==null?(v.return=p,j=v):wh(u)}h=h.sibling}e:for(h=null,u=e;;){if(u.tag===5){if(h===null){h=u;try{i=u.stateNode,c?(n=i.style,typeof n.setProperty=="function"?n.setProperty("display","none","important"):n.display="none"):(l=u.stateNode,d=u.memoizedProps.style,s=d!=null&&d.hasOwnProperty("display")?d.display:null,l.style.display=$p("display",s))}catch(y){de(e,e.return,y)}}}else if(u.tag===6){if(h===null)try{u.stateNode.nodeValue=c?"":u.memoizedProps}catch(y){de(e,e.return,y)}}else if((u.tag!==22&&u.tag!==23||u.memoizedState===null||u===e)&&u.child!==null){u.child.return=u,u=u.child;continue}if(u===e)break e;for(;u.sibling===null;){if(u.return===null||u.return===e)break e;h===u&&(h=null),u=u.return}h===u&&(h=null),u.sibling.return=u.return,u=u.sibling}}break;case 19:lt(t,e),xt(e),a&4&&yh(e);break;case 21:break;default:lt(t,e),xt(e)}}function xt(e){var t=e.flags;if(t&2){try{e:{for(var r=e.return;r!==null;){if(xf(r)){var a=r;break e}r=r.return}throw Error(I(160))}switch(a.tag){case 5:var i=a.stateNode;a.flags&32&&(Mi(i,""),a.flags&=-33);var n=vh(e);ql(e,n,i);break;case 3:case 4:var s=a.stateNode.containerInfo,l=vh(e);jl(e,l,s);break;default:throw Error(I(161))}}catch(d){de(e,e.return,d)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Ub(e,t,r){j=e,Tf(e)}function Tf(e,t,r){for(var a=(e.mode&1)!==0;j!==null;){var i=j,n=i.child;if(i.tag===22&&a){var s=i.memoizedState!==null||kn;if(!s){var l=i.alternate,d=l!==null&&l.memoizedState!==null||Te;l=kn;var c=Te;if(kn=s,(Te=d)&&!c)for(j=i;j!==null;)s=j,d=s.child,s.tag===22&&s.memoizedState!==null?xh(i):d!==null?(d.return=s,j=d):xh(i);for(;n!==null;)j=n,Tf(n),n=n.sibling;j=i,kn=l,Te=c}bh(e)}else i.subtreeFlags&8772&&n!==null?(n.return=i,j=n):bh(e)}}function bh(e){for(;j!==null;){var t=j;if(t.flags&8772){var r=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:Te||Do(5,t);break;case 1:var a=t.stateNode;if(t.flags&4&&!Te)if(r===null)a.componentDidMount();else{var i=t.elementType===t.type?r.memoizedProps:dt(t.type,r.memoizedProps);a.componentDidUpdate(i,r.memoizedState,a.__reactInternalSnapshotBeforeUpdate)}var n=t.updateQueue;n!==null&&ah(t,n,a);break;case 3:var s=t.updateQueue;if(s!==null){if(r=null,t.child!==null)switch(t.child.tag){case 5:r=t.child.stateNode;break;case 1:r=t.child.stateNode}ah(t,s,r)}break;case 5:var l=t.stateNode;if(r===null&&t.flags&4){r=l;var d=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":d.autoFocus&&r.focus();break;case"img":d.src&&(r.src=d.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var c=t.alternate;if(c!==null){var h=c.memoizedState;if(h!==null){var u=h.dehydrated;u!==null&&Ri(u)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(I(163))}Te||t.flags&512&&Rl(t)}catch(p){de(t,t.return,p)}}if(t===e){j=null;break}if(r=t.sibling,r!==null){r.return=t.return,j=r;break}j=t.return}}function wh(e){for(;j!==null;){var t=j;if(t===e){j=null;break}var r=t.sibling;if(r!==null){r.return=t.return,j=r;break}j=t.return}}function xh(e){for(;j!==null;){var t=j;try{switch(t.tag){case 0:case 11:case 15:var r=t.return;try{Do(4,t)}catch(d){de(t,r,d)}break;case 1:var a=t.stateNode;if(typeof a.componentDidMount=="function"){var i=t.return;try{a.componentDidMount()}catch(d){de(t,i,d)}}var n=t.return;try{Rl(t)}catch(d){de(t,n,d)}break;case 5:var s=t.return;try{Rl(t)}catch(d){de(t,s,d)}}}catch(d){de(t,t.return,d)}if(t===e){j=null;break}var l=t.sibling;if(l!==null){l.return=t.return,j=l;break}j=t.return}}var Xb=Math.ceil,po=Yt.ReactCurrentDispatcher,Dd=Yt.ReactCurrentOwner,it=Yt.ReactCurrentBatchConfig,X=0,ge=null,he=null,ye=0,Ue=0,ma=Cr(0),me=0,zi=null,Gr=0,Lo=0,Ld=0,ki=null,Ne=null,Nd=0,Qa=1/0,Qt=null,mo=!1,Pl=null,yr=null,An=!1,ur=null,fo=0,Ai=0,Dl=null,Wn=-1,zn=0;function Re(){return X&6?ce():Wn!==-1?Wn:Wn=ce()}function br(e){return e.mode&1?X&2&&ye!==0?ye&-ye:Cb.transition!==null?(zn===0&&(zn=sm()),zn):(e=G,e!==0||(e=window.event,e=e===void 0?16:mm(e.type)),e):1}function gt(e,t,r,a){if(50<Ai)throw Ai=0,Dl=null,Error(I(185));Ji(e,r,a),(!(X&2)||e!==ge)&&(e===ge&&(!(X&2)&&(Lo|=r),me===4&&nr(e,ye)),We(e,a),r===1&&X===0&&!(t.mode&1)&&(Qa=ce()+500,jo&&Ir()))}function We(e,t){var r=e.callbackNode;Cy(e,t);var a=Yn(e,e===ge?ye:0);if(a===0)r!==null&&Rc(r),e.callbackNode=null,e.callbackPriority=0;else if(t=a&-a,e.callbackPriority!==t){if(r!=null&&Rc(r),t===1)e.tag===0?Sb(kh.bind(null,e)):Pm(kh.bind(null,e)),Ab(function(){!(X&6)&&Ir()}),r=null;else{switch(lm(a)){case 1:r=ld;break;case 4:r=nm;break;case 16:r=Kn;break;case 536870912:r=om;break;default:r=Kn}r=qf(r,Ef.bind(null,e))}e.callbackPriority=t,e.callbackNode=r}}function Ef(e,t){if(Wn=-1,zn=0,X&6)throw Error(I(327));var r=e.callbackNode;if(wa()&&e.callbackNode!==r)return null;var a=Yn(e,e===ge?ye:0);if(a===0)return null;if(a&30||a&e.expiredLanes||t)t=go(e,a);else{t=a;var i=X;X|=2;var n=Sf();(ge!==e||ye!==t)&&(Qt=null,Qa=ce()+500,_r(e,t));do try{$b();break}catch(l){Mf(e,l)}while(!0);xd(),po.current=n,X=i,he!==null?t=0:(ge=null,ye=0,t=me)}if(t!==0){if(t===2&&(i=sl(e),i!==0&&(a=i,t=Ll(e,i))),t===1)throw r=zi,_r(e,0),nr(e,a),We(e,ce()),r;if(t===6)nr(e,a);else{if(i=e.current.alternate,!(a&30)&&!Vb(i)&&(t=go(e,a),t===2&&(n=sl(e),n!==0&&(a=n,t=Ll(e,n))),t===1))throw r=zi,_r(e,0),nr(e,a),We(e,ce()),r;switch(e.finishedWork=i,e.finishedLanes=a,t){case 0:case 1:throw Error(I(345));case 2:Dr(e,Ne,Qt);break;case 3:if(nr(e,a),(a&130023424)===a&&(t=Nd+500-ce(),10<t)){if(Yn(e,0)!==0)break;if(i=e.suspendedLanes,(i&a)!==a){Re(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=fl(Dr.bind(null,e,Ne,Qt),t);break}Dr(e,Ne,Qt);break;case 4:if(nr(e,a),(a&4194240)===a)break;for(t=e.eventTimes,i=-1;0<a;){var s=31-ft(a);n=1<<s,s=t[s],s>i&&(i=s),a&=~n}if(a=i,a=ce()-a,a=(120>a?120:480>a?480:1080>a?1080:1920>a?1920:3e3>a?3e3:4320>a?4320:1960*Xb(a/1960))-a,10<a){e.timeoutHandle=fl(Dr.bind(null,e,Ne,Qt),a);break}Dr(e,Ne,Qt);break;case 5:Dr(e,Ne,Qt);break;default:throw Error(I(329))}}}return We(e,ce()),e.callbackNode===r?Ef.bind(null,e):null}function Ll(e,t){var r=ki;return e.current.memoizedState.isDehydrated&&(_r(e,t).flags|=256),e=go(e,t),e!==2&&(t=Ne,Ne=r,t!==null&&Nl(t)),e}function Nl(e){Ne===null?Ne=e:Ne.push.apply(Ne,e)}function Vb(e){for(var t=e;;){if(t.flags&16384){var r=t.updateQueue;if(r!==null&&(r=r.stores,r!==null))for(var a=0;a<r.length;a++){var i=r[a],n=i.getSnapshot;i=i.value;try{if(!vt(n(),i))return!1}catch{return!1}}}if(r=t.child,t.subtreeFlags&16384&&r!==null)r.return=t,t=r;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function nr(e,t){for(t&=~Ld,t&=~Lo,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var r=31-ft(t),a=1<<r;e[r]=-1,t&=~a}}function kh(e){if(X&6)throw Error(I(327));wa();var t=Yn(e,0);if(!(t&1))return We(e,ce()),null;var r=go(e,t);if(e.tag!==0&&r===2){var a=sl(e);a!==0&&(t=a,r=Ll(e,a))}if(r===1)throw r=zi,_r(e,0),nr(e,t),We(e,ce()),r;if(r===6)throw Error(I(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Dr(e,Ne,Qt),We(e,ce()),null}function Od(e,t){var r=X;X|=1;try{return e(t)}finally{X=r,X===0&&(Qa=ce()+500,jo&&Ir())}}function Kr(e){ur!==null&&ur.tag===0&&!(X&6)&&wa();var t=X;X|=1;var r=it.transition,a=G;try{if(it.transition=null,G=1,e)return e()}finally{G=a,it.transition=r,X=t,!(X&6)&&Ir()}}function Fd(){Ue=ma.current,ee(ma)}function _r(e,t){e.finishedWork=null,e.finishedLanes=0;var r=e.timeoutHandle;if(r!==-1&&(e.timeoutHandle=-1,kb(r)),he!==null)for(r=he.return;r!==null;){var a=r;switch(yd(a),a.tag){case 1:a=a.type.childContextTypes,a!=null&&ro();break;case 3:Oa(),ee(Fe),ee(Ee),Sd();break;case 5:Md(a);break;case 4:Oa();break;case 13:ee(ne);break;case 19:ee(ne);break;case 10:kd(a.type._context);break;case 22:case 23:Fd()}r=r.return}if(ge=e,he=e=wr(e.current,null),ye=Ue=t,me=0,zi=null,Ld=Lo=Gr=0,Ne=ki=null,Or!==null){for(t=0;t<Or.length;t++)if(r=Or[t],a=r.interleaved,a!==null){r.interleaved=null;var i=a.next,n=r.pending;if(n!==null){var s=n.next;n.next=i,a.next=s}r.pending=a}Or=null}return e}function Mf(e,t){do{var r=he;try{if(xd(),On.current=uo,ho){for(var a=oe.memoizedState;a!==null;){var i=a.queue;i!==null&&(i.pending=null),a=a.next}ho=!1}if($r=0,fe=ue=oe=null,wi=!1,Fi=0,Dd.current=null,r===null||r.return===null){me=1,zi=t,he=null;break}e:{var n=e,s=r.return,l=r,d=t;if(t=ye,l.flags|=32768,d!==null&&typeof d=="object"&&typeof d.then=="function"){var c=d,h=l,u=h.tag;if(!(h.mode&1)&&(u===0||u===11||u===15)){var p=h.alternate;p?(h.updateQueue=p.updateQueue,h.memoizedState=p.memoizedState,h.lanes=p.lanes):(h.updateQueue=null,h.memoizedState=null)}var v=dh(s);if(v!==null){v.flags&=-257,ch(v,s,l,n,t),v.mode&1&&lh(n,c,t),t=v,d=c;var b=t.updateQueue;if(b===null){var y=new Set;y.add(d),t.updateQueue=y}else b.add(d);break e}else{if(!(t&1)){lh(n,c,t),Qd();break e}d=Error(I(426))}}else if(ie&&l.mode&1){var x=dh(s);if(x!==null){!(x.flags&65536)&&(x.flags|=256),ch(x,s,l,n,t),bd(Fa(d,l));break e}}n=d=Fa(d,l),me!==4&&(me=2),ki===null?ki=[n]:ki.push(n),n=s;do{switch(n.tag){case 3:n.flags|=65536,t&=-t,n.lanes|=t;var f=df(n,d,t);rh(n,f);break e;case 1:l=d;var m=n.type,g=n.stateNode;if(!(n.flags&128)&&(typeof m.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(yr===null||!yr.has(g)))){n.flags|=65536,t&=-t,n.lanes|=t;var k=cf(n,l,t);rh(n,k);break e}}n=n.return}while(n!==null)}If(r)}catch(A){t=A,he===r&&r!==null&&(he=r=r.return);continue}break}while(!0)}function Sf(){var e=po.current;return po.current=uo,e===null?uo:e}function Qd(){(me===0||me===3||me===2)&&(me=4),ge===null||!(Gr&268435455)&&!(Lo&268435455)||nr(ge,ye)}function go(e,t){var r=X;X|=2;var a=Sf();(ge!==e||ye!==t)&&(Qt=null,_r(e,t));do try{Hb();break}catch(i){Mf(e,i)}while(!0);if(xd(),X=r,po.current=a,he!==null)throw Error(I(261));return ge=null,ye=0,me}function Hb(){for(;he!==null;)Cf(he)}function $b(){for(;he!==null&&!by();)Cf(he)}function Cf(e){var t=jf(e.alternate,e,Ue);e.memoizedProps=e.pendingProps,t===null?If(e):he=t,Dd.current=null}function If(e){var t=e;do{var r=t.alternate;if(e=t.return,t.flags&32768){if(r=zb(r,t),r!==null){r.flags&=32767,he=r;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{me=6,he=null;return}}else if(r=Wb(r,t,Ue),r!==null){he=r;return}if(t=t.sibling,t!==null){he=t;return}he=t=e}while(t!==null);me===0&&(me=5)}function Dr(e,t,r){var a=G,i=it.transition;try{it.transition=null,G=1,Gb(e,t,r,a)}finally{it.transition=i,G=a}return null}function Gb(e,t,r,a){do wa();while(ur!==null);if(X&6)throw Error(I(327));r=e.finishedWork;var i=e.finishedLanes;if(r===null)return null;if(e.finishedWork=null,e.finishedLanes=0,r===e.current)throw Error(I(177));e.callbackNode=null,e.callbackPriority=0;var n=r.lanes|r.childLanes;if(Iy(e,n),e===ge&&(he=ge=null,ye=0),!(r.subtreeFlags&2064)&&!(r.flags&2064)||An||(An=!0,qf(Kn,function(){return wa(),null})),n=(r.flags&15990)!==0,r.subtreeFlags&15990||n){n=it.transition,it.transition=null;var s=G;G=1;var l=X;X|=4,Dd.current=null,_b(e,r),Af(r,e),fb(pl),Jn=!!ul,pl=ul=null,e.current=r,Ub(r),wy(),X=l,G=s,it.transition=n}else e.current=r;if(An&&(An=!1,ur=e,fo=i),n=e.pendingLanes,n===0&&(yr=null),Ay(r.stateNode),We(e,ce()),t!==null)for(a=e.onRecoverableError,r=0;r<t.length;r++)i=t[r],a(i.value,{componentStack:i.stack,digest:i.digest});if(mo)throw mo=!1,e=Pl,Pl=null,e;return fo&1&&e.tag!==0&&wa(),n=e.pendingLanes,n&1?e===Dl?Ai++:(Ai=0,Dl=e):Ai=0,Ir(),null}function wa(){if(ur!==null){var e=lm(fo),t=it.transition,r=G;try{if(it.transition=null,G=16>e?16:e,ur===null)var a=!1;else{if(e=ur,ur=null,fo=0,X&6)throw Error(I(331));var i=X;for(X|=4,j=e.current;j!==null;){var n=j,s=n.child;if(j.flags&16){var l=n.deletions;if(l!==null){for(var d=0;d<l.length;d++){var c=l[d];for(j=c;j!==null;){var h=j;switch(h.tag){case 0:case 11:case 15:xi(8,h,n)}var u=h.child;if(u!==null)u.return=h,j=u;else for(;j!==null;){h=j;var p=h.sibling,v=h.return;if(wf(h),h===c){j=null;break}if(p!==null){p.return=v,j=p;break}j=v}}}var b=n.alternate;if(b!==null){var y=b.child;if(y!==null){b.child=null;do{var x=y.sibling;y.sibling=null,y=x}while(y!==null)}}j=n}}if(n.subtreeFlags&2064&&s!==null)s.return=n,j=s;else e:for(;j!==null;){if(n=j,n.flags&2048)switch(n.tag){case 0:case 11:case 15:xi(9,n,n.return)}var f=n.sibling;if(f!==null){f.return=n.return,j=f;break e}j=n.return}}var m=e.current;for(j=m;j!==null;){s=j;var g=s.child;if(s.subtreeFlags&2064&&g!==null)g.return=s,j=g;else e:for(s=m;j!==null;){if(l=j,l.flags&2048)try{switch(l.tag){case 0:case 11:case 15:Do(9,l)}}catch(A){de(l,l.return,A)}if(l===s){j=null;break e}var k=l.sibling;if(k!==null){k.return=l.return,j=k;break e}j=l.return}}if(X=i,Ir(),St&&typeof St.onPostCommitFiberRoot=="function")try{St.onPostCommitFiberRoot(Mo,e)}catch{}a=!0}return a}finally{G=r,it.transition=t}}return!1}function Ah(e,t,r){t=Fa(r,t),t=df(e,t,1),e=vr(e,t,1),t=Re(),e!==null&&(Ji(e,1,t),We(e,t))}function de(e,t,r){if(e.tag===3)Ah(e,e,r);else for(;t!==null;){if(t.tag===3){Ah(t,e,r);break}else if(t.tag===1){var a=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof a.componentDidCatch=="function"&&(yr===null||!yr.has(a))){e=Fa(r,e),e=cf(t,e,1),t=vr(t,e,1),e=Re(),t!==null&&(Ji(t,1,e),We(t,e));break}}t=t.return}}function Kb(e,t,r){var a=e.pingCache;a!==null&&a.delete(t),t=Re(),e.pingedLanes|=e.suspendedLanes&r,ge===e&&(ye&r)===r&&(me===4||me===3&&(ye&130023424)===ye&&500>ce()-Nd?_r(e,0):Ld|=r),We(e,t)}function Rf(e,t){t===0&&(e.mode&1?(t=pn,pn<<=1,!(pn&130023424)&&(pn=4194304)):t=1);var r=Re();e=Ht(e,t),e!==null&&(Ji(e,t,r),We(e,r))}function Yb(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),Rf(e,r)}function Jb(e,t){var r=0;switch(e.tag){case 13:var a=e.stateNode,i=e.memoizedState;i!==null&&(r=i.retryLane);break;case 19:a=e.stateNode;break;default:throw Error(I(314))}a!==null&&a.delete(t),Rf(e,r)}var jf;jf=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||Fe.current)Oe=!0;else{if(!(e.lanes&r)&&!(t.flags&128))return Oe=!1,Qb(e,t,r);Oe=!!(e.flags&131072)}else Oe=!1,ie&&t.flags&1048576&&Dm(t,no,t.index);switch(t.lanes=0,t.tag){case 2:var a=t.type;Qn(e,t),e=t.pendingProps;var i=Da(t,Ee.current);ba(t,r),i=Id(null,t,a,e,i,r);var n=Rd();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Qe(a)?(n=!0,ao(t)):n=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,Td(t),i.updater=Po,t.stateNode=i,i._reactInternals=t,kl(t,a,e,r),t=El(null,t,a,!0,n,r)):(t.tag=0,ie&&n&&vd(t),Se(null,t,i,r),t=t.child),t;case 16:a=t.elementType;e:{switch(Qn(e,t),e=t.pendingProps,i=a._init,a=i(a._payload),t.type=a,i=t.tag=ew(a),e=dt(a,e),i){case 0:t=Tl(null,t,a,e,r);break e;case 1:t=ph(null,t,a,e,r);break e;case 11:t=hh(null,t,a,e,r);break e;case 14:t=uh(null,t,a,dt(a.type,e),r);break e}throw Error(I(306,a,""))}return t;case 0:return a=t.type,i=t.pendingProps,i=t.elementType===a?i:dt(a,i),Tl(e,t,a,i,r);case 1:return a=t.type,i=t.pendingProps,i=t.elementType===a?i:dt(a,i),ph(e,t,a,i,r);case 3:e:{if(mf(t),e===null)throw Error(I(387));a=t.pendingProps,n=t.memoizedState,i=n.element,Wm(e,t),lo(t,a,null,r);var s=t.memoizedState;if(a=s.element,n.isDehydrated)if(n={element:a,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=n,t.memoizedState=n,t.flags&256){i=Fa(Error(I(423)),t),t=mh(e,t,a,r,i);break e}else if(a!==i){i=Fa(Error(I(424)),t),t=mh(e,t,a,r,i);break e}else for(He=gr(t.stateNode.containerInfo.firstChild),$e=t,ie=!0,pt=null,r=Fm(t,null,a,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(La(),a===i){t=$t(e,t,r);break e}Se(e,t,a,r)}t=t.child}return t;case 5:return zm(t),e===null&&bl(t),a=t.type,i=t.pendingProps,n=e!==null?e.memoizedProps:null,s=i.children,ml(a,i)?s=null:n!==null&&ml(a,n)&&(t.flags|=32),pf(e,t),Se(e,t,s,r),t.child;case 6:return e===null&&bl(t),null;case 13:return ff(e,t,r);case 4:return Ed(t,t.stateNode.containerInfo),a=t.pendingProps,e===null?t.child=Na(t,null,a,r):Se(e,t,a,r),t.child;case 11:return a=t.type,i=t.pendingProps,i=t.elementType===a?i:dt(a,i),hh(e,t,a,i,r);case 7:return Se(e,t,t.pendingProps,r),t.child;case 8:return Se(e,t,t.pendingProps.children,r),t.child;case 12:return Se(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(a=t.type._context,i=t.pendingProps,n=t.memoizedProps,s=i.value,K(oo,a._currentValue),a._currentValue=s,n!==null)if(vt(n.value,s)){if(n.children===i.children&&!Fe.current){t=$t(e,t,r);break e}}else for(n=t.child,n!==null&&(n.return=t);n!==null;){var l=n.dependencies;if(l!==null){s=n.child;for(var d=l.firstContext;d!==null;){if(d.context===a){if(n.tag===1){d=Ut(-1,r&-r),d.tag=2;var c=n.updateQueue;if(c!==null){c=c.shared;var h=c.pending;h===null?d.next=d:(d.next=h.next,h.next=d),c.pending=d}}n.lanes|=r,d=n.alternate,d!==null&&(d.lanes|=r),wl(n.return,r,t),l.lanes|=r;break}d=d.next}}else if(n.tag===10)s=n.type===t.type?null:n.child;else if(n.tag===18){if(s=n.return,s===null)throw Error(I(341));s.lanes|=r,l=s.alternate,l!==null&&(l.lanes|=r),wl(s,r,t),s=n.sibling}else s=n.child;if(s!==null)s.return=n;else for(s=n;s!==null;){if(s===t){s=null;break}if(n=s.sibling,n!==null){n.return=s.return,s=n;break}s=s.return}n=s}Se(e,t,i.children,r),t=t.child}return t;case 9:return i=t.type,a=t.pendingProps.children,ba(t,r),i=nt(i),a=a(i),t.flags|=1,Se(e,t,a,r),t.child;case 14:return a=t.type,i=dt(a,t.pendingProps),i=dt(a.type,i),uh(e,t,a,i,r);case 15:return hf(e,t,t.type,t.pendingProps,r);case 17:return a=t.type,i=t.pendingProps,i=t.elementType===a?i:dt(a,i),Qn(e,t),t.tag=1,Qe(a)?(e=!0,ao(t)):e=!1,ba(t,r),lf(t,a,i),kl(t,a,i,r),El(null,t,a,!0,e,r);case 19:return gf(e,t,r);case 22:return uf(e,t,r)}throw Error(I(156,t.tag))};function qf(e,t){return im(e,t)}function Zb(e,t,r,a){this.tag=e,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=a,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function at(e,t,r,a){return new Zb(e,t,r,a)}function Wd(e){return e=e.prototype,!(!e||!e.isReactComponent)}function ew(e){if(typeof e=="function")return Wd(e)?1:0;if(e!=null){if(e=e.$$typeof,e===nd)return 11;if(e===od)return 14}return 2}function wr(e,t){var r=e.alternate;return r===null?(r=at(e.tag,t,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&14680064,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.depen
vendor: 8,697 bytes, line 40
40dencies,r.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r}function Bn(e,t,r,a,i,n){var s=2;if(a=e,typeof e=="function")Wd(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case ia:return Ur(r.children,i,n,t);case id:s=8,i|=8;break;case Vs:return e=at(12,r,t,i|2),e.elementType=Vs,e.lanes=n,e;case Hs:return e=at(13,r,t,i),e.elementType=Hs,e.lanes=n,e;case $s:return e=at(19,r,t,i),e.elementType=$s,e.lanes=n,e;case zp:return No(r,i,n,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Qp:s=10;break e;case Wp:s=9;break e;case nd:s=11;break e;case od:s=14;break e;case rr:s=16,a=null;break e}throw Error(I(130,e==null?e:typeof e,""))}return t=at(s,r,t,i),t.elementType=e,t.type=a,t.lanes=n,t}function Ur(e,t,r,a){return e=at(7,e,a,t),e.lanes=r,e}function No(e,t,r,a){return e=at(22,e,a,t),e.elementType=zp,e.lanes=r,e.stateNode={isHidden:!1},e}function Ms(e,t,r){return e=at(6,e,null,t),e.lanes=r,e}function Ss(e,t,r){return t=at(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function tw(e,t,r,a,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=ss(0),this.expirationTimes=ss(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=ss(0),this.identifierPrefix=a,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function zd(e,t,r,a,i,n,s,l,d){return e=new tw(e,t,r,l,d),t===1?(t=1,n===!0&&(t|=8)):t=0,n=at(3,null,null,t),e.current=n,n.stateNode=e,n.memoizedState={element:a,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},Td(n),e}function rw(e,t,r){var a=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:aa,key:a==null?null:""+a,children:e,containerInfo:t,implementation:r}}function Pf(e){if(!e)return Ar;e=e._reactInternals;e:{if(ea(e)!==e||e.tag!==1)throw Error(I(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Qe(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(I(171))}if(e.tag===1){var r=e.type;if(Qe(r))return qm(e,r,t)}return t}function Df(e,t,r,a,i,n,s,l,d){return e=zd(r,a,!0,e,i,n,s,l,d),e.context=Pf(null),r=e.current,a=Re(),i=br(r),n=Ut(a,i),n.callback=t??null,vr(r,n,i),e.current.lanes=i,Ji(e,i,a),We(e,a),e}function Oo(e,t,r,a){var i=t.current,n=Re(),s=br(i);return r=Pf(r),t.context===null?t.context=r:t.pendingContext=r,t=Ut(n,s),t.payload={element:e},a=a===void 0?null:a,a!==null&&(t.callback=a),e=vr(i,t,s),e!==null&&(gt(e,i,s,n),Nn(e,i,s)),s}function vo(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function Th(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var r=e.retryLane;e.retryLane=r!==0&&r<t?r:t}}function Bd(e,t){Th(e,t),(e=e.alternate)&&Th(e,t)}function aw(){return null}var Lf=typeof reportError=="function"?reportError:function(e){console.error(e)};function _d(e){this._internalRoot=e}Fo.prototype.render=_d.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(I(409));Oo(e,t,null,null)};Fo.prototype.unmount=_d.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Kr(function(){Oo(null,e,null,null)}),t[Vt]=null}};function Fo(e){this._internalRoot=e}Fo.prototype.unstable_scheduleHydration=function(e){if(e){var t=hm();e={blockedOn:null,target:e,priority:t};for(var r=0;r<ir.length&&t!==0&&t<ir[r].priority;r++);ir.splice(r,0,e),r===0&&pm(e)}};function Ud(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Qo(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function Eh(){}function iw(e,t,r,a,i){if(i){if(typeof a=="function"){var n=a;a=function(){var c=vo(s);n.call(c)}}var s=Df(t,a,e,0,null,!1,!1,"",Eh);return e._reactRootContainer=s,e[Vt]=s.current,Pi(e.nodeType===8?e.parentNode:e),Kr(),s}for(;i=e.lastChild;)e.removeChild(i);if(typeof a=="function"){var l=a;a=function(){var c=vo(d);l.call(c)}}var d=zd(e,0,!1,null,null,!1,!1,"",Eh);return e._reactRootContainer=d,e[Vt]=d.current,Pi(e.nodeType===8?e.parentNode:e),Kr(function(){Oo(t,d,r,a)}),d}function Wo(e,t,r,a,i){var n=r._reactRootContainer;if(n){var s=n;if(typeof i=="function"){var l=i;i=function(){var d=vo(s);l.call(d)}}Oo(t,s,e,i)}else s=iw(r,t,e,i,a);return vo(s)}dm=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var r=pi(t.pendingLanes);r!==0&&(dd(t,r|1),We(t,ce()),!(X&6)&&(Qa=ce()+500,Ir()))}break;case 13:Kr(function(){var a=Ht(e,1);if(a!==null){var i=Re();gt(a,e,1,i)}}),Bd(e,1)}};cd=function(e){if(e.tag===13){var t=Ht(e,134217728);if(t!==null){var r=Re();gt(t,e,134217728,r)}Bd(e,134217728)}};cm=function(e){if(e.tag===13){var t=br(e),r=Ht(e,t);if(r!==null){var a=Re();gt(r,e,t,a)}Bd(e,t)}};hm=function(){return G};um=function(e,t){var r=G;try{return G=e,t()}finally{G=r}};il=function(e,t,r){switch(t){case"input":if(Ys(e,r),t=r.name,r.type==="radio"&&t!=null){for(r=e;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<r.length;t++){var a=r[t];if(a!==e&&a.form===e.form){var i=Ro(a);if(!i)throw Error(I(90));_p(a),Ys(a,i)}}}break;case"textarea":Xp(e,r);break;case"select":t=r.value,t!=null&&fa(e,!!r.multiple,t,!1)}};Jp=Od;Zp=Kr;var nw={usingClientEntryPoint:!1,Events:[en,la,Ro,Kp,Yp,Od]},oi={findFiberByHostInstance:Nr,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},ow={bundleType:oi.bundleType,version:oi.version,rendererPackageName:oi.rendererPackageName,rendererConfig:oi.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Yt.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=rm(e),e===null?null:e.stateNode},findFiberByHostInstance:oi.findFiberByHostInstance||aw,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Tn=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Tn.isDisabled&&Tn.supportsFiber)try{Mo=Tn.inject(ow),St=Tn}catch{}}Ye.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=nw;Ye.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Ud(t))throw Error(I(200));return rw(e,t,null,r)};Ye.createRoot=function(e,t){if(!Ud(e))throw Error(I(299));var r=!1,a="",i=Lf;return t!=null&&(t.unstable_strictMode===!0&&(r=!0),t.identifierPrefix!==void 0&&(a=t.identifierPrefix),t.onRecoverableError!==void 0&&(i=t.onRecoverableError)),t=zd(e,1,!1,null,null,r,!1,a,i),e[Vt]=t.current,Pi(e.nodeType===8?e.parentNode:e),new _d(t)};Ye.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(I(188)):(e=Object.keys(e).join(","),Error(I(268,e)));return e=rm(t),e=e===null?null:e.stateNode,e};Ye.flushSync=function(e){return Kr(e)};Ye.hydrate=function(e,t,r){if(!Qo(t))throw Error(I(200));return Wo(null,e,t,!0,r)};Ye.hydrateRoot=function(e,t,r){if(!Ud(e))throw Error(I(405));var a=r!=null&&r.hydratedSources||null,i=!1,n="",s=Lf;if(r!=null&&(r.unstable_strictMode===!0&&(i=!0),r.identifierPrefix!==void 0&&(n=r.identifierPrefix),r.onRecoverableError!==void 0&&(s=r.onRecoverableError)),t=Df(t,null,e,1,r??null,i,!1,n,s),e[Vt]=t.current,Pi(e),a)for(e=0;e<a.length;e++)r=a[e],i=r._getVersion,i=i(r._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[r,i]:t.mutableSourceEagerHydrationData.push(r,i);return new Fo(t)};Ye.render=function(e,t,r){if(!Qo(t))throw Error(I(200));return Wo(null,e,t,!1,r)};Ye.unmountComponentAtNode=function(e){if(!Qo(e))throw Error(I(40));return e._reactRootContainer?(Kr(function(){Wo(null,null,e,!1,function(){e._reactRootContainer=null,e[Vt]=null})}),!0):!1};Ye.unstable_batchedUpdates=Od;Ye.unstable_renderSubtreeIntoContainer=function(e,t,r,a){if(!Qo(r))throw Error(I(200));if(e==null||e._reactInternals===void 0)throw Error(I(38));return Wo(e,t,r,!1,a)};
40Ye.version="18.3.1-next-f1338f8080-20240426";function Nf(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Nf)}catch(e){console.error(e)}}Nf(),Lp.exports=Ye;var rn=Lp.exports;const sw=Ua(rn);var Of,Mh=rn;Of=Mh.createRoot,Mh.hydrateRoot;function lw(e,t){if(e instanceof RegExp)return{keys:!1,pattern:e};var r,a,i,n,s=[],l="",d=e.split("/");for(d[0]||d.shift();i=d.shift();)r=i[0],r==="*"?(s.push(r),l+=i[1]==="?"?"(?:/(.*))?":"/(.*)"):r===":"?(a=i.indexOf("?",1),n=i.indexOf(".",1),s.push(i.substring(1,~a?a:~n?n:i.length)),l+=~a&&!~n?"(?:/([^/]+?))?":"/([^/]+?)",~n&&(l+=(~a?"?":"")+"\\"+i.substring(n))):l+="/"+i;return{keys:s,pattern:new RegExp("^"+l+(t?"(?=$|/)":"/?$"),"i")}}var Ff={exports:{}},Qf={};/**
41 * @license React
42 * use-sync-external-store-shim.production.min.js
43 *
44 * Copyright (c) Facebook, Inc. and its affiliates.
45 *
46 * This source code is licensed under the MIT license found in the
47 * LICENSE file in the root directory of this source tree.
48 */var Wa=w;function dw(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var cw=typeof Object.is=="function"?Object.is:dw,hw=Wa.useState,uw=Wa.useEffect,pw=Wa.useLayoutEffect,mw=Wa.useDebugValue;function fw(e,t){var r=t(),a=hw({inst:{value:r,getSnapshot:t}}),i=a[0].inst,n=a[1];return pw(function(){i.value=r,i.getSnapshot=t,Cs(i)&&n({inst:i})},[e,r,t]),uw(function(){return Cs(i)&&n({inst:i}),e(function(){Cs(i)&&n({inst:i})})},[e]),mw(r),r}function Cs(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!cw(e,r)}catch{return!0}}function gw(e,t){return t()}var vw=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?gw:fw;Qf.useSyncExternalStore=Wa.useSyncExternalStore!==void 0?Wa.useSyncExternalStore:vw;Ff.exports=Qf;var yw=Ff.exports;const bw=Kv.useInsertionEffect,ww=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",xw=ww?w.useLayoutEffect:w.useEffect,kw=bw||xw,Wf=e=>{const t=w.useRef([e,(...r)=>t[0](...r)]).current;return kw(()=>{t[0]=e}),t[1]},Aw="popstate",Xd="pushState",Vd="replaceState",Tw="hashchange",Sh=[Aw,Xd,Vd,Tw],Ew=e=>{for(const t of Sh)addEventListener(t,e);return()=>{for(const t of Sh)removeEventListener(t,e)}},zf=(e,t)=>yw.useSyncExternalStore(Ew,e,t),Mw=()=>location.search,Sw=({ssrSearch:e=""}={})=>zf(Mw,()=>e),Ch=()=>location.pathname,Cw=({ssrPath:e}={})=>zf(Ch,e?()=>e:Ch),Iw=(e,{replace:t=!1,state:r=null}={})=>history[t?Vd:Xd](r,"",e),Rw=(e={})=>[Cw(e),Iw],Ih=Symbol.for("wouter_v3");if(typeof history<"u"&&typeof window[Ih]>"u"){for(const e of[Xd,Vd]){const t=history[e];history[e]=function(){const r=t.apply(this,arguments),a=new Event(e);return a.arguments=arguments,dispatchEvent(a),r}}Object.defineProperty(window,Ih,{value:!0})}const jw=(e,t)=>t.toLowerCase().indexOf(e.toLowerCase())?"~"+t:t.slice(e.length)||"/",Bf=(e="")=>e==="/"?"":e,qw=(e,t)=>e[0]==="~"?e.slice(1):Bf(t)+e,Pw=(e="",t)=>jw(Rh(Bf(e)),Rh(t)),Rh=e=>{try{return decodeURI(e)}catch{return e}},_f={hook:Rw,searchHook:Sw,parser:lw,base:"",ssrPath:void 0,ssrSearch:void 0,hrefs:e=>e},Uf=w.createContext(_f),an=()=>w.useContext(Uf),Xf={},Vf=w.createContext(Xf),Hf=()=>w.useContext(Vf),zo=e=>{const[t,r]=e.hook(e);return[Pw(e.base,t),Wf((a,i)=>r(qw(a,e.base),i))]},$f=()=>zo(an()),Gf=(e,t,r,a)=>{const{pattern:i,keys:n}=t instanceof RegExp?{keys:!1,pattern:t}:e(t||"*",a),s=i.exec(r)||[],[l,...d]=s;return l!==void 0?[!0,(()=>{const c=n!==!1?Object.fromEntries(n.map((u,p)=>[u,d[p]])):s.groups;let h={...d};return c&&Object.assign(h,c),h})(),...a?[l]:[]]:[!1,null]},Dw=({children:e,...t})=>{var h,u;const r=an(),a=t.hook?_f:r;let i=a;const[n,s]=((h=t.ssrPath)==null?void 0:h.split("?"))??[];s&&(t.ssrSearch=s,t.ssrPath=n),t.hrefs=t.hrefs??((u=t.hook)==null?void 0:u.hrefs);let l=w.useRef({}),d=l.current,c=d;for(let p in a){const v=p==="base"?a[p]+(t[p]||""):t[p]||a[p];d===c&&v!==c[p]&&(l.current=c={...c}),c[p]=v,v!==a[p]&&(i=c)}return w.createElement(Uf.Provider,{value:i,children:e})},jh=({children:e,component:t},r)=>t?w.createElement(t,{params:r}):typeof e=="function"?e(r):e,Lw=e=>{let t=w.useRef(Xf),r=t.current;for(const a in e)e[a]!==r[a]&&(r=e);return Object.keys(e).length===0&&(r=e),t.current=r},Lt=({path:e,nest:t,match:r,...a})=>{const i=an(),[n]=zo(i),[s,l,d]=r??Gf(i.parser,e,n,t),c=Lw({...Hf(),...l});if(!s)return null;const h=d?w.createElement(Dw,{base:d},jh(a,c)):jh(a,c);return w.createElement(Vf.Provider,{value:c,children:h})},Z=w.forwardRef((e,t)=>
48{const r=an(),[a,i]=zo(r),{to:n="",href:s=n,onClick:l,asChild:d,children:c,className:h,replace:u,state:p,...v}=e,b=Wf(x=>{x.ctrlKey||x.metaKey||x.altKey||x.shiftKey||x.button!==0||(l==null||l(x),x.defaultPrevented||(x.preventDefault(),i(s,e)))}),y=r.hrefs(s[0]==="~"?s.slice(1):r.base+s,r);return d&&w.isValidElement(c)?w.cloneElement(c,{onClick:b,href:y}):w.createElement("a",{...v,onClick:b,href:y,className:h!=null&&h.call?h(a===s):h,children:c,ref:t})}),Kf=e=>Array.isArray(e)?e.flatMap(t=>Kf(t&&t.type===w.Fragment?t.props.children:t)):[e],Nw=({children:e,location:t})=>{const r=an(),[a]=zo(r);for(const i of Kf(e)){let n=0;if(w.isValidElement(i)&&(n=Gf(r.parser,i.props.path,t||a,i.props.nest))[0])return w.cloneElement(i,{match:n})}return null};var Bo=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},_o=typeof window>"u"||"Deno"in globalThis;function ct(){}function Ow(e,t){return typeof e=="function"?e(t):e}function Fw(e){return typeof e=="number"&&e>=0&&e!==1/0}function Qw(e,t){return Math.max(e+(t||0)-Date.now(),0)}function qh(e,t){return typeof e=="function"?e(t):e}function Ww(e,t){return typeof e=="function"?e(t):e}function Ph(e,t){const{type:r="all",exact:a,fetchStatus:i,predicate:n,queryKey:s,stale:l}=e;if(s){if(a){if(t.queryHash!==Hd(s,t.options))return!1}else if(!_i(t.queryKey,s))return!1}if(r!=="all"){const d=t.isActive();if(r==="active"&&!d||r==="inactive"&&d)return!1}return!(typeof l=="boolean"&&t.isStale()!==l||i&&i!==t.state.fetchStatus||n&&!n(t))}function Dh(e,t){const{exact:r,status:a,predicate:i,mutationKey:n}=e;if(n){if(!t.options.mutationKey)return!1;if(r){if(Bi(t.options.mutationKey)!==Bi(n))return!1}else if(!_i(t.options.mutationKey,n))return!1}return!(a&&t.state.status!==a||i&&!i(t))}function Hd(e,t){return((t==null?void 0:t.queryKeyHashFn)||Bi)(e)}function Bi(e){return JSON.stringify(e,(t,r)=>Ol(r)?Object.keys(r).sort().reduce((a,i)=>(a[i]=r[i],a),{}):r)}function _i(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(r=>!_i(e[r],t[r])):!1}function Yf(e,t){if(e===t)return e;const r=Lh(e)&&Lh(t);if(r||Ol(e)&&Ol(t)){const a=r?e:Object.keys(e),i=a.length,n=r?t:Object.keys(t),s=n.length,l=r?[]:{};let d=0;for(let c=0;c<s;c++){const h=r?c:n[c];(!r&&a.includes(h)||r)&&e[h]===void 0&&t[h]===void 0?(l[h]=void 0,d++):(l[h]=Yf(e[h],t[h]),l[h]===e[h]&&e[h]!==void 0&&d++)}return i===s&&d===i?e:l}return t}function Lh(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Ol(e){if(!Nh(e))return!1;const t=e.constructor;if(t===void 0)return!0;const r=t.prototype;return!(!Nh(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function Nh(e){return Object.prototype.toString.call(e)==="[object Object]"}function zw(e){return new Promise(t=>{setTimeout(t,e)})}function Bw(e,t,r){return typeof r.structuralSharing=="function"?r.structuralSharing(e,t):r.structuralSharing!==!1?Yf(e,t):t}function _w(e,t,r=0){const a=[...e,t];return r&&a.length>r?a.slice(1):a}function Uw(e,t,r=0){const a=[t,...e];return r&&a.length>r?a.slice(0,-1):a}var $d=Symbol();function Jf(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===$d?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var Qr,or,Ta,gp,Xw=(gp=class extends Bo{constructor(){super();$(this,Qr);$(this,or);$(this,Ta);Q(this,Ta,t=>{if(!_o&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){M(this,or)||this.setEventListener(M(this,Ta))}onUnsubscribe(){var t;this.hasListeners()||((t=M(this,or))==null||t.call(this),Q(this,or,void 0))}setEventListener(t){var r;Q(this,Ta,t),(r=M(this,or))==null||r.call(this),Q(this,or,t(a=>{typeof a=="boolean"?this.setFocused(a):this.onFocus()}))}setFocused(t){M(this,Qr)!==t&&(Q(this,Qr,t),this.onFocus())}onFocus(){const t=this.isFocused();
vendor: 20,856 bytes, line 48
48this.listeners.forEach(r=>{r(t)})}isFocused(){var t;return typeof M(this,Qr)=="boolean"?M(this,Qr):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},Qr=new WeakMap,or=new WeakMap,Ta=new WeakMap,gp),Zf=new Xw,Ea,sr,Ma,vp,Vw=(vp=class extends Bo{constructor(){super();$(this,Ea,!0);$(this,sr);$(this,Ma);Q(this,Ma,t=>{if(!_o&&window.addEventListener){const r=()=>t(!0),a=()=>t(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",a,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",a)}}})}onSubscribe(){M(this,sr)||this.setEventListener(M(this,Ma))}onUnsubscribe(){var t;this.hasListeners()||((t=M(this,sr))==null||t.call(this),Q(this,sr,void 0))}setEventListener(t){var r;Q(this,Ma,t),(r=M(this,sr))==null||r.call(this),Q(this,sr,t(this.setOnline.bind(this)))}setOnline(t){M(this,Ea)!==t&&(Q(this,Ea,t),this.listeners.forEach(a=>{a(t)}))}isOnline(){return M(this,Ea)}},Ea=new WeakMap,sr=new WeakMap,Ma=new WeakMap,vp),yo=new Vw;function Hw(){let e,t;const r=new Promise((i,n)=>{e=i,t=n});r.status="pending",r.catch(()=>{});function a(i){Object.assign(r,i),delete r.resolve,delete r.reject}return r.resolve=i=>{a({status:"fulfilled",value:i}),e(i)},r.reject=i=>{a({status:"rejected",reason:i}),t(i)},r}function $w(e){return Math.min(1e3*2**e,3e4)}function eg(e){return(e??"online")==="online"?yo.isOnline():!0}var tg=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Is(e){return e instanceof tg}function rg(e){let t=!1,r=0,a=!1,i;const n=Hw(),s=y=>{var x;a||(p(new tg(y)),(x=e.abort)==null||x.call(e))},l=()=>{t=!0},d=()=>{t=!1},c=()=>Zf.isFocused()&&(e.networkMode==="always"||yo.isOnline())&&e.canRun(),h=()=>eg(e.networkMode)&&e.canRun(),u=y=>{var x;a||(a=!0,(x=e.onSuccess)==null||x.call(e,y),i==null||i(),n.resolve(y))},p=y=>{var x;a||(a=!0,(x=e.onError)==null||x.call(e,y),i==null||i(),n.reject(y))},v=()=>new Promise(y=>{var x;i=f=>{(a||c())&&y(f)},(x=e.onPause)==null||x.call(e)}).then(()=>{var y;i=void 0,a||(y=e.onContinue)==null||y.call(e)}),b=()=>{if(a)return;let y;const x=r===0?e.initialPromise:void 0;try{y=x??e.fn()}catch(f){y=Promise.reject(f)}Promise.resolve(y).then(u).catch(f=>{var T;if(a)return;const m=e.retry??(_o?0:3),g=e.retryDelay??$w,k=typeof g=="function"?g(r,f):g,A=m===!0||typeof m=="number"&&r<m||typeof m=="function"&&m(r,f);if(t||!A){p(f);return}r++,(T=e.onFail)==null||T.call(e,r,f),zw(k).then(()=>c()?void 0:v()).then(()=>{t?p(f):b()})})};return{promise:n,cancel:s,continue:()=>(i==null||i(),n),cancelRetry:l,continueRetry:d,canStart:h,start:()=>(h()?b():v().then(b),n)}}function Gw(){let e=[],t=0,r=l=>{l()},a=l=>{l()},i=l=>setTimeout(l,0);const n=l=>{t?e.push(l):i(()=>{r(l)})},s=()=>{const l=e;e=[],l.length&&i(()=>{a(()=>{l.forEach(d=>{r(d)})})})};return{batch:l=>{let d;t++;try{d=l()}finally{t--,t||s()}return d},batchCalls:l=>(...d)=>{n(()=>{l(...d)})},schedule:n,setNotifyFunction:l=>{r=l},setBatchNotifyFunction:l=>{a=l},setScheduler:l=>{i=l}}}var Ce=Gw(),Wr,yp,ag=(yp=class{constructor(){$(this,Wr)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Fw(this.gcTime)&&Q(this,Wr,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(_o?1/0:5*60*1e3))}clearGcTimeout(){M(this,Wr)&&(clearTimeout(M(this,Wr)),Q(this,Wr,void 0))}},Wr=new WeakMap,yp),Sa,Ca,et,Ae,Gi,zr,ht,Ft,bp,Kw=(bp=class extends ag{constructor(t){super();$(this,ht);$(this,Sa);$(this,Ca);$(this,et);$(this,Ae);$(this,Gi);$(this,zr);Q(this,zr,!1),Q(this,Gi,t.defaultOptions),this.setOptions(t.options),this.observers=[],Q(this,et,t.cache),this.queryKey=t.queryKey,this.queryHash=t.queryHash,Q(this,Sa,Jw(this.options)),this.state=t.state??M(this,Sa),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=M(this,Ae))==null?void 0:t.promise}setOptions(t){this.options={...M(this,Gi),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&M(this,et).remove(this)}setData(t,r){const a=Bw(this.state.data,t,this.options);return we(this,ht,Ft).call(this,{data:a,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),a}setState(t,r){we(this,ht,Ft).call(this,{type:"setState",state:t,setStateOptions:r})}cancel(t){var a,i;const r=(a=M(this,Ae))==null?void 0:a.promise;return(i=M(this,Ae))==null||i.cancel(t),r?r.then(ct).catch(ct):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(M(this,Sa))}isActive(){return this.observers.some(t=>Ww(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===$d||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return this.state.isInvalidated?!0:this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0}isStaleByTime(t=0){return this.state.isInvalidated||this.state.data===void 0||!Qw(this.state.dataUpdatedAt,t)}onFocus(){var r;const t=this.observers.find(a=>a.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(r=M(this,Ae))==null||r.continue()}onOnline(){var r;const t=this.observers.find(a=>a.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(r=M(this,Ae))==null||r.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),M(this,et).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(M(this,Ae)&&(M(this,zr)?M(this,Ae).cancel({revert:!0}):M(this,Ae).cancelRetry()),this.scheduleGc()),M(this,et).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||we(this,ht,Ft).call(this,{type:"invalidate"})}fetch(t,r){var d,c,h;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(M(this,Ae))return M(this,Ae).continueRetry(),M(this,Ae).promise}if(t&&this.setOptions(t),!this.options.queryFn){const u=this.observers.find(p=>p.options.queryFn);u&&this.setOptions(u.options)}const a=new AbortController,i=u=>{Object.defineProperty(u,"signal",{enumerable:!0,get:()=>(Q(this,zr,!0),a.signal)})},n=()=>{const u=Jf(this.options,r),p={queryKey:this.queryKey,meta:this.meta};return i(p),Q(this,zr,!1),this.options.persister?this.options.persister(u,p,this):u(p)},s={fetchOptions:r,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:n};i(s),(d=this.options.behavior)==null||d.onFetch(s,this),Q(this,Ca,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((c=s.fetchOptions)==null?void 0:c.meta))&&we(this,ht,Ft).call(this,{type:"fetch",meta:(h=s.fetchOptions)==null?void 0:h.meta});const l=u=>{var p,v,b,y;Is(u)&&u.silent||we(this,ht,Ft).call(this,{type:"error",error:u}),Is(u)||((v=(p=M(this,et).config).onError)==null||v.call(p,u,this),(y=(b=M(this,et).config).onSettled)==null||y.call(b,this.state.data,u,this)),this.scheduleGc()};return Q(this,Ae,rg({initialPromise:r==null?void 0:r.initialPromise,fn:s.fetchFn,abort:a.abort.bind(a),onSuccess:u=>{var p,v,b,y;if(u===void 0){l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(u)}catch(x){l(x);return}(v=(p=M(this,et).config).onSuccess)==null||v.call(p,u,this),(y=(b=M(this,et).config).onSettled)==null||y.call(b,u,this.state.error,this),this.scheduleGc()},onError:l,onFail:(u,p)=>{we(this,ht,Ft).call(this,{type:"failed",failureCount:u,error:p})},onPause:()=>{we(this,ht,Ft).call(this,{type:"pause"})},onContinue:()=>{we(this,ht,Ft).call(this,{type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode,canRun:()=>!0})),M(this,Ae).start()}},Sa=new WeakMap,Ca=new WeakMap,et=new WeakMap,Ae=new WeakMap,Gi=new WeakMap,zr=new WeakMap,ht=new WeakSet,Ft=function(t){const r=a=>{switch(t.type){case"failed":return{...a,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...a,fetchStatus:"paused"};case"continue":return{...a,fetchStatus:"fetching"};case"fetch":return{...a,...Yw(a.data,this.options),fetchMeta:t.meta??null};case"success":return{...a,data:t.data,dataUpdateCount:a.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const i=t.error;return Is(i)&&i.revert&&M(this,Ca)?{...M(this,Ca),fetchStatus:"idle"}:{...a,error:i,errorUpdateCount:a.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:a.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...a,isInvalidated:!0};case"setState":return{...a,...t.state}}};this.state=r(this.state),Ce.batch(()=>{this.observers.forEach(a=>{a.onQueryUpdate()}),M(this,et).notify({query:this,type:"updated",action:t})})},bp);function Yw(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:eg(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function Jw(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,r=t!==void 0,a=r?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?a??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var At,wp,Zw=(wp=class extends Bo{constructor(t={}){super();$(this,At);this.config=t,Q(this,At,new Map)}build(t,r,a){const i=r.queryKey,n=r.queryHash??Hd(i,r);let s=this.get(n);return s||(s=new Kw({cache:this,queryKey:i,queryHash:n,options:t.defaultQueryOptions(r),state:a,defaultOptions:t.getQueryDefaults(i)}),this.add(s)),s}add(t){M(this,At).has(t.queryHash)||(M(this,At).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const r=M(this,At).get(t.queryHash);r&&(t.destroy(),r===t&&M(this,At).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Ce.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return M(this,At).get(t)}getAll(){return[...M(this,At).values()]}find(t){const r={exact:!0,...t};return this.getAll().find(a=>Ph(r,a))}findAll(t={}){const r=this.getAll();return Object.keys(t).length>0?r.filter(a=>Ph(t,a)):r}notify(t){Ce.batch(()=>{this.listeners.forEach(r=>{r(t)})})}onFocus(){Ce.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Ce.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},At=new WeakMap,wp),Tt,Me,Br,Et,tr,xp,ex=(xp=class extends ag{constructor(t){super();$(this,Et);$(this,Tt);$(this,Me);$(this,Br);this.mutationId=t.mutationId,Q(this,Me,t.mutationCache),Q(this,Tt,[]),this.state=t.state||tx(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){M(this,Tt).includes(t)||(M(this,Tt).push(t),this.clearGcTimeout(),M(this,Me).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){Q(this,Tt,M(this,Tt).filter(r=>r!==t)),this.scheduleGc(),M(this,Me).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){M(this,Tt).length||(this.state.status==="pending"?this.scheduleGc():M(this,Me).remove(this))}continue(){var t;return((t=M(this,Br))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var i,n,s,l,d,c,h,u,p,v,b,y,x,f,m,g,k,A,T,E;Q(this,Br,rg({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(C,D)=>{we(this,Et,tr).call(this,{type:"failed",failureCount:C,error:D})},onPause:()=>{we(this,Et,tr).call(this,{type:"pause"})},onContinue:()=>{we(this,Et,tr).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>M(this,Me).canRun(this)}));const r=this.state.status==="pending",a=!M(this,Br).canStart();try{if(!r){we(this,Et,tr).call(this,{type:"pending",variables:t,isPaused:a}),await((n=(i=M(this,Me).config).onMutate)==null?void 0:n.call(i,t,this));const D=await((l=(s=this.options).onMutate)==null?void 0:l.call(s,t));D!==this.state.context&&we(this,Et,tr).call(this,{type:"pending",context:D,variables:t,isPaused:a})}const C=await M(this,Br).start();return await((c=(d=M(this,Me).config).onSuccess)==null?void 0:c.call(d,C,t,this.state.context,this)),await((u=(h=this.options).onSuccess)==null?void 0:u.call(h,C,t,this.state.context)),await((v=(p=M(this,Me).config).onSettled)==null?void 0:v.call(p,C,null,this.state.variables,this.state.context,this)),await((y=(b=this.options).onSettled)==null?void 0:y.call(b,C,null,t,this.state.context)),we(this,Et,tr).call(this,{type:"success",data:C}),C}catch(C){try{throw await((f=(x=M(this,Me).config).onError)==null?void 0:f.call(x,C,t,this.state.context,this)),await((g=(m=this.options).onError)==null?void 0:g.call(m,C,t,this.state.context)),await((A=(k=M(this,Me).config).onSettled)==null?void 0:A.call(k,void 0,C,this.state.variables,this.state.context,this)),await((E=(T=this.options).onSettled)==null?void 0:E.call(T,void 0,C,t,this.state.context)),C}finally{we(this,Et,tr).call(this,{type:"error",error:C})}}finally{M(this,Me).runNext(this)}}},Tt=new WeakMap,Me=new WeakMap,Br=new WeakMap,Et=new WeakSet,tr=function(t){const r=a=>{switch(t.type){case"failed":return{...a,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...a,isPaused:!0};case"continue":return{...a,isPaused:!1};case"pending":return{...a,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...a,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...a,data:void 0,error:t.error,failureCount:a.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Ce.batch(()=>{M(this,Tt).forEach(a=>{a.onMutationUpdate(t)}),M(this,Me).notify({mutation:this,type:"updated",action:t})})},xp);function tx(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var _e,Ki,kp,rx=(kp=class extends Bo{constructor(t={}){super();$(this,_e);$(this,Ki);this.config=t,Q(this,_e,new Map),Q(this,Ki,Date.now())}build(t,r,a){const i=new ex({mutationCache:this,mutationId:++sn(this,Ki)._,options:t.defaultMutationOptions(r),state:a});return this.add(i),i}add(t){const r=En(t),a=M(this,_e).get(r)??[];a.push(t),M(this,_e).set(r,a),this.notify({type:"added",mutation:t})}remove(t){var a;const r=En(t);if(M(this,_e).has(r)){const i=(a=M(this,_e).get(r))==null?void 0:a.filter(n=>n!==t);i&&(i.length===0?M(this,_e).delete(r):M(this,_e).set(r,i))}this.notify({type:"removed",mutation:t})}canRun(t){var a;const r=(a=M(this,_e).get(En(t)))==null?void 0:a.find(i=>i.state.status==="pending");return!r||r===t}runNext(t){var a;const r=(a=M(this,_e).get(En(t)))==null?void 0:a.find(i=>i!==t&&i.state.isPaused);return(r==null?void 0:r.continue())??Promise.resolve()}clear(){Ce.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}getAll(){return[...M(this,_e).values()].flat()}find(t){const r={exact:!0,...t};return this.getAll().find(a=>Dh(r,a))}findAll(t={}){return this.getAll().filter(r=>Dh(t,r))}notify(t){Ce.batch(()=>{this.listeners.forEach(r=>{r(t)})})}resumePausedMutations(){const t=this.getAll().filter(r=>r.state.isPaused);return Ce.batch(()=>Promise.all(t.map(r=>r.continue().catch(ct))))}},_e=new WeakMap,Ki=new WeakMap,kp);function En(e){var t;return((t=e.options.scope)==null?void 0:t.id)??String(e.mutationId)}function Oh(e){return{onFetch:(t,r)=>{var h,u,p,v,b;const a=t.options,i=(p=(u=(h=t.fetchOptions)==null?void 0:h.meta)==null?void 0:u.fetchMore)==null?void 0:p.direction,n=((v=t.state.data)==null?void 0:v.pages)||[],s=((b=t.state.data)==null?void 0:b.pageParams)||[];let l={pages:[],pageParams:[]},d=0;const c=async()=>{let y=!1;const x=g=>{Object.defineProperty(g,"signal",{enumerable:!0,get:()=>(t.signal.aborted?y=!0:t.signal.addEventListener("abort",()=>{y=!0}),t.signal)})},f=Jf(t.options,t.fetchOptions),m=async(g,k,A)=>{if(y)return Promise.reject();if(k==null&&g.pages.length)return Promise.resolve(g);const T={queryKey:t.queryKey,pageParam:k,direction:A?"backward":"forward",meta:t.options.meta};x(T);const E=await f(T),{maxPages:C}=t.options,D=A?Uw:_w;return{pages:D(g.pages,E,C),pageParams:D(g.pageParams,k,C)}};if(i&&n.length){const g=i==="backward",k=g?ax:Fh,A={pages:n,pageParams:s},T=k(a,A);l=await m(A,T,g)}else{const g=e??n.length;do{const k=d===0?s[0]??a.initialPageParam:Fh(a,l);if(d>0&&k==null)break;l=await m(l,k),d++}while(d<g)}return l};t.options.persister?t.fetchFn=()=>{var y,x;return(x=(y=t.options).persister)==null?void 0:x.call(y,c,{queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=c}}}function Fh(e,{pages:t,pageParams:r}){const a=t.length-1;return t.length>0?e.getNextPageParam(t[a],t,r[a],r):void 0}function ax(e,{pages:t,pageParams:r}){var a;return t.length>0?(a=e.getPreviousPageParam)==null?void 0:a.call(e,t[0],t,r[0],r):void 0}var le,lr,dr,Ia,Ra,cr,ja,qa,Ap,ix=(Ap=class{constructor(e={}){$(this,le);$(this,lr);$(this,dr);$(this,Ia);$(this,Ra);$(this,cr);$(this,ja);$(this,qa);Q(this,le,e.queryCache||new Zw),Q(this,lr,e.mutationCache||new rx),Q(this,dr,e.defaultOptions||{}),Q(this,Ia,new Map),Q(this,Ra,new Map),Q(this,cr,0)}mount(){sn(this,cr)._++,M(this,cr)===1&&(Q(this,ja,Zf.subscribe(async e=>{e&&(await this.resumePausedMutations(),M(this,le).onFocus())})),Q(this,qa,yo.subscribe(async e=>{e&&(await this.resumePausedMutations(),M(this,le).onOnline())})))}unmount(){var e,t;sn(this,cr)._--,M(this,cr)===0&&((e=M(this,ja))==null||e.call(this),Q(this,ja,void 0),(t=M(this,qa))==null||t.call(this),Q(this,qa,void 0))}isFetching(e){return M(this,le).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return M(this,lr).findAll({...e,status:"pending"}).length}getQueryData(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=M(this,le).get(t.queryHash))==null?void 0:r.state.data}ensureQueryData(e){const t=this.getQueryData(e.queryKey);if(t===void 0)return this.fetchQuery(e);{const r=this.defaultQueryOptions(e),a=M(this,le).build(this,r);return e.revalidateIfStale&&a.isStaleByTime(qh(r.staleTime,a))&&this.prefetchQuery(r),Promise.resolve(t)}}getQueriesData(e){return M(this,le).findAll(e).map(({queryKey:t,state:r})=>{const a=r.data;return[t,a]})}setQueryData(e,t,r){const a=this.defaultQueryOptions({queryKey:e}),i=M(this,le).get(a.queryHash),n=i==null?void 0:i.state.data,s=Ow(t,n);if(s!==void 0)return M(this,le).build(this,a).setData(s,{...r,manual:!0})}setQueriesData(e,t,r){return Ce.batch(()=>M(this,le).findAll(e).map(({queryKey:a})=>[a,this.setQueryData(a,t,r)]))}getQueryState(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=M(this,le).get(t.queryHash))==null?void 0:r.state}removeQueries(e){const t=M(this,le);Ce.batch(()=>{t.findAll(e).forEach(r=>{t.remove(r)})})}resetQueries(e,t){const r=M(this,le),a={type:"active",...e};return Ce.batch(()=>(r.findAll(e).forEach(i=>{i.reset()}),this.refetchQueries(a,t)))}cancelQueries(e={},t={}){const r={revert:!0,...t},a=Ce.batch(()=>M(this,le).findAll(e).map(i=>i.cancel(r)));return Promise.all(a).then(ct).catch(ct)}invalidateQueries(e={},t={}){return Ce.batch(()=>{if(M(this,le).findAll(e).forEach(a=>{a.invalidate()}),e.refetchType==="none")return Promise.resolve();const r={...e,type:e.refetchType??e.type??"active"};return this.refetchQueries(r,t)})}refetchQueries(e={},t){const r={...t,cancelRefetch:(t==null?void 0:t.cancelRefetch)??!0},a=Ce.batch(()=>M(this,le).findAll(e).filter(i=>!i.isDisabled()).map(i=>{let n=i.fetch(void 0,r);return r.throwOnError||(n=n.catch(ct)),i.state.fetchStatus==="paused"?Promise.resolve():n}));return Promise.all(a).then(ct)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const r=M(this,le).build(this,t);return r.isStaleByTime(qh(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(ct).catch(ct)}fetchInfiniteQuery(e){return e.behavior=Oh(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(ct).catch(ct)}ensureInfiniteQueryData(e){return e.behavior=Oh(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return yo.isOnline()?M(this,lr).resumePausedMutations():Promise.resolve()}getQueryCache(){return M(this,le)}getMutationCache(){return M(this,lr)}getDefaultOptions(){return M(this,dr)}
48setDefaultOptions(e){Q(this,dr,e)}setQueryDefaults(e,t){M(this,Ia).set(Bi(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...M(this,Ia).values()];let r={};return t.forEach(a=>{_i(e,a.queryKey)&&(r={...r,...a.defaultOptions})}),r}setMutationDefaults(e,t){M(this,Ra).set(Bi(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...M(this,Ra).values()];let r={};return t.forEach(a=>{_i(e,a.mutationKey)&&(r={...r,...a.defaultOptions})}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t={...M(this,dr).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=Hd(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.enabled!==!0&&t.queryFn===$d&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...M(this,dr).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){M(this,le).clear(),M(this,lr).clear()}},le=new WeakMap,lr=new WeakMap,dr=new WeakMap,Ia=new WeakMap,Ra=new WeakMap,cr=new WeakMap,ja=new WeakMap,qa=new WeakMap,Ap),nx=w.createContext(void 0),ox=({client:e,children:t})=>(w.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),o.jsx(nx.Provider,{value:e,children:t}));async function sx(e){if(!e.ok){const t=await e.text()||e.statusText;throw new Error(`${e.status}: ${t}`)}}const lx=({on401:e})=>async({queryKey:t})=>{const r=await fetch(t.join("/"),{credentials:"include"});return e==="returnNull"&&r.status===401?null:(await sx(r),await r.json())},dx=new ix({defaultOptions:{queries:{queryFn:lx({on401:"throw"}),refetchInterval:!1,refetchOnWindowFocus:!1,staleTime:1/0,retry:!1},mutations:{retry:!1}}}),cx=1,hx=1e6;let Rs=0;function ux(){return Rs=(Rs+1)%Number.MAX_SAFE_INTEGER,Rs.toString()}const js=new Map,Qh=e=>{if(js.has(e))return;const t=setTimeout(()=>{js.delete(e),Ti({type:"REMOVE_TOAST",toastId:e})},hx);js.set(e,t)},px=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,cx)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(r=>r.id===t.toast.id?{...r,...t.toast}:r)};case"DISMISS_TOAST":{const{toastId:r}=t;return r?Qh(r):e.toasts.forEach(a=>{Qh(a.id)}),{...e,toasts:e.toasts.map(a=>a.id===r||r===void 0?{...a,open:!1}:a)}}case"REMOVE_TOAST":return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(r=>r.id!==t.toastId)}}},_n=[];let Un={toasts:[]};function Ti(e){Un=px(Un,e),_n.forEach(t=>{t(Un)})}function mx({...e}){const t=ux(),r=i=>Ti({type:"UPDATE_TOAST",toast:{...i,id:t}}),a=()=>Ti({type:"DISMISS_TOAST",toastId:t});return Ti({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:i=>{i||a()}}}),{id:t,dismiss:a,update:r}}function fx(){const[e,t]=w.useState(Un);return w.useEffect(()=>(_n.push(t),()=>{const r=_n.indexOf(t);r>-1&&_n.splice(r,1)}),[e]),{...e,toast:mx,dismiss:r=>Ti({type:"DISMISS_TOAST",toastId:r})}}function pe(e,t,{checkForDefaultPrevented:r=!0}={}){return function(i){if(e==null||e(i),r===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function Wh(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function ig(...e){return t=>{let r=!1;const a=e.map(i=>{const n=Wh(i,t);return!r&&typeof n=="function"&&(r=!0),n});if(r)return()=>{for(let i=0;i<a.length;i++){const n=a[i];typeof n=="function"?n():Wh(e[i],null)}}}}function yt(...e){return w.useCallback(ig(...e),e)}function Uo(e,t=[]){let r=[];function a(n,s){const l=w.createContext(s),d=r.length;r=[...r,s];const c=u=>{var f;const{scope:p,children:v,...b}=u,y=((f=p==null?void 0:p[e])==null?void 0:f[d])||l,x=w.useMemo(()=>b,Object.values(b));return o.jsx(y.Provider,{value:x,children:v})};c.displayName=n+"Provider";function h(u,p){var y;const v=((y=p==null?void 0:p[e])==null?void 0:y[d])||l,b=w.useContext(v);if(b)return b;if(s!==void 0)return s;throw new Error(`\`${u}\` must be used within \`${n}\``)}return[c,h]}const i=()=>{const n=r.map(s=>w.createContext(s));return function(l){const d=(l==null?void 0:l[e])||n;return w.useMemo(()=>({[`__scope${e}`]:{...l,[e]:d}}),[l,d])}};return i.scopeName=e,[a,gx(i,...t)]}function gx(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const a=e.map(i=>({useScope:i(),scopeName:i.scopeName}));
vendor: 9,944 bytes, line 48
48return function(n){const s=a.reduce((l,{useScope:d,scopeName:c})=>{const u=d(n)[`__scope${c}`];return{...l,...u}},{});return w.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return r.scopeName=t.scopeName,r}function bo(e){const t=yx(e),r=w.forwardRef((a,i)=>{const{children:n,...s}=a,l=w.Children.toArray(n),d=l.find(wx);if(d){const c=d.props.children,h=l.map(u=>u===d?w.Children.count(c)>1?w.Children.only(null):w.isValidElement(c)?c.props.children:null:u);return o.jsx(t,{...s,ref:i,children:w.isValidElement(c)?w.cloneElement(c,void 0,h):null})}return o.jsx(t,{...s,ref:i,children:n})});return r.displayName=`${e}.Slot`,r}var vx=bo("Slot");function yx(e){const t=w.forwardRef((r,a)=>{const{children:i,...n}=r;if(w.isValidElement(i)){const s=kx(i),l=xx(n,i.props);return i.type!==w.Fragment&&(l.ref=a?ig(a,s):s),w.cloneElement(i,l)}return w.Children.count(i)>1?w.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var ng=Symbol("radix.slottable");function bx(e){const t=({children:r})=>o.jsx(o.Fragment,{children:r});return t.displayName=`${e}.Slottable`,t.__radixId=ng,t}function wx(e){return w.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===ng}function xx(e,t){const r={...t};for(const a in t){const i=e[a],n=t[a];/^on[A-Z]/.test(a)?i&&n?r[a]=(...l)=>{n(...l),i(...l)}:i&&(r[a]=i):a==="style"?r[a]={...i,...n}:a==="className"&&(r[a]=[i,n].filter(Boolean).join(" "))}return{...e,...r}}function kx(e){var a,i;let t=(a=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:a.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function Ax(e){const t=e+"CollectionProvider",[r,a]=Uo(t),[i,n]=r(t,{collectionRef:{current:null},itemMap:new Map}),s=y=>{const{scope:x,children:f}=y,m=Xe.useRef(null),g=Xe.useRef(new Map).current;return o.jsx(i,{scope:x,itemMap:g,collectionRef:m,children:f})};s.displayName=t;const l=e+"CollectionSlot",d=bo(l),c=Xe.forwardRef((y,x)=>{const{scope:f,children:m}=y,g=n(l,f),k=yt(x,g.collectionRef);return o.jsx(d,{ref:k,children:m})});c.displayName=l;const h=e+"CollectionItemSlot",u="data-radix-collection-item",p=bo(h),v=Xe.forwardRef((y,x)=>{const{scope:f,children:m,...g}=y,k=Xe.useRef(null),A=yt(x,k),T=n(h,f);return Xe.useEffect(()=>(T.itemMap.set(k,{ref:k,...g}),()=>void T.itemMap.delete(k))),o.jsx(p,{[u]:"",ref:A,children:m})});v.displayName=h;function b(y){const x=n(e+"CollectionConsumer",y);return Xe.useCallback(()=>{const m=x.collectionRef.current;if(!m)return[];const g=Array.from(m.querySelectorAll(`[${u}]`));return Array.from(x.itemMap.values()).sort((T,E)=>g.indexOf(T.ref.current)-g.indexOf(E.ref.current))},[x.collectionRef,x.itemMap])}return[{Provider:s,Slot:c,ItemSlot:v},b,a]}var Tx=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],ze=Tx.reduce((e,t)=>{const r=bo(`Primitive.${t}`),a=w.forwardRef((i,n)=>{const{asChild:s,...l}=i,d=s?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),o.jsx(d,{...l,ref:n})});return a.displayName=`Primitive.${t}`,{...e,[t]:a}},{});function og(e,t){e&&rn.flushSync(()=>e.dispatchEvent(t))}function Rt(e){const t=w.useRef(e);return w.useEffect(()=>{t.current=e}),w.useMemo(()=>(...r)=>{var a;return(a=t.current)==null?void 0:a.call(t,...r)},[])}function Ex(e,t=globalThis==null?void 0:globalThis.document){const r=Rt(e);w.useEffect(()=>{const a=i=>{i.key==="Escape"&&r(i)};return t.addEventListener("keydown",a,{capture:!0}),()=>t.removeEventListener("keydown",a,{capture:!0})},[r,t])}var Mx="DismissableLayer",Fl="dismissableLayer.update",Sx="dismissableLayer.pointerDownOutside",Cx="dismissableLayer.focusOutside",zh,sg=w.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Gd=w.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:n,onInteractOutside:s,onDismiss:l,...d}=e,c=w.useContext(sg),[h,u]=w.useState(null),p=(h==null?void 0:h.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,v]=w.useState({}),b=yt(t,E=>u(E)),y=Array.from(c.layers),[x]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),f=y.indexOf(x),m=h?y.indexOf(h):-1,g=c.layersWithOutsidePointerEventsDisabled.size>0,k=m>=f,A=Rx(E=>{const C=E.target,D=[...c.branches].some(q=>q.contains(C));!k||D||(i==null||i(E),s==null||s(E),E.defaultPrevented||l==null||l())},p),T=jx(E=>{const C=E.target;[...c.branches].some(q=>q.contains(C))||(n==null||n(E),s==null||s(E),E.defaultPrevented||l==null||l())},p);return Ex(E=>{m===c.layers.size-1&&(a==null||a(E),!E.defaultPrevented&&l&&(E.preventDefault(),l()))},p),w.useEffect(()=>{if(h)return r&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(zh=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(h)),c.layers.add(h),Bh(),()=>{r&&c.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=zh)}},[h,p,r,c]),w.useEffect(()=>()=>{h&&(c.layers.delete(h),c.layersWithOutsidePointerEventsDisabled.delete(h),Bh())},[h,c]),w.useEffect(()=>{const E=()=>v({});return document.addEventListener(Fl,E),()=>document.removeEventListener(Fl,E)},[]),o.jsx(ze.div,{...d,ref:b,style:{pointerEvents:g?k?"auto":"none":void 0,...e.style},onFocusCapture:pe(e.onFocusCapture,T.onFocusCapture),onBlurCapture:pe(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:pe(e.onPointerDownCapture,A.onPointerDownCapture)})});Gd.displayName=Mx;var Ix="DismissableLayerBranch",lg=w.forwardRef((e,t)=>{const r=w.useContext(sg),a=w.useRef(null),i=yt(t,a);return w.useEffect(()=>{const n=a.current;if(n)return r.branches.add(n),()=>{r.branches.delete(n)}},[r.branches]),o.jsx(ze.div,{...e,ref:i})});lg.displayName=Ix;function Rx(e,t=globalThis==null?void 0:globalThis.document){const r=Rt(e),a=w.useRef(!1),i=w.useRef(()=>{});return w.useEffect(()=>{const n=l=>{if(l.target&&!a.current){let d=function(){dg(Sx,r,c,{discrete:!0})};const c={originalEvent:l};l.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=d,t.addEventListener("click",i.current,{once:!0})):d()}else t.removeEventListener("click",i.current);a.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",n)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",n),t.removeEventListener("click",i.current)}},[t,r]),{onPointerDownCapture:()=>a.current=!0}}function jx(e,t=globalThis==null?void 0:globalThis.document){const r=Rt(e),a=w.useRef(!1);return w.useEffect(()=>{const i=n=>{n.target&&!a.current&&dg(Cx,r,{originalEvent:n},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,r]),{onFocusCapture:()=>a.current=!0,onBlurCapture:()=>a.current=!1}}function Bh(){const e=new CustomEvent(Fl);document.dispatchEvent(e)}function dg(e,t,r,{discrete:a}){const i=r.originalEvent.target,n=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&i.addEventListener(e,t,{once:!0}),a?og(i,n):i.dispatchEvent(n)}var qx=Gd,Px=lg,Yr=globalThis!=null&&globalThis.document?w.useLayoutEffect:()=>{},Dx="Portal",cg=w.forwardRef((e,t)=>{var l;const{container:r,...a}=e,[i,n]=w.useState(!1);Yr(()=>n(!0),[]);const s=r||i&&((l=globalThis==null?void 0:globalThis.document)==null?void 0:l.body);return s?sw.createPortal(o.jsx(ze.div,{...a,ref:t}),s):null});cg.displayName=Dx;function Lx(e,t){return w.useReducer((r,a)=>t[r][a]??r,e)}var Kd=e=>{const{present:t,children:r}=e,a=Nx(t),i=typeof r=="function"?r({present:a.isPresent}):w.Children.only(r),n=yt(a.ref,Ox(i));return typeof r=="function"||a.isPresent?w.cloneElement(i,{ref:n}):null};Kd.displayName="Presence";function Nx(e){const[t,r]=w.useState(),a=w.useRef({}),i=w.useRef(e),n=w.useRef("none"),s=e?"mounted":"unmounted",[l,d]=Lx(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return w.useEffect(()=>{const c=Mn(a.current);n.current=l==="mounted"?c:"none"},[l]),Yr(()=>{const c=a.current,h=i.current;if(h!==e){const p=n.current,v=Mn(c);e?d("MOUNT"):v==="none"||(c==null?void 0:c.display)==="none"?d("UNMOUNT"):d(h&&p!==v?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,d]),Yr(()=>{if(t){let c;const h=t.ownerDocument.defaultView??window,u=v=>{const y=Mn(a.current).includes(v.animationName);if(v.target===t&&y&&(d("ANIMATION_END"),!i.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",c=h.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},p=v=>{v.target===t&&(n.current=Mn(a.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",u),t.addEventListener("animationend",u),()=>{h.clearTimeout(c),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",u),t.removeEventListener("animationend",u)}}else d("ANIMATION_END")},[t,d]),{isPresent:["mounted","unmountSuspended"].includes(l),ref:w.useCallback(c=>{c&&(a.current=getComputedStyle(c)),r(c)},[])}}function Mn(e){return(e==null?void 0:e.animationName)||"none"}function Ox(e){var a,i;let t=(a=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:a.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function Fx({prop:e,defaultProp:t,onChange:r=()=>{}}){const[a,i]=Qx({defaultProp:t,onChange:r}),n=e!==void 0,s=n?e:a,l=Rt(r),d=w.useCallback(c=>{if(n){const u=typeof c=="function"?c(e):c;u!==e&&l(u)}else i(c)},[n,e,i,l]);return[s,d]}function Qx({defaultProp:e,onChange:t}){const r=w.useState(e),[a]=r,i=w.useRef(a),n=Rt(t);return w.useEffect(()=>{i.current!==a&&(n(a),i.current=a)},[a,i,n]),r}var Wx="VisuallyHidden",Xo=w.forwardRef((e,t)=>
48o.jsx(ze.span,{...e,ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}}));Xo.displayName=Wx;var zx=Xo,Yd="ToastProvider",[Jd,Bx,_x]=Ax("Toast"),[hg,n4]=Uo("Toast",[_x]),[Ux,Vo]=hg(Yd),ug=e=>{const{__scopeToast:t,label:r="Notification",duration:a=5e3,swipeDirection:i="right",swipeThreshold:n=50,children:s}=e,[l,d]=w.useState(null),[c,h]=w.useState(0),u=w.useRef(!1),p=w.useRef(!1);return r.trim()||console.error(`Invalid prop \`label\` supplied to \`${Yd}\`. Expected non-empty \`string\`.`),o.jsx(Jd.Provider,{scope:t,children:o.jsx(Ux,{scope:t,label:r,duration:a,swipeDirection:i,swipeThreshold:n,toastCount:c,viewport:l,onViewportChange:d,onToastAdd:w.useCallback(()=>h(v=>v+1),[]),onToastRemove:w.useCallback(()=>h(v=>v-1),[]),isFocusedToastEscapeKeyDownRef:u,isClosePausedRef:p,children:s})})};ug.displayName=Yd;var pg="ToastViewport",Xx=["F8"],Ql="toast.viewportPause",Wl="toast.viewportResume",mg=w.forwardRef((e,t)=>{const{__scopeToast:r,hotkey:a=Xx,label:i="Notifications ({hotkey})",...n}=e,s=Vo(pg,r),l=Bx(r),d=w.useRef(null),c=w.useRef(null),h=w.useRef(null),u=w.useRef(null),p=yt(t,u,s.onViewportChange),v=a.join("+").replace(/Key/g,"").replace(/Digit/g,""),b=s.toastCount>0;w.useEffect(()=>{const x=f=>{var g;a.length!==0&&a.every(k=>f[k]||f.code===k)&&((g=u.current)==null||g.focus())};return document.addEventListener("keydown",x),()=>document.removeEventListener("keydown",x)},[a]),w.useEffect(()=>{const x=d.current,f=u.current;if(b&&x&&f){const m=()=>{if(!s.isClosePausedRef.current){const T=new CustomEvent(Ql);f.dispatchEvent(T),s.isClosePausedRef.current=!0}},g=()=>{if(s.isClosePausedRef.current){const T=new CustomEvent(Wl);f.dispatchEvent(T),s.isClosePausedRef.current=!1}},k=T=>{!x.contains(T.relatedTarget)&&g()},A=()=>{x.contains(document.activeElement)||g()};return x.addEventListener("focusin",m),x.addEventListener("focusout",k),x.addEventListener("pointermove",m),x.addEventListener("pointerleave",A),window.addEventListener("blur",m),window.addEventListener("focus",g),()=>{x.removeEventListener("focusin",m),x.removeEventListener("focusout",k),x.removeEventListener("pointermove",m),x.removeEventListener("pointerleave",A),window.removeEventListener("blur",m),window.removeEventListener("focus",g)}}},[b,s.isClosePausedRef]);const y=w.useCallback(({tabbingDirection:x})=>{const m=l().map(g=>{const k=g.ref.current,A=[k,...ik(k)];return x==="forwards"?A:A.reverse()});return(x==="forwards"?m.reverse():m).flat()},[l]);return w.useEffect(()=>{const x=u.current;if(x){const f=m=>{var A,T,E;const g=m.altKey||m.ctrlKey||m.metaKey;if(m.key==="Tab"&&!g){const C=document.activeElement,D=m.shiftKey;if(m.target===x&&D){(A=c.current)==null||A.focus();return}const L=y({tabbingDirection:D?"backwards":"forwards"}),U=L.findIndex(P=>P===C);qs(L.slice(U+1))?m.preventDefault():D?(T=c.current)==null||T.focus():(E=h.current)==null||E.focus()}};return x.addEventListener("keydown",f),()=>x.removeEventListener("keydown",f)}},[l,y]),o.jsxs(Px,{ref:d,role:"region","aria-label":i.replace("{hotkey}",v),tabIndex:-1,style:{pointerEvents:b?void 0:"none"},children:[b&&o.jsx(zl,{ref:c,onFocusFromOutsideViewport:()=>{const x=y({tabbingDirection:"forwards"});qs(x)}}),o.jsx(Jd.Slot,{scope:r,children:o.jsx(ze.ol,{tabIndex:-1,...n,ref:p})}),b&&o.jsx(zl,{ref:h,onFocusFromOutsideViewport:()=>{const x=y({tabbingDirection:"backwards"});qs(x)}})]})});mg.displayName=pg;var fg="ToastFocusProxy",zl=w.forwardRef((e,t)=>{const{__scopeToast:r,onFocusFromOutsideViewport:a,...i}=e,n=Vo(fg,r);return o.jsx(Xo,{"aria-hidden":!0,tabIndex:0,...i,ref:t,style:{position:"fixed"},onFocus:s=>{var c;const l=s.relatedTarget;!((c=n.viewport)!=null&&c.contains(l))&&a()}})});zl.displayName=fg;var Ho="Toast",Vx="toast.swipeStart",Hx="toast.swipeMove",$x="toast.swipeCancel",Gx="toast.swipeEnd",gg=w.forwardRef((e,t)=>{const{forceMount:r,open:a,defaultOpen:i,onOpenChange:n,...s}=e,[l=!0,d]=Fx({prop:a,defaultProp:i,onChange:n});return o.jsx(Kd,{present:r||l,children:o.jsx(Jx,{open:l,...s,ref:t,onClose:()=>d(!1),onPause:Rt(e.onPause),onResume:Rt(e.onResume),onSwipeStart:pe(e.onSwipeStart,c=>{c.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:pe(e.onSwipeMove,c=>{const{x:h,y:u}=c.detail.delta;c.currentTarget.setAttribute("data-swipe","move"),c.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${h}px`),c.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${u}px`)}),onSwipeCancel:pe(e.onSwipeCancel,c=>{c.currentTarget.setAttribute("data-swipe","cancel"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),c.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),c.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:pe(e.onSwipeEnd,c=>{const{x:h,y:u}=c.detail.delta;c.currentTarget.setAttribute("data-swipe","end"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),c.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${h}px`),c.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${u}px`),d(!1)})})})});gg.displayName=Ho;var[Kx,Yx]=hg(Ho,{onClose(){}}),Jx=w.forwardRef((e,t)=>
48{const{__scopeToast:r,type:a="foreground",duration:i,open:n,onClose:s,onEscapeKeyDown:l,onPause:d,onResume:c,onSwipeStart:h,onSwipeMove:u,onSwipeCancel:p,onSwipeEnd:v,...b}=e,y=Vo(Ho,r),[x,f]=w.useState(null),m=yt(t,P=>f(P)),g=w.useRef(null),k=w.useRef(null),A=i||y.duration,T=w.useRef(0),E=w.useRef(A),C=w.useRef(0),{onToastAdd:D,onToastRemove:q}=y,W=Rt(()=>{var H;(x==null?void 0:x.contains(document.activeElement))&&((H=y.viewport)==null||H.focus()),s()}),L=w.useCallback(P=>{!P||P===1/0||(window.clearTimeout(C.current),T.current=new Date().getTime(),C.current=window.setTimeout(W,P))},[W]);w.useEffect(()=>{const P=y.viewport;if(P){const H=()=>{L(E.current),c==null||c()},B=()=>{const V=new Date().getTime()-T.current;E.current=E.current-V,window.clearTimeout(C.current),d==null||d()};return P.addEventListener(Ql,B),P.addEventListener(Wl,H),()=>{P.removeEventListener(Ql,B),P.removeEventListener(Wl,H)}}},[y.viewport,A,d,c,L]),w.useEffect(()=>{n&&!y.isClosePausedRef.current&&L(A)},[n,A,y.isClosePausedRef,L]),w.useEffect(()=>(D(),()=>q()),[D,q]);const U=w.useMemo(()=>x?Ag(x):null,[x]);return y.viewport?o.jsxs(o.Fragment,{children:[U&&o.jsx(Zx,{__scopeToast:r,role:"status","aria-live":a==="foreground"?"assertive":"polite","aria-atomic":!0,children:U}),o.jsx(Kx,{scope:r,onClose:W,children:rn.createPortal(o.jsx(Jd.ItemSlot,{scope:r,children:o.jsx(qx,{asChild:!0,onEscapeKeyDown:pe(l,()=>{y.isFocusedToastEscapeKeyDownRef.current||W(),y.isFocusedToastEscapeKeyDownRef.current=!1}),children:o.jsx(ze.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":n?"open":"closed","data-swipe-direction":y.swipeDirection,...b,ref:m,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:pe(e.onKeyDown,P=>{P.key==="Escape"&&(l==null||l(P.nativeEvent),P.nativeEvent.defaultPrevented||(y.isFocusedToastEscapeKeyDownRef.current=!0,W()))}),onPointerDown:pe(e.onPointerDown,P=>{P.button===0&&(g.current={x:P.clientX,y:P.clientY})}),onPointerMove:pe(e.onPointerMove,P=>{if(!g.current)return;const H=P.clientX-g.current.x,B=P.clientY-g.current.y,V=!!k.current,S=["left","right"].includes(y.swipeDirection),R=["left","up"].includes(y.swipeDirection)?Math.min:Math.max,N=S?R(0,H):0,z=S?0:R(0,B),te=P.pointerType==="touch"?10:2,st={x:N,y:z},Ze={originalEvent:P,delta:st};V?(k.current=st,Sn(Hx,u,Ze,{discrete:!1})):_h(st,y.swipeDirection,te)?(k.current=st,Sn(Vx,h,Ze,{discrete:!1}),P.target.setPointerCapture(P.pointerId)):(Math.abs(H)>te||Math.abs(B)>te)&&(g.current=null)}),onPointerUp:pe(e.onPointerUp,P=>{const H=k.current,B=P.target;if(B.hasPointerCapture(P.pointerId)&&B.releasePointerCapture(P.pointerId),k.current=null,g.current=null,H){const V=P.currentTarget,S={originalEvent:P,delta:H};_h(H,y.swipeDirection,y.swipeThreshold)?Sn(Gx,v,S,{discrete:!0}):Sn($x,p,S,{discrete:!0}),V.addEventListener("click",R=>R.preventDefault(),{once:!0})}})})})}),y.viewport)})]}):null}),Zx=e=>{const{__scopeToast:t,children:r,...a}=e,i=Vo(Ho,t),[n,s]=w.useState(!1),[l,d]=w.useState(!1);return rk(()=>s(!0)),w.useEffect(()=>{const c=window.setTimeout(()=>d(!0),1e3);return()=>window.clearTimeout(c)},[]),l?null:o.jsx(cg,{asChild:!0,children:o.jsx(Xo,{...a,children:n&&o.jsxs(o.Fragment,{children:[i.label," ",r]})})})},ek="ToastTitle",vg=w.forwardRef((e,t)=>{const{__scopeToast:r,...a}=e;return o.jsx(ze.div,{...a,ref:t})});vg.displayName=ek;var tk="ToastDescription",yg=w.forwardRef((e,t)=>{const{__scopeToast:r,...a}=e;return o.jsx(ze.div,{...a,ref:t})});yg.displayName=tk;var bg="ToastAction",wg=w.forwardRef((e,t)=>{const{altText:r,...a}=e;return r.trim()?o.jsx(kg,{altText:r,asChild:!0,children:o.jsx(Zd,{...a,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${bg}\`. Expected non-empty \`string\`.`),null)});wg.displayName=bg;var xg="ToastClose",Zd=w.forwardRef((e,t)=>{const{__scopeToast:r,...a}=e,i=Yx(xg,r);return o.jsx(kg,{asChild:!0,children:o.jsx(ze.button,{type:"button",...a,ref:t,onClick:pe(e.onClick,i.onClose)})})});Zd.displayName=xg;var kg=w.forwardRef((e,t)=>{const{__scopeToast:r,altText:a,...i}=e;return o.jsx(ze.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":a||void 0,...i,ref:t})});function Ag(e){const t=[];
vendor: 8,728 bytes, lines 48-143
48return Array.from(e.childNodes).forEach(a=>{if(a.nodeType===a.TEXT_NODE&&a.textContent&&t.push(a.textContent),ak(a)){const i=a.ariaHidden||a.hidden||a.style.display==="none",n=a.dataset.radixToastAnnounceExclude==="";if(!i)if(n){const s=a.dataset.radixToastAnnounceAlt;s&&t.push(s)}else t.push(...Ag(a))}}),t}function Sn(e,t,r,{discrete:a}){const i=r.originalEvent.currentTarget,n=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:r});t&&i.addEventListener(e,t,{once:!0}),a?og(i,n):i.dispatchEvent(n)}var _h=(e,t,r=0)=>{const a=Math.abs(e.x),i=Math.abs(e.y),n=a>i;return t==="left"||t==="right"?n&&a>r:!n&&i>r};function rk(e=()=>{}){const t=Rt(e);Yr(()=>{let r=0,a=0;return r=window.requestAnimationFrame(()=>a=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(r),window.cancelAnimationFrame(a)}},[t])}function ak(e){return e.nodeType===e.ELEMENT_NODE}function ik(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:a=>{const i=a.tagName==="INPUT"&&a.type==="hidden";return a.disabled||a.hidden||i?NodeFilter.FILTER_SKIP:a.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function qs(e){const t=document.activeElement;return e.some(r=>r===t?!0:(r.focus(),document.activeElement!==t))}var nk=ug,Tg=mg,Eg=gg,Mg=vg,Sg=yg,Cg=wg,Ig=Zd;function Rg(e){var t,r,a="";if(typeof e=="string"||typeof e=="number")a+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(r=Rg(e[t]))&&(a&&(a+=" "),a+=r)}else for(r in e)e[r]&&(a&&(a+=" "),a+=r);return a}function jg(){for(var e,t,r=0,a="",i=arguments.length;r<i;r++)(e=arguments[r])&&(t=Rg(e))&&(a&&(a+=" "),a+=t);return a}const Uh=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,Xh=jg,ec=(e,t)=>r=>{var a;if((t==null?void 0:t.variants)==null)return Xh(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:i,defaultVariants:n}=t,s=Object.keys(i).map(c=>{const h=r==null?void 0:r[c],u=n==null?void 0:n[c];if(h===null)return null;const p=Uh(h)||Uh(u);return i[c][p]}),l=r&&Object.entries(r).reduce((c,h)=>{let[u,p]=h;return p===void 0||(c[u]=p),c},{}),d=t==null||(a=t.compoundVariants)===null||a===void 0?void 0:a.reduce((c,h)=>{let{class:u,className:p,...v}=h;return Object.entries(v).every(b=>{let[y,x]=b;return Array.isArray(x)?x.includes({...n,...l}[y]):{...n,...l}[y]===x})?[...c,u,p]:c},[]);return Xh(e,s,d,r==null?void 0:r.class,r==null?void 0:r.className)};/**
49 * @license lucide-react v0.453.0 - ISC
50 *
51 * This source code is licensed under the ISC license.
52 * See the LICENSE file in the root directory of this source tree.
53 */const ok=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),qg=(...e)=>e.filter((t,r,a)=>!!t&&a.indexOf(t)===r).join(" ");/**
54 * @license lucide-react v0.453.0 - ISC
55 *
56 * This source code is licensed under the ISC license.
57 * See the LICENSE file in the root directory of this source tree.
58 */var sk={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
59 * @license lucide-react v0.453.0 - ISC
60 *
61 * This source code is licensed under the ISC license.
62 * See the LICENSE file in the root directory of this source tree.
63 */const lk=w.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:r=2,absoluteStrokeWidth:a,className:i="",children:n,iconNode:s,...l},d)=>w.createElement("svg",{ref:d,...sk,width:t,height:t,stroke:e,strokeWidth:a?Number(r)*24/Number(t):r,className:qg("lucide",i),...l},[...s.map(([c,h])=>w.createElement(c,h)),...Array.isArray(n)?n:[n]]));/**
64 * @license lucide-react v0.453.0 - ISC
65 *
66 * This source code is licensed under the ISC license.
67 * See the LICENSE file in the root directory of this source tree.
68 */const Pe=(e,t)=>{const r=w.forwardRef(({className:a,...i},n)=>w.createElement(lk,{ref:n,iconNode:t,className:qg(`lucide-${ok(e)}`,a),...i}));return r.displayName=`${e}`,r};/**
69 * @license lucide-react v0.453.0 - ISC
70 *
71 * This source code is licensed under the ISC license.
72 * See the LICENSE file in the root directory of this source tree.
73 */const dk=Pe("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
74 * @license lucide-react v0.453.0 - ISC
75 *
76 * This source code is licensed under the ISC license.
77 * See the LICENSE file in the root directory of this source tree.
78 */const $o=Pe("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
79 * @license lucide-react v0.453.0 - ISC
80 *
81 * This source code is licensed under the ISC license.
82 * See the LICENSE file in the root directory of this source tree.
83 */const ck=Pe("Award",[["path",{d:"m15.477 12.89 1.515 8.526a.5.5 0 0 1-.81.47l-3.58-2.687a1 1 0 0 0-1.197 0l-3.586 2.686a.5.5 0 0 1-.81-.469l1.514-8.526",key:"1yiouv"}],["circle",{cx:"12",cy:"8",r:"6",key:"1vp47v"}]]);/**
84 * @license lucide-react v0.453.0 - ISC
85 *
86 * This source code is licensed under the ISC license.
87 * See the LICENSE file in the root directory of this source tree.
88 */const Pg=Pe("BookOpen",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]]);/**
89 * @license lucide-react v0.453.0 - ISC
90 *
91 * This source code is licensed under the ISC license.
92 * See the LICENSE file in the root directory of this source tree.
93 */const Dg=Pe("Calendar",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]]);/**
94 * @license lucide-react v0.453.0 - ISC
95 *
96 * This source code is licensed under the ISC license.
97 * See the LICENSE file in the root directory of this source tree.
98 */const Vh=Pe("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
99 * @license lucide-react v0.453.0 - ISC
100 *
101 * This source code is licensed under the ISC license.
102 * See the LICENSE file in the root directory of this source tree.
103 */const hk=Pe("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/**
104 * @license lucide-react v0.453.0 - ISC
105 *
106 * This source code is licensed under the ISC license.
107 * See the LICENSE file in the root directory of this source tree.
108 */const Ui=Pe("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
109 * @license lucide-react v0.453.0 - ISC
110 *
111 * This source code is licensed under the ISC license.
112 * See the LICENSE file in the root directory of this source tree.
113 */const Go=Pe("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
114 * @license lucide-react v0.453.0 - ISC
115 *
116 * This source code is licensed under the ISC license.
117 * See the LICENSE file in the root directory of this source tree.
118 */const za=Pe("ExternalLink",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);/**
119 * @license lucide-react v0.453.0 - ISC
120 *
121 * This source code is licensed under the ISC license.
122 * See the LICENSE file in the root directory of this source tree.
123 */const uk=Pe("Mail",[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}]]);/**
124 * @license lucide-react v0.453.0 - ISC
125 *
126 * This source code is licensed under the ISC license.
127 * See the LICENSE file in the root directory of this source tree.
128 */const pk=Pe("MessageSquare",[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]]);/**
129 * @license lucide-react v0.453.0 - ISC
130 *
131 * This source code is licensed under the ISC license.
132 * See the LICENSE file in the root directory of this source tree.
133 */const mk=Pe("Target",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"6",key:"1vlfrh"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]]);/**
134 * @license lucide-react v0.453.0 - ISC
135 *
136 * This source code is licensed under the ISC license.
137 * See the LICENSE file in the root directory of this source tree.
138 */const fk=Pe("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);/**
139 * @license lucide-react v0.453.0 - ISC
140 *
141 * This source code is licensed under the ISC license.
142 * See the LICENSE file in the root directory of this source tree.
143 */const Bl=Pe("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}
vendor: 5,880 bytes, line 143
143],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),tc="-",gk=e=>{const t=yk(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:a}=e;return{getClassGroupId:s=>{const l=s.split(tc);return l[0]===""&&l.length!==1&&l.shift(),Lg(l,t)||vk(s)},getConflictingClassGroupIds:(s,l)=>{const d=r[s]||[];return l&&a[s]?[...d,...a[s]]:d}}},Lg=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const r=e[0],a=t.nextPart.get(r),i=a?Lg(e.slice(1),a):void 0;if(i)return i;if(t.validators.length===0)return;const n=e.join(tc);return(s=t.validators.find(({validator:l})=>l(n)))==null?void 0:s.classGroupId},Hh=/^\[(.+)\]$/,vk=e=>{if(Hh.test(e)){const t=Hh.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},yk=e=>{const{theme:t,prefix:r}=e,a={nextPart:new Map,validators:[]};return wk(Object.entries(e.classGroups),r).forEach(([n,s])=>{_l(s,a,n,t)}),a},_l=(e,t,r,a)=>{e.forEach(i=>{if(typeof i=="string"){const n=i===""?t:$h(t,i);n.classGroupId=r;return}if(typeof i=="function"){if(bk(i)){_l(i(a),t,r,a);return}t.validators.push({validator:i,classGroupId:r});return}Object.entries(i).forEach(([n,s])=>{_l(s,$h(t,n),r,a)})})},$h=(e,t)=>{let r=e;return t.split(tc).forEach(a=>{r.nextPart.has(a)||r.nextPart.set(a,{nextPart:new Map,validators:[]}),r=r.nextPart.get(a)}),r},bk=e=>e.isThemeGetter,wk=(e,t)=>t?e.map(([r,a])=>{const i=a.map(n=>typeof n=="string"?t+n:typeof n=="object"?Object.fromEntries(Object.entries(n).map(([s,l])=>[t+s,l])):n);return[r,i]}):e,xk=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,a=new Map;const i=(n,s)=>{r.set(n,s),t++,t>e&&(t=0,a=r,r=new Map)};return{get(n){let s=r.get(n);if(s!==void 0)return s;if((s=a.get(n))!==void 0)return i(n,s),s},set(n,s){r.has(n)?r.set(n,s):i(n,s)}}},Ng="!",kk=e=>{const{separator:t,experimentalParseClassName:r}=e,a=t.length===1,i=t[0],n=t.length,s=l=>{const d=[];let c=0,h=0,u;for(let x=0;x<l.length;x++){let f=l[x];if(c===0){if(f===i&&(a||l.slice(x,x+n)===t)){d.push(l.slice(h,x)),h=x+n;continue}if(f==="/"){u=x;continue}}f==="["?c++:f==="]"&&c--}const p=d.length===0?l:l.substring(h),v=p.startsWith(Ng),b=v?p.substring(1):p,y=u&&u>h?u-h:void 0;return{modifiers:d,hasImportantModifier:v,baseClassName:b,maybePostfixModifierPosition:y}};return r?l=>r({className:l,parseClassName:s}):s},Ak=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(a=>{a[0]==="["?(t.push(...r.sort(),a),r=[]):r.push(a)}),t.push(...r.sort()),t},Tk=e=>({cache:xk(e.cacheSize),parseClassName:kk(e),...gk(e)}),Ek=/\s+/,Mk=(e,t)=>{const{parseClassName:r,getClassGroupId:a,getConflictingClassGroupIds:i}=t,n=[],s=e.trim().split(Ek);let l="";for(let d=s.length-1;d>=0;d-=1){const c=s[d],{modifiers:h,hasImportantModifier:u,baseClassName:p,maybePostfixModifierPosition:v}=r(c);let b=!!v,y=a(b?p.substring(0,v):p);if(!y){if(!b){l=c+(l.length>0?" "+l:l);continue}if(y=a(p),!y){l=c+(l.length>0?" "+l:l);continue}b=!1}const x=Ak(h).join(":"),f=u?x+Ng:x,m=f+y;if(n.includes(m))continue;n.push(m);const g=i(y,b);for(let k=0;k<g.length;++k){const A=g[k];n.push(f+A)}l=c+(l.length>0?" "+l:l)}return l};function Sk(){let e=0,t,r,a="";for(;e<arguments.length;)(t=arguments[e++])&&(r=Og(t))&&(a&&(a+=" "),a+=r);return a}const Og=e=>{if(typeof e=="string")return e;let t,r="";for(let a=0;a<e.length;a++)e[a]&&(t=Og(e[a]))&&(r&&(r+=" "),r+=t);return r};function Ck(e,...t){let r,a,i,n=s;function s(d){const c=t.reduce((h,u)=>u(h),e());return r=Tk(c),a=r.cache.get,i=r.cache.set,n=l,l(d)}function l(d){const c=a(d);if(c)return c;const h=Mk(d,r);return i(d,h),h}return function(){return n(Sk.apply(null,arguments))}}const Y=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},Fg=/^\[(?:([a-z-]+):)?(.+)\]$/i,Ik=/^\d+\/\d+$/,Rk=new Set(["px","full","screen"]),jk=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,qk=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Pk=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,Dk=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Lk=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Nt=e=>xa(e)||Rk.has(e)||Ik.test(e),Zt=e=>$a(e,"length",_k),xa=e=>!!e&&!Number.isNaN(Number(e)),Ps=e=>$a(e,"number",xa),si=e=>!!e&&Number.isInteger(Number(e)),Nk=e=>e.endsWith("%")&&xa(e.slice(0,-1)),F=e=>Fg.test(e),er=e=>jk.test(e),Ok=new Set(["length","size","percentage"]),Fk=e=>$a(e,Ok,Qg),Qk=e=>$a(e,"position",Qg),Wk=new Set(["image","url"]),zk=e=>$a(e,Wk,Xk),Bk=e=>$a(e,"",Uk),li=()=>!0,$a=(e,t,r)=>{const a=Fg.exec(e);return a?a[1]?typeof t=="string"?a[1]===t:t.has(a[1]):r(a[2]):!1},_k=e=>qk.test(e)&&!Pk.test(e),Qg=()=>!1,Uk=e=>Dk.test(e),Xk=e=>Lk.test(e),Vk=()=>{const e=Y("colors"),t=Y("spacing"),r=Y("blur"),a=Y("brightness"),i=Y("borderColor"),n=Y("borderRadius"),s=Y("borderSpacing"),l=Y("borderWidth"),d=Y("contrast"),c=Y("grayscale"),h=Y("hueRotate"),u=Y("invert"),p=Y("gap"),v=Y("gradientColorStops"),b=Y("gradientColorStopPositions"),y=Y("inset"),x=Y("margin"),f=Y("opacity"),m=Y("padding"),g=Y("saturate"),k=Y("scale"),A=Y("sepia"),T=Y("skew"),E=Y("space"),C=Y("translate"),D=()=>["auto","contain","none"],q=()=>["auto","hidden","clip","visible","scroll"],W=()=>["auto",F,t],L=()=>[F,t],U=()=>["",Nt,Zt],P=()=>["auto",xa,F],H=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],B=()=>["solid","dashed","dotted","double","none"],V=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],S=()=>["start","end","center","between","around","evenly","stretch"],R=()=>["","0",F],N=()=>["auto","avoid","all","avoid-page","page","left","right","column"],z=()=>[xa,F];return{cacheSize:500,separator:":",theme:{colors:[li],spacing:[Nt,Zt],blur:["none","",er,F],brightness:z(),borderColor:[e],borderRadius:["n
143one","","full",er,F],borderSpacing:L(),borderWidth:U(),contrast:z(),grayscale:R(),hueRotate:z(),invert:R(),gap:L(),gradientColorStops:[e],gradientColorStopPositions:[Nk,Zt],inset:W(),margin:W(),opacity:z(),padding:L(),saturate:z(),scale:z(),sepia:R(),skew:z(),space:L(),translate:L()},classGroups:{aspect:[{aspect:["auto","square","video",F]}],container:["container"],columns:[{columns:[er]}],"break-after":[{"break-after":N()}],"break-before":[{"break-before":N()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...H(),F]}],overflow:[{overflow:q()}],"overflow-x":[{"overflow-x":q()}],"overflow-y":[{"overflow-y":q()}],overscroll:[{overscroll:D()}],"overscroll-x":[{"overscroll-x":D()}],"overscroll-y":[{"overscroll-y":D()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[y]}],"inset-x":[{"inset-x":[y]}],"inset-y":[{"inset-y":[y]}],start:[{start:[y]}],end:[{end:[y]}],top:[{top:[y]}],right:[{right:[y]}],bottom:[{bottom:[y]}],left:[{left:[y]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",si,F]}],basis:[{basis:W()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",F]}],grow:[{grow:R()}],shrink:[{shrink:R()}],order:[{order:["first","last","none",si,F]}],"grid-cols":[{"grid-cols":[li]}],"col-start-end":[{col:["auto",{span:["full",si,F]},F]}],"col-start":[{"col-start":P()}],"col-end":[{"col-end":P()}],"grid-rows":[{"grid-rows":[li]}],"row-start-end":[{row:["auto",{span:[si,F]},F]}],"row-start":[{"row-start":P()}],"row-end":[{"row-end":P()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",F]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",F]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal",...S()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...S(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...S(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[m]}],px:[{px:[m]}],py:[{py:[m]}],ps:[{ps:[m]}],pe:[{pe:[m]}],pt:[{pt:[m]}],pr:[{pr:[m]}],pb:[{pb:[m]}],pl:[{pl:[m]}],m:[{m:[x]}],mx:[{mx:[x]}],my:[{my:[x]}],ms:[{ms:[x]}],me:[{me:[x]}],mt:[{mt:[x]}],mr:[{mr:[x]}],mb:[{mb:[x]}],ml:[{ml:[x]}],"space-x":[{"space-x":[E]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[E]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",F,t]}],"min-w":[{"min-w":[F,t,"min","max","fit"]}],"max-w":[{"max-w":[F,t,"none","full","min","max","fit","prose",{screen:[er]},er]}],h:[{h:[F,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[F,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[F,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[F,t,"auto","min","max","fit"]}],"font-size":[{text:["base",er,Zt]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Ps]}],"font-family":[{font:[li]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",F]}],"line-clamp":[{"line-clamp":["none",xa,Ps]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Nt,F]}],"list-image":[{"list-image":["none",F]}],"list-style-type":[{list:["none","disc","decimal",F]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[f]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[f]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...B(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Nt,Zt]}],"underline-offset":[{"underline-offset":["auto",Nt,F]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:L()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",F]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",F]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[f]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...H(),Qk]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Fk]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},zk]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[b]}
vendor: 5,172 bytes, line 143
143],"gradient-via-pos":[{via:[b]}],"gradient-to-pos":[{to:[b]}],"gradient-from":[{from:[v]}],"gradient-via":[{via:[v]}],"gradient-to":[{to:[v]}],rounded:[{rounded:[n]}],"rounded-s":[{"rounded-s":[n]}],"rounded-e":[{"rounded-e":[n]}],"rounded-t":[{"rounded-t":[n]}],"rounded-r":[{"rounded-r":[n]}],"rounded-b":[{"rounded-b":[n]}],"rounded-l":[{"rounded-l":[n]}],"rounded-ss":[{"rounded-ss":[n]}],"rounded-se":[{"rounded-se":[n]}],"rounded-ee":[{"rounded-ee":[n]}],"rounded-es":[{"rounded-es":[n]}],"rounded-tl":[{"rounded-tl":[n]}],"rounded-tr":[{"rounded-tr":[n]}],"rounded-br":[{"rounded-br":[n]}],"rounded-bl":[{"rounded-bl":[n]}],"border-w":[{border:[l]}],"border-w-x":[{"border-x":[l]}],"border-w-y":[{"border-y":[l]}],"border-w-s":[{"border-s":[l]}],"border-w-e":[{"border-e":[l]}],"border-w-t":[{"border-t":[l]}],"border-w-r":[{"border-r":[l]}],"border-w-b":[{"border-b":[l]}],"border-w-l":[{"border-l":[l]}],"border-opacity":[{"border-opacity":[f]}],"border-style":[{border:[...B(),"hidden"]}],"divide-x":[{"divide-x":[l]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[l]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[f]}],"divide-style":[{divide:B()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-s":[{"border-s":[i]}],"border-color-e":[{"border-e":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...B()]}],"outline-offset":[{"outline-offset":[Nt,F]}],"outline-w":[{outline:[Nt,Zt]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:U()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[f]}],"ring-offset-w":[{"ring-offset":[Nt,Zt]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",er,Bk]}],"shadow-color":[{shadow:[li]}],opacity:[{opacity:[f]}],"mix-blend":[{"mix-blend":[...V(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":V()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[a]}],contrast:[{contrast:[d]}],"drop-shadow":[{"drop-shadow":["","none",er,F]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[h]}],invert:[{invert:[u]}],saturate:[{saturate:[g]}],sepia:[{sepia:[A]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[a]}],"backdrop-contrast":[{"backdrop-contrast":[d]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[h]}],"backdrop-invert":[{"backdrop-invert":[u]}],"backdrop-opacity":[{"backdrop-opacity":[f]}],"backdrop-saturate":[{"backdrop-saturate":[g]}],"backdrop-sepia":[{"backdrop-sepia":[A]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",F]}],duration:[{duration:z()}],ease:[{ease:["linear","in","out","in-out",F]}],delay:[{delay:z()}],animate:[{animate:["none","spin","ping","pulse","bounce",F]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[k]}],"scale-x":[{"scale-x":[k]}],"scale-y":[{"scale-y":[k]}],rotate:[{rotate:[si,F]}],"translate-x":[{"translate-x":[C]}],"translate-y":[{"translate-y":[C]}],"skew-x":[{"skew-x":[T]}],"skew-y":[{"skew-y":[T]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",F]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",F]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":L()}],"scroll-mx":[{"scroll-mx":L()}],"scroll-my":[{"scroll-my":L()}],"scroll-ms":[{"scroll-ms":L()}],"scroll-me":[{"scroll-me":L()}],"scroll-mt":[{"scroll-mt":L()}],"scroll-mr":[{"scroll-mr":L()}],"scroll-mb":[{"scroll-mb":L()}],"scroll-ml":[{"scroll-ml":L()}],"scroll-p":[{"scroll-p":L()}],"scroll-px":[{"scroll-px":L()}],"scroll-py":[{"scroll-py":L()}],"scroll-ps":[{"scroll-ps":L()}],"scroll-pe":[{"scroll-pe":L()}],"scroll-pt":[{"scroll-pt":L()}],"scroll-pr":[{"scroll-pr":L()}],"scroll-pb":[{"scroll-pb":L()}],"scroll-pl":[{"scroll-pl":L()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}
vendor: 4,646 bytes, line 143
143],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",F]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Nt,Zt,Ps]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},Hk=Ck(Vk);function De(...e){return Hk(jg(e))}const $k=nk,Wg=w.forwardRef(({className:e,...t},r)=>o.jsx(Tg,{ref:r,className:De("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",e),...t}));Wg.displayName=Tg.displayName;const Gk=ec("group pointer-events-auto relative flex w-full items-center justify-between space-x-4 overflow-hidden rounded-md border p-6 pr-8 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),zg=w.forwardRef(({className:e,variant:t,...r},a)=>o.jsx(Eg,{ref:a,className:De(Gk({variant:t}),e),...r}));zg.displayName=Eg.displayName;const Kk=w.forwardRef(({className:e,...t},r)=>o.jsx(Cg,{ref:r,className:De("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium ring-offset-background transition-colors hover:bg-secondary focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive",e),...t}));Kk.displayName=Cg.displayName;const Bg=w.forwardRef(({className:e,...t},r)=>o.jsx(Ig,{ref:r,className:De("absolute right-2 top-2 rounded-md p-1 text-foreground
vendor: 12,797 bytes, line 143
143/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-2 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...t,children:o.jsx(Bl,{className:"h-4 w-4"})}));Bg.displayName=Ig.displayName;const _g=w.forwardRef(({className:e,...t},r)=>o.jsx(Mg,{ref:r,className:De("text-sm font-semibold",e),...t}));_g.displayName=Mg.displayName;const Ug=w.forwardRef(({className:e,...t},r)=>o.jsx(Sg,{ref:r,className:De("text-sm opacity-90",e),...t}));Ug.displayName=Sg.displayName;function Yk(){const{toasts:e}=fx();return o.jsxs($k,{children:[e.map(function({id:t,title:r,description:a,action:i,...n}){return o.jsxs(zg,{...n,children:[o.jsxs("div",{className:"grid gap-1",children:[r&&o.jsx(_g,{children:r}),a&&o.jsx(Ug,{children:a})]}),i,o.jsx(Bg,{})]},t)}),o.jsx(Wg,{})]})}const Jk=["top","right","bottom","left"],Tr=Math.min,Ve=Math.max,wo=Math.round,Cn=Math.floor,It=e=>({x:e,y:e}),Zk={left:"right",right:"left",bottom:"top",top:"bottom"},eA={start:"end",end:"start"};function Ul(e,t,r){return Ve(e,Tr(t,r))}function Gt(e,t){return typeof e=="function"?e(t):e}function Kt(e){return e.split("-")[0]}function Ga(e){return e.split("-")[1]}function rc(e){return e==="x"?"y":"x"}function ac(e){return e==="y"?"height":"width"}function Er(e){return["top","bottom"].includes(Kt(e))?"y":"x"}function ic(e){return rc(Er(e))}function tA(e,t,r){r===void 0&&(r=!1);const a=Ga(e),i=ic(e),n=ac(i);let s=i==="x"?a===(r?"end":"start")?"right":"left":a==="start"?"bottom":"top";return t.reference[n]>t.floating[n]&&(s=xo(s)),[s,xo(s)]}function rA(e){const t=xo(e);return[Xl(e),t,Xl(t)]}function Xl(e){return e.replace(/start|end/g,t=>eA[t])}function aA(e,t,r){const a=["left","right"],i=["right","left"],n=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return r?t?i:a:t?a:i;case"left":case"right":return t?n:s;default:return[]}}function iA(e,t,r,a){const i=Ga(e);let n=aA(Kt(e),r==="start",a);return i&&(n=n.map(s=>s+"-"+i),t&&(n=n.concat(n.map(Xl)))),n}function xo(e){return e.replace(/left|right|bottom|top/g,t=>Zk[t])}function nA(e){return{top:0,right:0,bottom:0,left:0,...e}}function Xg(e){return typeof e!="number"?nA(e):{top:e,right:e,bottom:e,left:e}}function ko(e){const{x:t,y:r,width:a,height:i}=e;return{width:a,height:i,top:r,left:t,right:t+a,bottom:r+i,x:t,y:r}}function Gh(e,t,r){let{reference:a,floating:i}=e;const n=Er(t),s=ic(t),l=ac(s),d=Kt(t),c=n==="y",h=a.x+a.width/2-i.width/2,u=a.y+a.height/2-i.height/2,p=a[l]/2-i[l]/2;let v;switch(d){case"top":v={x:h,y:a.y-i.height};break;case"bottom":v={x:h,y:a.y+a.height};break;case"right":v={x:a.x+a.width,y:u};break;case"left":v={x:a.x-i.width,y:u};break;default:v={x:a.x,y:a.y}}switch(Ga(t)){case"start":v[s]-=p*(r&&c?-1:1);break;case"end":v[s]+=p*(r&&c?-1:1);break}return v}const oA=async(e,t,r)=>{const{placement:a="bottom",strategy:i="absolute",middleware:n=[],platform:s}=r,l=n.filter(Boolean),d=await(s.isRTL==null?void 0:s.isRTL(t));let c=await s.getElementRects({reference:e,floating:t,strategy:i}),{x:h,y:u}=Gh(c,a,d),p=a,v={},b=0;for(let y=0;y<l.length;y++){const{name:x,fn:f}=l[y],{x:m,y:g,data:k,reset:A}=await f({x:h,y:u,initialPlacement:a,placement:p,strategy:i,middlewareData:v,rects:c,platform:s,elements:{reference:e,floating:t}});h=m??h,u=g??u,v={...v,[x]:{...v[x],...k}},A&&b<=50&&(b++,typeof A=="object"&&(A.placement&&(p=A.placement),A.rects&&(c=A.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:i}):A.rects),{x:h,y:u}=Gh(c,p,d)),y=-1)}return{x:h,y:u,placement:p,strategy:i,middlewareData:v}};async function Xi(e,t){var r;t===void 0&&(t={});const{x:a,y:i,platform:n,rects:s,elements:l,strategy:d}=e,{boundary:c="clippingAncestors",rootBoundary:h="viewport",elementContext:u="floating",altBoundary:p=!1,padding:v=0}=Gt(t,e),b=Xg(v),x=l[p?u==="floating"?"reference":"floating":u],f=ko(await n.getClippingRect({element:(r=await(n.isElement==null?void 0:n.isElement(x)))==null||r?x:x.contextElement||await(n.getDocumentElement==null?void 0:n.getDocumentElement(l.floating)),boundary:c,rootBoundary:h,strategy:d})),m=u==="floating"?{x:a,y:i,width:s.floating.width,height:s.floating.height}:s.reference,g=await(n.getOffsetParent==null?void 0:n.getOffsetParent(l.floating)),k=await(n.isElement==null?void 0:n.isElement(g))?await(n.getScale==null?void 0:n.getScale(g))||{x:1,y:1}:{x:1,y:1},A=ko(n.convertOffsetParentRelativeRectToViewportRelativeRect?await n.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:m,offsetParent:g,strategy:d}):m);return{top:(f.top-A.top+b.top)/k.y,bottom:(A.bottom-f.bottom+b.bottom)/k.y,left:(f.left-A.left+b.left)/k.x,right:(A.right-f.right+b.right)/k.x}}const sA=e=>({name:"arrow",options:e,async fn(t){const{x:r,y:a,placement:i,rects:n,platform:s,elements:l,middlewareData:d}=t,{element:c,padding:h=0}=Gt(e,t)||{};if(c==null)return{};const u=Xg(h),p={x:r,y:a},v=ic(i),b=ac(v),y=await s.getDimensions(c),x=v==="y",f=x?"top":"left",m=x?"bottom":"right",g=x?"clientHeight":"clientWidth",k=n.reference[b]+n.reference[v]-p[v]-n.floating[b],A=p[v]-n.reference[v],T=await(s.getOffsetParent==null?void 0:s.getOffsetParent(c));let E=T?T[g]:0;(!E||!await(s.isElement==null?void 0:s.isElement(T)))&&(E=l.floating[g]||n.floating[b]);const C=k/2-A/2,D=E/2-y[b]/2-1,q=Tr(u[f],D),W=Tr(u[m],D),L=q,U=E-y[b]-W,P=E/2-y[b]/2+C,H=Ul(L,P,U),B=!d.arrow&&Ga(i)!=null&&P!==H&&n.reference[b]/2-(P<L?q:W)-y[b]/2<0,V=B?P<L?P-L:P-U:0;return{[v]:p[v]+V,data:{[v]:H,centerOffset:P-H-V,...B&&{alignmentOffset:V}},reset:B}}}),lA=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,a;const{placement:i,middlewareData:n,rects:s,initialPlacement:l,platform:d,elements:c}=t,{mainAxis:h=!0,crossAxis:u=!0,fallbackPlacements:p,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:y=!0,...x}=Gt(e,t);if((r=n.arrow)!=null&&r.alignmentOffset)return{};const f=Kt(i),m=Er(l),g=Kt(l)===l,k=await(d.isRTL==null?void 0:d.isRTL(c.floating)),A=p||(g||!y?[xo(l)]:rA(l)),T=b!=="none";!p&&T&&A.push(...iA(l,y,b,k));const E=[l,...A],C=await Xi(t,x),D=[];let q=((a=n.flip)==null?void 0:a.overflows)||[];if(h&&D.push(C[f]),u){const P=tA(i,s,k);D.push(C[P[0]],C[P[1]])}if(q=[...q,{placement:i,overflows:D}],!D.every(P=>P<=0)){var W,L;const P=(((W=n.flip)==null?void 0:W.index)||0)+1,H=E[P];if(H)return{data:{index:P,overflows:q},reset:{placement:H}};let B=(L=q.filter(V=>V.overflows[0]<=0).sort((V,S)=>V.overflows[1]-S.overflows[1])[0])==null?void 0:L.placement;if(!B)switch(v){case"bestFit":{var U;const V=(U=q.filter(S=>{if(T){const R=Er(S.placement);return R===m||R==="y"}return!0}).map(S=>[S.placement,S.overflows.filter(R=>R>0).reduce((R,N)=>R+N,0)]).sort((S,R)=>S[1]-R[1])[0])==null?void 0:U[0];V&&(B=V);break}case"initialPlacement":B=l;break}if(i!==B)return{reset:{placement:B}}}return{}}}};function Kh(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Yh(e){return Jk.some(t=>e[t]>=0)}const dA=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:r}=t,{strategy:a="referenceHidden",...i}=Gt(e,t);switch(a){case"referenceHidden":{const n=await Xi(t,{...i,elementContext:"reference"}),s=Kh(n,r.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:Yh(s)}}}case"escaped":{const n=await Xi(t,{...i,altBoundary:!0}),s=Kh(n,r.floating);return{data:{escapedOffsets:s,escaped:Yh(s)}}}default:return{}}}}};async function cA(e,t){const{placement:r,platform:a,elements:i}=e,n=await(a.isRTL==null?void 0:a.isRTL(i.floating)),s=Kt(r),l=Ga(r),d=Er(r)==="y",c=["left","top"].includes(s)?-1:1,h=n&&d?-1:1,u=Gt(t,e);let{mainAxis:p,crossAxis:v,alignmentAxis:b}=typeof u=="number"?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return l&&typeof b=="number"&&(v=l==="end"?b*-1:b),d?{x:v*h,y:p*c}:{x:p*c,y:v*h}}const hA=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,a;const{x:i,y:n,placement:s,middlewareData:l}=t,d=await cA(t,e);return s===((r=l.offset)==null?void 0:r.placement)&&(a=l.arrow)!=null&&a.alignmentOffset?{}:{x:i+d.x,y:n+d.y,data:{...d,placement:s}}}}},uA=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:a,placement:i}=t,{mainAxis:n=!0,crossAxis:s=!1,limiter:l={fn:x=>{let{x:f,y:m}=x;return{x:f,y:m}}},...d}=Gt(e,t),c={x:r,y:a},h=await Xi(t,d),u=Er(Kt(i)),p=rc(u);let v=c[p],b=c[u];if(n){const x=p==="y"?"top":"left",f=p==="y"?"bottom":"right",m=v+h[x],g=v-h[f];v=Ul(m,v,g)}if(s){const x=u==="y"?"top":"left",f=u==="y"?"bottom":"right",m=b+h[x],g=b-h[f];b=Ul(m,b,g)}const y=l.fn({...t,[p]:v,[u]:b});return{...y,data:{x:y.x-r,y:y.y-a,enabled:{[p]:n,[u]:s}}}}}},pA=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:r,y:a,placement:i,rects:n,middlewareData:s}=t,{offset:l=0,mainAxis:d=!0,crossAxis:c=!0}=Gt(e,t),h={x:r,y:a},u=Er(i),p=rc(u);let v=h[p],b=h[u];const y=Gt(l,t),x=typeof y=="number"?{mainAxis:y,crossAxis:0}:{mainAxis:0,crossAxis:0,...y};if(d){const g=p==="y"?"height":"width",k=n.reference[p]-n.floating[g]+x.mainAxis,A=n.reference[p]+n.reference[g]-x.mainAxis;v<k?v=k:v>A&&(v=A)}if(c){var f,m;const g=p==="y"?"width":"height",k=["top","left"].includes(Kt(i)),A=n.reference[u]-n.floating[g]+(k&&((f=s.offset)==null?void 0:f[u])||0)+(k?0:x.crossAxis),T=n.reference[u]+n.reference[g]+(k?0:((m=s.offset)==null?void 0:m[u])||0)-(k?x.crossAxis:0);b<A?b=A:b>T&&(b=T)}return{[p]:v,[u]:b}}}},mA=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var r,a;const{placement:i,rects:n,platform:s,elements:l}=t,{apply:d=()=>{},...c}=Gt(e,t),h=await Xi(t,c),u=Kt(i),p=Ga(i),v=Er(i)==="y",{width:b,height:y}=n.floating;let x,f;u==="top"||u==="bottom"?(x=u,f=p===(await(s.isRTL==null?void 0:s.isRTL(l.floating))?"start":"end")?"left":"right"):(f=u,x=p==="end"?"top":"bottom");const m=y-h.top-h.bottom,g=b-h.left-h.right,k=Tr(y-h[x],m),A=Tr(b-h[f],g),T=!t.middlewareData.shift;let E=k,C=A;if((r=t.middlewareData.shift)!=null&&r.enabled.x&&(C=g),(a=t.middlewareData.shift)!=null&&a.enabled.y&&(E=m),T&&!p){const q=Ve(h.left,0),W=Ve(h.right,0),L=Ve(h.top,0),U=Ve(h.bottom,0);v?C=b-2*(q!==0||W!==0?q+W:Ve(h.left,h.right)):E=y-2*(L!==0||U!==0?L+U:Ve(h.top,h.bottom))}await d({...t,availableWidth:C,availableHeight:E});const D=await s.getDimensions(l.floating);return b!==D.width||y!==D.height?{reset:{rects:!0}}:{}}}};function Ko(){return typeof window<"u"}function Ka(e){return Vg(e)?(e.nodeName||"").toLowerCase():"#document"}function Ge(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Pt(e){var t;return(t=(Vg(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Vg(e){return Ko()?e instanceof Node||e instanceof Ge(e).Node:!1}function bt(e){return Ko()?e instanceof Element||e instanceof Ge(e).Element:!1}function jt(e){return Ko()?e instanceof HTMLElement||e instanceof Ge(e).HTMLElement:!1}function Jh(e){return!Ko()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ge(e).ShadowRoot}function nn(e){const{overflow:t,overflowX:r,overflowY:a,display:i}=wt(e);return/auto|scroll|overlay|hidden|clip/.test(t+a+r)&&!["inline","contents"].includes(i)}function fA(e){return["table","td","th"].includes(Ka(e))}function Yo(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function nc(e){const t=oc(),r=bt(e)?wt(e):e;return["transform","translate","scale","rotate","perspective"].some(a=>r[a]?r[a]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(a=>(r.willChange||"").includes(a))||["paint","layout","strict","content"].some(a=>(r.contain||"").includes(a))}function gA(e){let t=Mr(e);for(;jt(t)&&!Ba(t);){if(nc(t))return t;if(Yo(t))return null;t=Mr(t)}return null}function oc(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Ba(e){return["html","body","#document"].includes(Ka(e))}function wt(e){return Ge(e).getComputedStyle(e)}function Jo(e){return bt(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Mr(e){if(Ka(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Jh(e)&&e.host||Pt(e);return Jh(t)?t.host:t}function Hg(e){const t=Mr(e);return Ba(t)?e.ownerDocument?e.ownerDocument.body:e.body:jt(t)&&nn(t)?t:Hg(t)}function Vi(e,t,r){var a;t===void 0&&(t=[]),r===void 0&&(r=!0);const i=Hg(e),n=i===((a=e.ownerDocument)==null?void 0:a.body),s=Ge(i);if(n){const l=Vl(s);
vendor: 7,338 bytes, line 143
143return t.concat(s,s.visualViewport||[],nn(i)?i:[],l&&r?Vi(l):[])}return t.concat(i,Vi(i,[],r))}function Vl(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function $g(e){const t=wt(e);let r=parseFloat(t.width)||0,a=parseFloat(t.height)||0;const i=jt(e),n=i?e.offsetWidth:r,s=i?e.offsetHeight:a,l=wo(r)!==n||wo(a)!==s;return l&&(r=n,a=s),{width:r,height:a,$:l}}function sc(e){return bt(e)?e:e.contextElement}function ka(e){const t=sc(e);if(!jt(t))return It(1);const r=t.getBoundingClientRect(),{width:a,height:i,$:n}=$g(t);let s=(n?wo(r.width):r.width)/a,l=(n?wo(r.height):r.height)/i;return(!s||!Number.isFinite(s))&&(s=1),(!l||!Number.isFinite(l))&&(l=1),{x:s,y:l}}const vA=It(0);function Gg(e){const t=Ge(e);return!oc()||!t.visualViewport?vA:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function yA(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==Ge(e)?!1:t}function Jr(e,t,r,a){t===void 0&&(t=!1),r===void 0&&(r=!1);const i=e.getBoundingClientRect(),n=sc(e);let s=It(1);t&&(a?bt(a)&&(s=ka(a)):s=ka(e));const l=yA(n,r,a)?Gg(n):It(0);let d=(i.left+l.x)/s.x,c=(i.top+l.y)/s.y,h=i.width/s.x,u=i.height/s.y;if(n){const p=Ge(n),v=a&&bt(a)?Ge(a):a;let b=p,y=Vl(b);for(;y&&a&&v!==b;){const x=ka(y),f=y.getBoundingClientRect(),m=wt(y),g=f.left+(y.clientLeft+parseFloat(m.paddingLeft))*x.x,k=f.top+(y.clientTop+parseFloat(m.paddingTop))*x.y;d*=x.x,c*=x.y,h*=x.x,u*=x.y,d+=g,c+=k,b=Ge(y),y=Vl(b)}}return ko({width:h,height:u,x:d,y:c})}function lc(e,t){const r=Jo(e).scrollLeft;return t?t.left+r:Jr(Pt(e)).left+r}function Kg(e,t,r){r===void 0&&(r=!1);const a=e.getBoundingClientRect(),i=a.left+t.scrollLeft-(r?0:lc(e,a)),n=a.top+t.scrollTop;return{x:i,y:n}}function bA(e){let{elements:t,rect:r,offsetParent:a,strategy:i}=e;const n=i==="fixed",s=Pt(a),l=t?Yo(t.floating):!1;if(a===s||l&&n)return r;let d={scrollLeft:0,scrollTop:0},c=It(1);const h=It(0),u=jt(a);if((u||!u&&!n)&&((Ka(a)!=="body"||nn(s))&&(d=Jo(a)),jt(a))){const v=Jr(a);c=ka(a),h.x=v.x+a.clientLeft,h.y=v.y+a.clientTop}const p=s&&!u&&!n?Kg(s,d,!0):It(0);return{width:r.width*c.x,height:r.height*c.y,x:r.x*c.x-d.scrollLeft*c.x+h.x+p.x,y:r.y*c.y-d.scrollTop*c.y+h.y+p.y}}function wA(e){return Array.from(e.getClientRects())}function xA(e){const t=Pt(e),r=Jo(e),a=e.ownerDocument.body,i=Ve(t.scrollWidth,t.clientWidth,a.scrollWidth,a.clientWidth),n=Ve(t.scrollHeight,t.clientHeight,a.scrollHeight,a.clientHeight);let s=-r.scrollLeft+lc(e);const l=-r.scrollTop;return wt(a).direction==="rtl"&&(s+=Ve(t.clientWidth,a.clientWidth)-i),{width:i,height:n,x:s,y:l}}function kA(e,t){const r=Ge(e),a=Pt(e),i=r.visualViewport;let n=a.clientWidth,s=a.clientHeight,l=0,d=0;if(i){n=i.width,s=i.height;const c=oc();(!c||c&&t==="fixed")&&(l=i.offsetLeft,d=i.offsetTop)}return{width:n,height:s,x:l,y:d}}function AA(e,t){const r=Jr(e,!0,t==="fixed"),a=r.top+e.clientTop,i=r.left+e.clientLeft,n=jt(e)?ka(e):It(1),s=e.clientWidth*n.x,l=e.clientHeight*n.y,d=i*n.x,c=a*n.y;return{width:s,height:l,x:d,y:c}}function Zh(e,t,r){let a;if(t==="viewport")a=kA(e,r);else if(t==="document")a=xA(Pt(e));else if(bt(t))a=AA(t,r);else{const i=Gg(e);a={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return ko(a)}function Yg(e,t){const r=Mr(e);return r===t||!bt(r)||Ba(r)?!1:wt(r).position==="fixed"||Yg(r,t)}function TA(e,t){const r=t.get(e);if(r)return r;let a=Vi(e,[],!1).filter(l=>bt(l)&&Ka(l)!=="body"),i=null;const n=wt(e).position==="fixed";let s=n?Mr(e):e;for(;bt(s)&&!Ba(s);){const l=wt(s),d=nc(s);!d&&l.position==="fixed"&&(i=null),(n?!d&&!i:!d&&l.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||nn(s)&&!d&&Yg(e,s))?a=a.filter(h=>h!==s):i=l,s=Mr(s)}return t.set(e,a),a}function EA(e){let{element:t,boundary:r,rootBoundary:a,strategy:i}=e;const s=[...r==="clippingAncestors"?Yo(t)?[]:TA(t,this._c):[].concat(r),a],l=s[0],d=s.reduce((c,h)=>{const u=Zh(t,h,i);return c.top=Ve(u.top,c.top),c.right=Tr(u.right,c.right),c.bottom=Tr(u.bottom,c.bottom),c.left=Ve(u.left,c.left),c},Zh(t,l,i));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function MA(e){const{width:t,height:r}=$g(e);return{width:t,height:r}}function SA(e,t,r){const a=jt(t),i=Pt(t),n=r==="fixed",s=Jr(e,!0,n,t);let l={scrollLeft:0,scrollTop:0};const d=It(0);if(a||!a&&!n)if((Ka(t)!=="body"||nn(i))&&(l=Jo(t)),a){const p=Jr(t,!0,n,t);d.x=p.x+t.clientLeft,d.y=p.y+t.clientTop}else i&&(d.x=lc(i));const c=i&&!a&&!n?Kg(i,l):It(0),h=s.left+l.scrollLeft-d.x-c.x,u=s.top+l.scrollTop-d.y-c.y;return{x:h,y:u,width:s.width,height:s.height}}function Ds(e){return wt(e).position==="static"}function eu(e,t){if(!jt(e)||wt(e).position==="fixed")return null;if(t)return t(e);let r=e.offsetParent;return Pt(e)===r&&(r=r.ownerDocument.body),r}function Jg(e,t){const r=Ge(e);if(Yo(e))return r;if(!jt(e)){let i=Mr(e);for(;i&&!Ba(i);){if(bt(i)&&!Ds(i))return i;i=Mr(i)}return r}let a=eu(e,t);for(;a&&fA(a)&&Ds(a);)a=eu(a,t);return a&&Ba(a)&&Ds(a)&&!nc(a)?r:a||gA(e)||r}const CA=async function(e){const t=this.getOffsetParent||Jg,r=this.getDimensions,a=await r(e.floating);return{reference:SA(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:a.width,height:a.height}}};function IA(e){return wt(e).direction==="rtl"}const RA={convertOffsetParentRelativeRectToViewportRelativeRect:bA,getDocumentElement:Pt,getClippingRect:EA,getOffsetParent:Jg,getElementRects:CA,getClientRects:wA,getDimensions:MA,getScale:ka,isElement:bt,isRTL:IA};function Zg(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function jA(e,t){let r=null,a;const i=Pt(e);function n(){var l;clearTimeout(a),(l=r)==null||l.disconnect(),r=null}function s(l,d){l===void 0&&(l=!1),d===void 0&&(d=1),n();const c=e.getBoundingClientRect(),{left:h,top:u,width:p,height:v}=c;if(l||t(),!p||!v)return;const b=Cn(u),y=Cn(i.clientWidth-(h+p)),x=Cn(i.clientHeight-(u+v)),f=Cn(h),g={rootMargin:-b+"px "+-y+"px "+-x+"px "+-f+"px",threshold:Ve(0,Tr(1,d))||1};let k=!0;function A(T){const E=T[0].intersectionRatio;if(E!==d){if(!k)return s();E?s(!1,E):a=setTimeout(()=>{s(!1,1e-7)},1e3)}E===1&&!Zg(c,e.getBoundingClientRect())&&s(),k=!1}try{r=new IntersectionObserver(A,{...g,root:i.ownerDocument})}catch{r=new IntersectionObserver(A,g)}r.observe(e)}return s(!0),n}function qA(e,t,r,a){a===void 0&&(a={});const{ancestorScroll:i=!0,ancestorResize:n=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:l=typeof IntersectionObserver=="function",animationFrame:d=!1}=a,c=sc(e),h=i||n?[...c?Vi(c):[],...Vi(t)]:[];h.forEach(f=>{i&&f.addEventListener("scroll",r,{passive:!0}),n&&f.addEventListener("resize",r)});const u=c&&l?jA(c,r):null;let p=-1,v=null;s&&(v=new ResizeObserver(f=>{let[m]=f;m&&m.target===c&&v&&(v.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var g;(g=v)==null||g.observe(t)})),r()}),c&&!d&&v.observe(c),v.observe(t));let b,y=d?Jr(e):null;d&&x();function x(){const f=Jr(e);y&&!Zg(y,f)&&r(),y=f,b=requestAnimationFrame(x)}return r(),()=>{var f;h.forEach(m=>{i&&m.removeEventListener("scroll",r),n&&m.removeEventListener("resize",r)}),u==null||u(),(f=v)==null||f.disconnect(),v=null,d&&cancelAnimationFrame(b)}}const PA=hA,DA=uA,LA=lA,NA=mA,OA=dA,tu=sA,FA=pA,QA=(e,t,r)=>{const a=new Map,i={platform:RA,...r},n={...i.platform,_c:a};return oA(e,t,{...i,platform:n})};var Xn=typeof document<"u"?w.useLayoutEffect:w.useEffect;function Ao(e,t){if(e===t)return!0;
vendor: 6,370 bytes, line 143
143if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let r,a,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(a=r;a--!==0;)if(!Ao(e[a],t[a]))return!1;return!0}if(i=Object.keys(e),r=i.length,r!==Object.keys(t).length)return!1;for(a=r;a--!==0;)if(!{}.hasOwnProperty.call(t,i[a]))return!1;for(a=r;a--!==0;){const n=i[a];if(!(n==="_owner"&&e.$$typeof)&&!Ao(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function ev(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function ru(e,t){const r=ev(e);return Math.round(t*r)/r}function Ls(e){const t=w.useRef(e);return Xn(()=>{t.current=e}),t}function WA(e){e===void 0&&(e={});const{placement:t="bottom",strategy:r="absolute",middleware:a=[],platform:i,elements:{reference:n,floating:s}={},transform:l=!0,whileElementsMounted:d,open:c}=e,[h,u]=w.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[p,v]=w.useState(a);Ao(p,a)||v(a);const[b,y]=w.useState(null),[x,f]=w.useState(null),m=w.useCallback(S=>{S!==T.current&&(T.current=S,y(S))},[]),g=w.useCallback(S=>{S!==E.current&&(E.current=S,f(S))},[]),k=n||b,A=s||x,T=w.useRef(null),E=w.useRef(null),C=w.useRef(h),D=d!=null,q=Ls(d),W=Ls(i),L=Ls(c),U=w.useCallback(()=>{if(!T.current||!E.current)return;const S={placement:t,strategy:r,middleware:p};W.current&&(S.platform=W.current),QA(T.current,E.current,S).then(R=>{const N={...R,isPositioned:L.current!==!1};P.current&&!Ao(C.current,N)&&(C.current=N,rn.flushSync(()=>{u(N)}))})},[p,t,r,W,L]);Xn(()=>{c===!1&&C.current.isPositioned&&(C.current.isPositioned=!1,u(S=>({...S,isPositioned:!1})))},[c]);const P=w.useRef(!1);Xn(()=>(P.current=!0,()=>{P.current=!1}),[]),Xn(()=>{if(k&&(T.current=k),A&&(E.current=A),k&&A){if(q.current)return q.current(k,A,U);U()}},[k,A,U,q,D]);const H=w.useMemo(()=>({reference:T,floating:E,setReference:m,setFloating:g}),[m,g]),B=w.useMemo(()=>({reference:k,floating:A}),[k,A]),V=w.useMemo(()=>{const S={position:r,left:0,top:0};if(!B.floating)return S;const R=ru(B.floating,h.x),N=ru(B.floating,h.y);return l?{...S,transform:"translate("+R+"px, "+N+"px)",...ev(B.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:R,top:N}},[r,l,B.floating,h.x,h.y]);return w.useMemo(()=>({...h,update:U,refs:H,elements:B,floatingStyles:V}),[h,U,H,B,V])}const zA=e=>{function t(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){const{element:a,padding:i}=typeof e=="function"?e(r):e;return a&&t(a)?a.current!=null?tu({element:a.current,padding:i}).fn(r):{}:a?tu({element:a,padding:i}).fn(r):{}}}},BA=(e,t)=>({...PA(e),options:[e,t]}),_A=(e,t)=>({...DA(e),options:[e,t]}),UA=(e,t)=>({...FA(e),options:[e,t]}),XA=(e,t)=>({...LA(e),options:[e,t]}),VA=(e,t)=>({...NA(e),options:[e,t]}),HA=(e,t)=>({...OA(e),options:[e,t]}),$A=(e,t)=>({...zA(e),options:[e,t]});var GA="Arrow",tv=w.forwardRef((e,t)=>{const{children:r,width:a=10,height:i=5,...n}=e;return o.jsx(ze.svg,{...n,ref:t,width:a,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:o.jsx("polygon",{points:"0,0 30,0 15,10"})})});tv.displayName=GA;var KA=tv;function YA(e){const[t,r]=w.useState(void 0);return Yr(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});const a=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const n=i[0];let s,l;if("borderBoxSize"in n){const d=n.borderBoxSize,c=Array.isArray(d)?d[0]:d;s=c.inlineSize,l=c.blockSize}else s=e.offsetWidth,l=e.offsetHeight;r({width:s,height:l})});return a.observe(e,{box:"border-box"}),()=>a.unobserve(e)}else r(void 0)},[e]),t}var rv="Popper",[av,iv]=Uo(rv),[o4,nv]=av(rv),ov="PopperAnchor",sv=w.forwardRef((e,t)=>{const{__scopePopper:r,virtualRef:a,...i}=e,n=nv(ov,r),s=w.useRef(null),l=yt(t,s);return w.useEffect(()=>{n.onAnchorChange((a==null?void 0:a.current)||s.current)}),a?null:o.jsx(ze.div,{...i,ref:l})});sv.displayName=ov;var dc="PopperContent",[JA,ZA]=av(dc),lv=w.forwardRef((e,t)=>{var qr,hc,uc,pc,mc,fc;const{__scopePopper:r,side:a="bottom",sideOffset:i=0,align:n="center",alignOffset:s=0,arrowPadding:l=0,avoidCollisions:d=!0,collisionBoundary:c=[],collisionPadding:h=0,sticky:u="partial",hideWhenDetached:p=!1,updatePositionStrategy:v="optimized",onPlaced:b,...y}=e,x=nv(dc,r),[f,m]=w.useState(null),g=yt(t,Ja=>m(Ja)),[k,A]=w.useState(null),T=YA(k),E=(T==null?void 0:T.width)??0,C=(T==null?void 0:T.height)??0,D=a+(n!=="center"?"-"+n:""),q=typeof h=="number"?h:{top:0,right:0,bottom:0,left:0,...h},W=Array.isArray(c)?c:[c],L=W.length>0,U={padding:q,boundary:W.filter(tT),altBoundary:L},{refs:P,floatingStyles:H,placement:B,isPositioned:V,middlewareData:S}=WA({strategy:"fixed",placement:D,whileElementsMounted:(...Ja)=>qA(...Ja,{animationFrame:v==="always"}),elements:{reference:x.anchor},middleware:[BA({mainAxis:i+C,alignmentAxis:s}),d&&_A({mainAxis:!0,crossAxis:!1,limiter:u==="partial"?UA():void 0,...U}),d&&XA({...U}),VA({...U,apply:({elements:Ja,rects:gc,availableWidth:Rv,availableHeight:jv})=>{const{width:qv,height:Pv}=gc.reference,on=Ja.floating.style;on.setProperty("--radix-popper-available-width",`${Rv}px`),on.setProperty("--radix-popper-available-height",`${jv}px`),on.setProperty("--radix-popper-anchor-width",`${qv}px`),on.setProperty("--radix-popper-anchor-height",`${Pv}px`)}}),k&&$A({element:k,padding:l}),rT({arrowWidth:E,arrowHeight:C}),p&&HA({strategy:"referenceHidden",...U})]}),[R,N]=hv(B),z=Rt(b);Yr(()=>{V&&(z==null||z())},[V,z]);const te=(qr=S.arrow)==null?void 0:qr.x,st=(hc=S.arrow)==null?void 0:hc.y,Ze=((uc=S.arrow)==null?void 0:uc.centerOffset)!==0,[Ya,Dt]=w.useState();return Yr(()=>{f&&Dt(window.getComputedStyle(f).zIndex)},[f]),o.jsx("div",{ref:P.setFloating,"data-radix-popper-content-wrapper":"",style:{...H,transform:V?H.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Ya,"--radix-popper-transform-origin":[(pc=S.transformOrigin)==null?void 0:pc.x,(mc=S.transformOrigin)==null?void 0:mc.y].join(" "),...((fc=S.hide)==null?void 0:fc.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:o.jsx(JA,{scope:r,placedSide:R,onArrowChange:A,arrowX:te,arrowY:st,shouldHideArrow:Ze,children:o.jsx(ze.div,{"data-side":R,"data-align":N,...y,ref:g,style:{...y.style,animation:V?void 0:"none"}})})})});lv.displayName=dc;var dv="PopperArrow",eT={top:"bottom",right:"left",bottom:"top",left:"r
143ight"},cv=w.forwardRef(function(t,r){const{__scopePopper:a,...i}=t,n=ZA(dv,a),s=eT[n.placedSide];return o.jsx("span",{ref:n.onArrowChange,style:{position:"absolute",left:n.arrowX,top:n.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[n.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[n.placedSide],visibility:n.shouldHideArrow?"hidden":void 0},children:o.jsx(KA,{...i,ref:r,style:{...i.style,display:"block"}})})});cv.displayName=dv;function tT(e){return e!==null}var rT=e=>({name:"transformOrigin",options:e,fn(t){var x,f,m;const{placement:r,rects:a,middlewareData:i}=t,s=((x=i.arrow)==null?void 0:x.centerOffset)!==0,l=s?0:e.arrowWidth,d=s?0:e.arrowHeight,[c,h]=hv(r),u={start:"0%",center:"50%",end:"100%"}[h],p=(((f=i.arrow)==null?void 0:f.x)??0)+l/2,v=(((m=i.arrow)==null?void 0:m.y)??0)+d/2;let b="",y="";return c==="bottom"?(b=s?u:`${p}px`,y=`${-d}px`):c==="top"?(b=s?u:`${p}px`,y=`${a.floating.height+d}px`):c==="right"?(b=`${-d}px`,y=s?u:`${v}px`):c==="left"&&(b=`${a.floating.width+d}px`,y=s?u:`${v}px`),{data:{x:b,y}}}});function hv(e){const[t,r="center"]=e.split("-");return[t,r]}var aT=sv,iT=lv,nT=cv,[Zo,s4]=Uo("Tooltip",[iv]),cc=iv(),uv="TooltipProvider",oT=700,au="tooltip.open",[sT,pv]=Zo(uv),mv=e=>{const{__scopeTooltip:t,delayDuration:r=oT,skipDelayDuration:a=300,disableHoverableContent:i=!1,children:n}=e,s=w.useRef(!0),l=w.useRef(!1),d=w.useRef(0);return w.useEffect(()=>{const c=d.current;return()=>window.clearTimeout(c)},[]),o.jsx(sT,{scope:t,isOpenDelayedRef:s,delayDuration:r,onOpen:w.useCallback(()=>{window.clearTimeout(d.current),s.current=!1},[]),onClose:w.useCallback(()=>{window.clearTimeout(d.current),d.current=window.setTimeout(()=>s.current=!0,a)},[a]),isPointerInTransitRef:l,onPointerInTransitChange:w.useCallback(c=>{l.current=c},[]),disableHoverableContent:i,children:n})};mv.displayName=uv;var fv="Tooltip",[l4,es]=Zo(fv),Hl="TooltipTrigger",lT=w.forwardRef((e,t)=>{const{__scopeTooltip:r,...a}=e,i=es(Hl,r),n=pv(Hl,r),s=cc(r),l=w.useRef(null),d=yt(t,l,i.onTriggerChange),c=w.useRef(!1),h=w.useRef(!1),u=w.useCallback(()=>c.current=!1,[]);return w.useEffect(()=>()=>document.removeEventListener("pointerup",u),[u]),o.jsx(aT,{asChild:!0,...s,children:o.jsx(ze.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...a,ref:d,onPointerMove:pe(e.onPointerMove,p=>{p.pointerType!=="touch"&&!h.current&&!n.isPointerInTransitRef.current&&(i.onTriggerEnter(),h.current=!0)}),onPointerLeave:pe(e.onPointerLeave,()=>{i.onTriggerLeave(),h.current=!1}),onPointerDown:pe(e.onPointerDown,()=>{i.open&&i.onClose(),c.current=!0,document.addEventListener("pointerup",u,{once:!0})}),onFocus:pe(e.onFocus,()=>{c.current||i.onOpen()}),onBlur:pe(e.onBlur,i.onClose),onClick:pe(e.onClick,i.onClose)})})});lT.displayName=Hl;var dT="TooltipPortal",[d4,cT]=Zo(dT,{forceMount:void 0}),_a="TooltipContent",gv=w.forwardRef((e,t)=>{const r=cT(_a,e.__scopeTooltip),{forceMount:a=r.forceMount,side:i="top",...n}=e,s=es(_a,e.__scopeTooltip);return o.jsx(Kd,{present:a||s.open,children:s.disableHoverableContent?o.jsx(vv,{side:i,...n,ref:t}):o.jsx(hT,{side:i,...n,ref:t})})}),hT=w.forwardRef((e,t)=>{const r=es(_a,e.__scopeTooltip),a=pv(_a,e.__scopeTooltip),i=w.useRef(null),n=yt(t,i),[s,l]=w.useState(null),{trigger:d,onClose:c}=r,h=i.current,{onPointerInTransitChange:u}=a,p=w.useCallback(()=>{l(null),u(!1)},[u]),v=w.useCallback((b,y)=>{const x=b.currentTarget,f={x:b.clientX,y:b.clientY},m=gT(f,x.getBoundingClientRect()),g=vT(f,m),k=yT(y.getBoundingClientRect()),A=wT([...g,...k]);l(A),u(!0)},[u]);return w.useEffect(()=>()=>p(),[p]),w.useEffect(()=>{if(d&&h){const b=x=>v(x,h),y=x=>v(x,d);return d.addEventListener("pointerleave",b),h.addEventListener("pointerleave",y),()=>{d.removeEventListener("pointerleave",b),h.removeEventListener("pointerleave",y)}}},[d,h,v,p]),w.useEffect(()=>{if(s){const b=y=>{const x=y.target,f={x:y.clientX,y:y.clientY},m=(d==null?void 0:d.contains(x))||(h==null?void 0:h.contains(x)),g=!bT(f,s);m?p():g&&(p(),c())};return document.addEventListener("pointermove",b),()=>document.removeEventListener("pointermove",b)}},[d,h,s,c,p]),o.jsx(vv,{...e,ref:n})}),[uT,pT]=Zo(fv,{isInside:!1}),mT=bx("TooltipContent"),vv=w.forwardRef((e,t)=>
143{const{__scopeTooltip:r,children:a,"aria-label":i,onEscapeKeyDown:n,onPointerDownOutside:s,...l}=e,d=es(_a,r),c=cc(r),{onClose:h}=d;return w.useEffect(()=>(document.addEventListener(au,h),()=>document.removeEventListener(au,h)),[h]),w.useEffect(()=>{if(d.trigger){const u=p=>{const v=p.target;v!=null&&v.contains(d.trigger)&&h()};return window.addEventListener("scroll",u,{capture:!0}),()=>window.removeEventListener("scroll",u,{capture:!0})}},[d.trigger,h]),o.jsx(Gd,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:n,onPointerDownOutside:s,onFocusOutside:u=>u.preventDefault(),onDismiss:h,children:o.jsxs(iT,{"data-state":d.stateAttribute,...c,...l,ref:t,style:{...l.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[o.jsx(mT,{children:a}),o.jsx(uT,{scope:r,isInside:!0,children:o.jsx(zx,{id:d.contentId,role:"tooltip",children:i||a})})]})})});gv.displayName=_a;var yv="TooltipArrow",fT=w.forwardRef((e,t)=>{const{__scopeTooltip:r,...a}=e,i=cc(r);return pT(yv,r).isInside?null:o.jsx(nT,{...i,...a,ref:t})});fT.displayName=yv;function gT(e,t){const r=Math.abs(t.top-e.y),a=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),n=Math.abs(t.left-e.x);switch(Math.min(r,a,i,n)){case n:return"left";case i:return"right";case r:return"top";case a:return"bottom";default:throw new Error("unreachable")}}function vT(e,t,r=5){const a=[];switch(t){case"top":a.push({x:e.x-r,y:e.y+r},{x:e.x+r,y:e.y+r});break;case"bottom":a.push({x:e.x-r,y:e.y-r},{x:e.x+r,y:e.y-r});break;case"left":a.push({x:e.x+r,y:e.y-r},{x:e.x+r,y:e.y+r});break;case"right":a.push({x:e.x-r,y:e.y-r},{x:e.x-r,y:e.y+r});break}return a}function yT(e){const{top:t,right:r,bottom:a,left:i}=e;return[{x:i,y:t},{x:r,y:t},{x:r,y:a},{x:i,y:a}]}function bT(e,t){const{x:r,y:a}=e;let i=!1;for(let n=0,s=t.length-1;n<t.length;s=n++){const l=t[n].x,d=t[n].y,c=t[s].x,h=t[s].y;d>a!=h>a&&r<(c-l)*(a-d)/(h-d)+l&&(i=!i)}return i}function wT(e){const t=e.slice();return t.sort((r,a)=>r.x<a.x?-1:r.x>a.x?1:r.y<a.y?-1:r.y>a.y?1:0),xT(t)}function xT(e){if(e.length<=1)return e.slice();const t=[];for(let a=0;a<e.length;a++){const i=e[a];for(;t.length>=2;){const n=t[t.length-1],s=t[t.length-2];if((n.x-s.x)*(i.y-s.y)>=(n.y-s.y)*(i.x-s.x))t.pop();else break}t.push(i)}t.pop();const r=[];for(let a=e.length-1;a>=0;a--){const i=e[a];for(;r.length>=2;){const n=r[r.length-1],s=r[r.length-2];if((n.x-s.x)*(i.y-s.y)>=(n.y-s.y)*(i.x-s.x))r.pop();else break}r.push(i)}return r.pop(),t.length===1&&r.length===1&&t[0].x===r[0].x&&t[0].y===r[0].y?t:t.concat(r)}var kT=mv,bv=gv;const AT=kT,TT=w.forwardRef(({className:e,sideOffset:t=4,...r},a)=>o.jsx(bv,{ref:a,sideOffset:t,className:De("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-tooltip-content-transform-origin]",e),...r}));TT.displayName=bv.displayName;var wv={exports:{}},ET="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",MT=ET,ST=MT;function xv(){}function kv(){}kv.resetWarningCache=xv;var CT=function(){function e(a,i,n,s,l,d){if(d!==ST){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}e.isRequired=e;function t(){return e}var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:kv,resetWarningCache:xv};return r.PropTypes=r,r};wv.exports=CT();var IT=wv.exports;const re=Ua(IT);function RT(e){return e&&typeof e=="object"&&"default"in e?e.default:e}var Av=w,jT=RT(Av);function iu(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function qT(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var PT=!!(typeof window<"u"&&window.document&&window.document.createElement);function DT(e,t,r){if(typeof e!="function")throw new Error("Expected reducePropsToState to be a function.");
143if(typeof t!="function")throw new Error("Expected handleStateChangeOnClient to be a function.");if(typeof r<"u"&&typeof r!="function")throw new Error("Expected mapStateOnServer to either be undefined or a function.");function a(i){return i.displayName||i.name||"Component"}return function(n){if(typeof n!="function")throw new Error("Expected WrappedComponent to be a React component.");var s=[],l;function d(){l=e(s.map(function(h){return h.props})),c.canUseDOM?t(l):r&&(l=r(l))}var c=function(h){qT(u,h);function u(){return h.apply(this,arguments)||this}u.peek=function(){return l},u.rewind=function(){if(u.canUseDOM)throw new Error("You may only call rewind() on the server. Call peek() to read the current state.");var b=l;return l=void 0,s=[],b};var p=u.prototype;return p.UNSAFE_componentWillMount=function(){s.push(this),d()},p.componentDidUpdate=function(){d()},p.componentWillUnmount=function(){var b=s.indexOf(this);s.splice(b,1),d()},p.render=function(){return jT.createElement(n,this.props)},u}(Av.PureComponent);return iu(c,"displayName","SideEffect("+a(n)+")"),iu(c,"canUseDOM",PT),c}}var LT=DT;const NT=Ua(LT);var OT=typeof Element<"u",FT=typeof Map=="function",QT=typeof Set=="function",WT=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function Vn(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var r,a,i;if(Array.isArray(e)){if(r=e.length,r!=t.length)return!1;for(a=r;a--!==0;)if(!Vn(e[a],t[a]))return!1;return!0}var n;if(FT&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(n=e.entries();!(a=n.next()).done;)if(!t.has(a.value[0]))return!1;for(n=e.entries();!(a=n.next()).done;)if(!Vn(a.value[1],t.get(a.value[0])))return!1;return!0}if(QT&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(n=e.entries();!(a=n.next()).done;)if(!t.has(a.value[0]))return!1;return!0}if(WT&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(r=e.length,r!=t.length)return!1;for(a=r;a--!==0;)if(e[a]!==t[a])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(i=Object.keys(e),r=i.length,r!==Object.keys(t).length)return!1;for(a=r;a--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[a]))return!1;if(OT&&e instanceof Element)return!1;for(a=r;a--!==0;)if(!((i[a]==="_owner"||i[a]==="__v"||i[a]==="__o")&&e.$$typeof)&&!Vn(e[i[a]],t[i[a]]))return!1;return!0}return e!==e&&t!==t}var zT=function(t,r){try{return Vn(t,r)}catch(a){if((a.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw a}};const BT=Ua(zT);/*
144object-assign
145(c) Sindre Sorhus
146@license MIT
147*/var nu=Object.getOwnPropertySymbols,_T=Object.prototype.hasOwnProperty,UT=Object.prototype.propertyIsEnumerable;function XT(e){if(e==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function VT(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de",Object.getOwnPropertyNames(e)[0]==="5")return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;var a=Object.getOwnPropertyNames(t).map(function(n){return t[n]});if(a.join("")!=="0123456789")return!1;var i={};return"abcdefghijklmnopqrst".split("").forEach(function(n){i[n]=n}),Object.keys(Object.assign({},i)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}var HT=VT()?Object.assign:function(e,t){for(var r,a=XT(e),i,n=1;n<arguments.length;n++){r=Object(arguments[n]);for(var s in r)_T.call(r,s)&&(a[s]=r[s]);if(nu){i=nu(r);for(var l=0;l<i.length;l++)UT.call(r,i[l])&&(a[i[l]]=r[i[l]])}}return a};const $T=Ua(HT);var Xr={BODY:"bodyAttributes",HTML:"htmlAttributes",TITLE:"titleAttributes"},O={BASE:"base",BODY:"body",HEAD:"head",HTML:"html",LINK:"link",META:"meta",NOSCRIPT:"noscript",SCRIPT:"script",STYLE:"style",TITLE:"title"};Object.keys(O).map(function(e){return O[e]});var ae={CHARSET:"charset",CSS_TEXT:"cssText",HREF:"href",HTTPEQUIV:"http-equiv",INNER_HTML:"innerHTML",ITEM_PROP:"itemprop",NAME:"name",PROPERTY:"property",REL:"rel",SRC:"src",TARGET:"target"},To={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},Hi={DEFAULT_TITLE:"defaultTitle",DEFER:"defer",ENCODE_SPECIAL_CHARACTERS:"encodeSpecialCharacters",ON_CHANGE_CLIENT_STATE:"onChangeClientState",TITLE_TEMPLATE:"titleTemplate"},GT=Object.keys(To).reduce(function(e,t){return e[To[t]]=t,e},{}),KT=[O.NOSCRIPT,O.SCRIPT,O.STYLE],mt="data-react-helmet",YT=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},JT=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},ZT=function(){function e(t,r){for(var a=0;a<r.length;a++){var i=r[a];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(t,r,a){return r&&e(t.prototype,r),a&&e(t,a),t}}(),Le=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e},eE=function(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)},ou=function(e,t){var r={};for(var a in e)t.indexOf(a)>=0||Object.prototype.hasOwnProperty.call(e,a)&&(r[a]=e[a]);return r},tE=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t&&(typeof t=="object"||typeof t=="function")?t:e},$l=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return r===!1?String(t):String(t).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;")},rE=function(t){var r=Aa(t,O.TITLE),a=Aa(t,Hi.TITLE_TEMPLATE);if(a&&r)return a.replace(/%s/g,function(){return Array.isArray(r)?r.join(""):r});var i=Aa(t,Hi.DEFAULT_TITLE);return r||i||void 0},aE=function(t){return Aa(t,Hi.ON_CHANGE_CLIENT_STATE)||function(){}},Ns=function(t,r){return r.filter(function(a){return typeof a[t]<"u"}).map(function(a){return a[t]}).reduce(function(a,i){return Le({},a,i)},{})},iE=function(t,r){return r.filter(function(a){return typeof a[O.BASE]<"u"}).map(function(a){return a[O.BASE]}).reverse().reduce(function(a,i){if(!a.length)for(var n=Object.keys(i),s=0;s<n.length;s++){var l=n[s],d=l.toLowerCase();if(t.indexOf(d)!==-1&&i[d])return a.concat(i)}return a},[])},di=function(t,r,a){var i={};return a.filter(function(n){return Array.isArray(n[t])?!0:(typeof n[t]<"u"&&lE("Helmet: "+t+' should be of type "Array". Instead found type "'+YT(n[t])+'"'),!1)}).map(function(n){return n[t]}).reverse().reduce(function(n,s){var l={};s.filter(function(p){for(var v=void 0,b=Object.keys(p),y=0;y<b.length;y++){var x=b[y],f=x.toLowerCase();r.indexOf(f)!==-1&&!(v===ae.REL&&p[v].toLowerCase()==="canonical")&&!(f===ae.REL&&p[f].toLowerCase()==="stylesheet")&&(v=f),r.indexOf(x)!==-1&&(x===ae.INNER_HTML||x===ae.CSS_TEXT||x===ae.ITEM_PROP)&&(v=x)}if(!v||!p[v])return!1;var m=p[v].toLowerCase();return i[v]||(i[v]={}),l[v]||(l[v]={}),i[v][m]?!1:(l[v][m]=!0,!0)}
147).reverse().forEach(function(p){return n.push(p)});for(var d=Object.keys(l),c=0;c<d.length;c++){var h=d[c],u=$T({},i[h],l[h]);i[h]=u}return n},[]).reverse()},Aa=function(t,r){for(var a=t.length-1;a>=0;a--){var i=t[a];if(i.hasOwnProperty(r))return i[r]}return null},nE=function(t){return{baseTag:iE([ae.HREF,ae.TARGET],t),bodyAttributes:Ns(Xr.BODY,t),defer:Aa(t,Hi.DEFER),encode:Aa(t,Hi.ENCODE_SPECIAL_CHARACTERS),htmlAttributes:Ns(Xr.HTML,t),linkTags:di(O.LINK,[ae.REL,ae.HREF],t),metaTags:di(O.META,[ae.NAME,ae.CHARSET,ae.HTTPEQUIV,ae.PROPERTY,ae.ITEM_PROP],t),noscriptTags:di(O.NOSCRIPT,[ae.INNER_HTML],t),onChangeClientState:aE(t),scriptTags:di(O.SCRIPT,[ae.SRC,ae.INNER_HTML],t),styleTags:di(O.STYLE,[ae.CSS_TEXT],t),title:rE(t),titleAttributes:Ns(Xr.TITLE,t)}},Gl=function(){var e=Date.now();return function(t){var r=Date.now();r-e>16?(e=r,t(r)):setTimeout(function(){Gl(t)},0)}}(),su=function(t){return clearTimeout(t)},oE=typeof window<"u"?window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||Gl:global.requestAnimationFrame||Gl,sE=typeof window<"u"?window.cancelAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame||su:global.cancelAnimationFrame||su,lE=function(t){return console&&typeof console.warn=="function"&&console.warn(t)},ci=null,dE=function(t){ci&&sE(ci),t.defer?ci=oE(function(){lu(t,function(){ci=null})}):(lu(t),ci=null)},lu=function(t,r){var a=t.baseTag,i=t.bodyAttributes,n=t.htmlAttributes,s=t.linkTags,l=t.metaTags,d=t.noscriptTags,c=t.onChangeClientState,h=t.scriptTags,u=t.styleTags,p=t.title,v=t.titleAttributes;Kl(O.BODY,i),Kl(O.HTML,n),cE(p,v);var b={baseTag:ra(O.BASE,a),linkTags:ra(O.LINK,s),metaTags:ra(O.META,l),noscriptTags:ra(O.NOSCRIPT,d),scriptTags:ra(O.SCRIPT,h),styleTags:ra(O.STYLE,u)},y={},x={};Object.keys(b).forEach(function(f){var m=b[f],g=m.newTags,k=m.oldTags;g.length&&(y[f]=g),k.length&&(x[f]=b[f].oldTags)}),r&&r(),c(t,y,x)},Tv=function(t){return Array.isArray(t)?t.join(""):t},cE=function(t,r){typeof t<"u"&&document.title!==t&&(document.title=Tv(t)),Kl(O.TITLE,r)},Kl=function(t,r){var a=document.getElementsByTagName(t)[0];if(a){for(var i=a.getAttribute(mt),n=i?i.split(","):[],s=[].concat(n),l=Object.keys(r),d=0;d<l.length;d++){var c=l[d],h=r[c]||"";a.getAttribute(c)!==h&&a.setAttribute(c,h),n.indexOf(c)===-1&&n.push(c);var u=s.indexOf(c);u!==-1&&s.splice(u,1)}for(var p=s.length-1;p>=0;p--)a.removeAttribute(s[p]);n.length===s.length?a.removeAttribute(mt):a.getAttribute(mt)!==l.join(",")&&a.setAttribute(mt,l.join(","))}},ra=function(t,r){var a=document.head||document.querySelector(O.HEAD),i=a.querySelectorAll(t+"["+mt+"]"),n=Array.prototype.slice.call(i),s=[],l=void 0;return r&&r.length&&r.forEach(function(d){var c=document.createElement(t);for(var h in d)if(d.hasOwnProperty(h))if(h===ae.INNER_HTML)c.innerHTML=d.innerHTML;else if(h===ae.CSS_TEXT)c.styleSheet?c.styleSheet.cssText=d.cssText:c.appendChild(document.createTextNode(d.cssText));else{var u=typeof d[h]>"u"?"":d[h];c.setAttribute(h,u)}c.setAttribute(mt,"true"),n.some(function(p,v){return l=v,c.isEqualNode(p)})?n.splice(l,1):s.push(c)}),n.forEach(function(d){return d.parentNode.removeChild(d)}),s.forEach(function(d){return a.appendChild(d)}),{oldTags:n,newTags:s}},Ev=function(t){return Object.keys(t).reduce(function(r,a){var i=typeof t[a]<"u"?a+'="'+t[a]+'"':""+a;return r?r+" "+i:i},"")},hE=function(t,r,a,i){var n=Ev(a),s=Tv(r);return n?"<"+t+" "+mt+'="true" '+n+">"+$l(s,i)+"</"+t+">":"<"+t+" "+mt+'="true">'+$l(s,i)+"</"+t+">"},uE=function(t,r,a){return r.reduce(function(i,n){var s=Object.keys(n).filter(function(c){return!(c===ae.INNER_HTML||c===ae.CSS_TEXT)}).reduce(function(c,h){var u=typeof n[h]>"u"?h:h+'="'+$l(n[h],a)+'"';return c?c+" "+u:u},""),l=n.innerHTML||n.cssText||"",d=KT.indexOf(t)===-1;return i+"<"+t+" "+mt+'="true" '+s+(d?"/>":">"+l+"</"+t+">")},"")},Mv=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return Object.keys(t).reduce(function(a,i){return a[To[i]||i]=t[i],a},r)},pE=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return Object.keys(t).reduce(function(a,i){return a[GT[i]||i]=t[i],a},r)},mE=function(t,r,a){var i,n=(i={key:r},i[mt]=!0,i),s=Mv(a,n);
147return[Xe.createElement(O.TITLE,s,r)]},fE=function(t,r){return r.map(function(a,i){var n,s=(n={key:i},n[mt]=!0,n);return Object.keys(a).forEach(function(l){var d=To[l]||l;if(d===ae.INNER_HTML||d===ae.CSS_TEXT){var c=a.innerHTML||a.cssText;s.dangerouslySetInnerHTML={__html:c}}else s[d]=a[l]}),Xe.createElement(t,s)})},Ot=function(t,r,a){switch(t){case O.TITLE:return{toComponent:function(){return mE(t,r.title,r.titleAttributes)},toString:function(){return hE(t,r.title,r.titleAttributes,a)}};case Xr.BODY:case Xr.HTML:return{toComponent:function(){return Mv(r)},toString:function(){return Ev(r)}};default:return{toComponent:function(){return fE(t,r)},toString:function(){return uE(t,r,a)}}}},Sv=function(t){var r=t.baseTag,a=t.bodyAttributes,i=t.encode,n=t.htmlAttributes,s=t.linkTags,l=t.metaTags,d=t.noscriptTags,c=t.scriptTags,h=t.styleTags,u=t.title,p=u===void 0?"":u,v=t.titleAttributes;return{base:Ot(O.BASE,r,i),bodyAttributes:Ot(Xr.BODY,a,i),htmlAttributes:Ot(Xr.HTML,n,i),link:Ot(O.LINK,s,i),meta:Ot(O.META,l,i),noscript:Ot(O.NOSCRIPT,d,i),script:Ot(O.SCRIPT,c,i),style:Ot(O.STYLE,h,i),title:Ot(O.TITLE,{title:p,titleAttributes:v},i)}},gE=function(t){var r,a;return a=r=function(i){eE(n,i);function n(){return JT(this,n),tE(this,i.apply(this,arguments))}return n.prototype.shouldComponentUpdate=function(l){return!BT(this.props,l)},n.prototype.mapNestedChildrenToProps=function(l,d){if(!d)return null;switch(l.type){case O.SCRIPT:case O.NOSCRIPT:return{innerHTML:d};case O.STYLE:return{cssText:d}}throw new Error("<"+l.type+" /> elements are self-closing and can not contain children. Refer to our API for more information.")},n.prototype.flattenArrayTypeChildren=function(l){var d,c=l.child,h=l.arrayTypeChildren,u=l.newChildProps,p=l.nestedChildren;return Le({},h,(d={},d[c.type]=[].concat(h[c.type]||[],[Le({},u,this.mapNestedChildrenToProps(c,p))]),d))},n.prototype.mapObjectTypeChildren=function(l){var d,c,h=l.child,u=l.newProps,p=l.newChildProps,v=l.nestedChildren;switch(h.type){case O.TITLE:return Le({},u,(d={},d[h.type]=v,d.titleAttributes=Le({},p),d));case O.BODY:return Le({},u,{bodyAttributes:Le({},p)});case O.HTML:return Le({},u,{htmlAttributes:Le({},p)})}return Le({},u,(c={},c[h.type]=Le({},p),c))},n.prototype.mapArrayTypeChildrenToProps=function(l,d){var c=Le({},d);return Object.keys(l).forEach(function(h){var u;c=Le({},c,(u={},u[h]=l[h],u))}),c}
147,n.prototype.warnOnInvalidChildren=function(l,d){return!0},n.prototype.mapChildrenToProps=function(l,d){var c=this,h={};return Xe.Children.forEach(l,function(u){if(!(!u||!u.props)){var p=u.props,v=p.children,b=ou(p,["children"]),y=pE(b);switch(c.warnOnInvalidChildren(u,v),u.type){case O.LINK:case O.META:case O.NOSCRIPT:case O.SCRIPT:case O.STYLE:h=c.flattenArrayTypeChildren({child:u,arrayTypeChildren:h,newChildProps:y,nestedChildren:v});break;default:d=c.mapObjectTypeChildren({child:u,newProps:d,newChildProps:y,nestedChildren:v});break}}}),d=this.mapArrayTypeChildrenToProps(h,d),d},n.prototype.render=function(){var l=this.props,d=l.children,c=ou(l,["children"]),h=Le({},c);return d&&(h=this.mapChildrenToProps(d,h)),Xe.createElement(t,h)},ZT(n,null,[{key:"canUseDOM",set:function(l){t.canUseDOM=l}}]),n}(Xe.Component),r.propTypes={base:re.object,bodyAttributes:re.object,children:re.oneOfType([re.arrayOf(re.node),re.node]),defaultTitle:re.string,defer:re.bool,encodeSpecialCharacters:re.bool,htmlAttributes:re.object,link:re.arrayOf(re.object),meta:re.arrayOf(re.object),noscript:re.arrayOf(re.object),onChangeClientState:re.func,script:re.arrayOf(re.object),style:re.arrayOf(re.object),title:re.string,titleAttributes:re.object,titleTemplate:re.string},r.defaultProps={defer:!0,encodeSpecialCharacters:!0},r.peek=t.peek,r.rewind=function(){var i=t.rewind();return i||(i=Sv({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}})),i},a},vE=function(){return null},yE=NT(nE,dE,Sv)(vE),qt=gE(yE);qt.renderStatic=qt.rewind;const bE=ec("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0 hover-elevate active-elevate-2",{variants:{variant:{default:"bg-primary text-primary-foreground border border-primary-border",destructive:"bg-destructive text-destructive-foreground border border-destructive-border",outline:" border [border-color:var(--button-outline)]  shadow-xs active:shadow-none ",secondary:"border bg-secondary text-secondary-foreground border border-secondary-border ",ghost:"border border-transparent"},size:{default:"min-h-9 px-4 py-2",sm:"min-h-8 rounded-md px-3 text-xs",lg:"min-h-10 rounded-md px-8",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),Ie=w.forwardRef(({className:e,variant:t,size:r,asChild:a=!1,...i},n)=>{const s=a?vx:"button";return o.jsx(s,{className:De(bE({variant:t,size:r,className:e})),ref:n,...i})});Ie.displayName="Button";const wE="/assets/favicon_1771965015077-P4RZGBe0.png";function Rr(){const[e]=$f(),t=e==="/";return o.jsx("header",{className:"sticky top-0 z-50 w-full border-b bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60",children:o.jsxs("div",{className:"max-w-7xl mx-auto px-4 sm:px-6 h-14 sm:h-16 flex items-center justify-between gap-2",children:[o.jsx(Z,{href:"/",className:"flex items-center gap-2 hover:opacity-80 transition-opacity cursor-pointer","data-testid":"link-home-logo",children:o.jsx("img",{src:wE,alt:"EX4 Decompiler",className:"h-8 w-8 sm:h-9 sm:w-9"})}),!t&&o.jsxs("nav",{className:"hidden sm:flex items-center gap-1 ml-4",children:[o.jsx(Z,{href:"/",children:o.jsx(Ie,{variant:"ghost",size:"sm","data-testid":"link-nav-home",children:"Review"})}),o.jsx(Z,{href:"/blog",children:o.jsx(Ie,{variant:"ghost",size:"sm","data-testid":"link-nav-blog",children:"Blog"})}),o.jsx(Z,{href:"/about",children:o.jsx(Ie,{variant:"ghost",size:"sm","data-testid":"link-nav-about",children:"About"})})]}),o.jsx("div",{className:"flex-1"}),o.jsx("a",{href:"https://forexmq5.com",target:"_blank",rel:"noopener noreferrer",children:o.jsxs(Ie,{className:"hidden sm:inline-flex","data-testid":"button-header-cta",children:[o.jsx(za,{className:"mr-2 h-4 w-4"}),"Visit ForexMQ5"]})}),o.jsx("a",{href:"https://forexmq5.com",target:"_blank",rel:"noopener noreferrer",children:o.jsxs(Ie,{size:"sm",className:"sm:hidden","data-testid":"button-header-cta-mobile",children:[o.jsx(za,{className:"mr-2 h-4 w-4"}),"Visit ForexMQ5"]})})]})})}const xE="/assets/hero_ex4_decompiler_workspace-BL2grX2O.png";function kE(){return o.jsxs("section",{className:"relative w-full min-h-[600px] md:min-
147h-[700px] flex items-center justify-center overflow-hidden",children:[o.jsx("img",{src:xE,alt:"EX4 decompiler workspace showing MQ4 source code recovery and decompilation process",className:"absolute inset-0 w-full h-full object-cover object-center",width:"1200",height:"700"}),o.jsx("div",{className:"absolute inset-0 bg-gradient-to-b from-black/70 via-black/60 to-black/70"}),o.jsxs("div",{className:"relative z-10 w-full max-w-4xl mx-auto px-4 sm:px-6 py-12 sm:py-16 md:py-24 text-center",children:[o.jsx("h1",{className:"font-serif text-2xl sm:text-3xl md:text-4xl lg:text-5xl font-bold text-white mb-4 sm:mb-6 leading-tight",children:"EX4 Decompiler Review: Options, Limits, and Validation"}),o.jsx("p",{className:"text-base sm:text-lg md:text-xl text-white/90 mb-6 sm:mb-8 leading-relaxed max-w-3xl mx-auto",children:"An independent review of EX4 to MQ4 recovery options, including service scope, pricing, common limitations, and how to validate recovered source before use."}),o.jsxs("div",{className:"flex flex-col sm:flex-row gap-4 justify-center mb-8",children:[o.jsx("a",{href:"https://forexmq5.com",target:"_blank",rel:"noopener noreferrer",children:o.jsxs(Ie,{size:"lg",className:"bg-primary/90 backdrop-blur-md border border-primary-border text-primary-foreground text-base md:text-lg px-6 sm:px-8 py-3 sm:py-6 w-full","data-testid":"button-visit-service-hero",children:[o.jsx(za,{className:"mr-2 h-5 w-5"}),"Visit ForexMQ5"]})}),o.jsxs(Ie,{size:"lg",variant:"outline",className:"backdrop-blur-md bg-white/10 border-white/30 text-white text-base md:text-lg px-6 sm:px-8 py-3 sm:py-6","data-testid":"button-read-review",onClick:()=>{var e;return(e=document.getElementById("review"))==null?void 0:e.scrollIntoView({behavior:"smooth"})},children:["Read Full Review Below",o.jsx($o,{className:"ml-2 h-5 w-5"})]})]}),o.jsxs("div",{className:"flex flex-wrap items-center justify-center gap-6 text-white/90 text-sm md:text-base",children:[o.jsxs("div",{className:"flex items-center gap-2",children:[o.jsx(Ui,{className:"h-5 w-5 text-green-400"}),o.jsx("span",{children:"Expert Reviewed"})]}),o.jsxs("div",{className:"flex items-center gap-2",children:[o.jsx(Ui,{className:"h-5 w-5 text-green-400"}),o.jsx("span",{children:"Reviewed September 2026"})]})]}),o.jsx("p",{className:"mt-6 text-white/60 text-xs",children:"Last Updated: September 2026"})]})]})}function AE({items:e}){var i;const[t,r]=w.useState(((i=e[0])==null?void 0:i.id)||"");w.useEffect(()=>{const n=new IntersectionObserver(s=>{s.forEach(l=>{l.isIntersecting&&r(l.target.id)})},{rootMargin:"-100px 0px -80% 0px",threshold:0});return e.forEach(s=>{const l=document.getElementById(s.id);l&&n.observe(l)}),()=>n.disconnect()},[e]);const a=n=>{const s=document.getElementById(n);s&&s.scrollIntoView({behavior:"smooth",block:"start"})};return o.jsx("nav",{className:"sticky top-24 hidden lg:block w-64 h-fit",children:o.jsxs("div",{className:"border rounded-lg p-6 bg-card",children:[o.jsx("h3",{className:"font-serif text-lg font-semibold mb-4",children:"Table of Contents"}),o.jsx("ul",{className:"space-y-3",children:e.map(n=>o.jsx("li",{children:o.jsx("button",{onClick:()=>a(n.id),className:`text-left text-sm w-full py-1 px-3 rounded-md transition-colors hover-elevate ${t===n.id?"bg-primary text-primary-foreground font-medium":"text-muted-foreground hover:text-foreground"}`,"data-testid":`toc-link-${n.id}`,children:n.title})},n.id))})]})})}function Be({id:e,title:t,children:r}){return o.jsxs("section",{id:e,className:"scroll-mt-24 mb-12 sm:mb-16",children:[o.jsx("h2",{className:"font-serif text-xl sm:text-2xl md:text-3xl lg:text-4xl font-semibold mb-4 sm:mb-6 text-foreground",children:t}),o.jsx("div",{className:"prose prose-base sm:prose-lg max-w-none leading-relaxed text-foreground space-y-4 sm:space-y-6",children:r})]})}function TE({title:e,videoId:t,caption:r}){return o.jsxs("div",{className:"my-12 max-w-3xl mx-auto",children:[o.jsx("div",{className:"aspect-video w-full rounded-lg overflow-hidden bg-muted border shadow-md",children:t?o.jsx("iframe",{className:"w-full h-full",src:`https://www.youtube.com/embed/${t}`,title:e,allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0,"data-testid":"video-iframe"}):o.jsx("div",{className:"w-full h-full flex items-center justify-center bg-gradient-to-br from-muted to-muted/50",children:o.jsxs("div",{className:"text-center px-6",children:[o.jsx("div",{className:"w-16 h-16 mx-auto mb-4 rounded-full bg-primary/10 flex items-center justify-center",children:o.jsx("svg",{className:"w-8 h-8 text-primary",fill:"currentColor",viewBox:"0 0 24 24",children:o.jsx("path",{d:"M8 5v14l11-7z"})})}),o.jsx("p",{className:"text-sm text-muted-foreground font-medium",children:e})]})})}),r&&o.jsx("p",{className:"text-center text-sm text-muted-foreground mt-4",children:r})]})}function EE({stats:e}){return o.jsx("div",{className:"grid sm:grid-cols-3 gap-6 sm:gap-8 my-8 sm:my-12",children:e.map((t,r)=>o.jsxs("div",{className:"text-center p-4 sm:p-6 rounded-lg bg-card border hover-elevate","data-testid":`stat-${r}`,children:[o.jsx("div",{className:"text-3xl sm:text-4xl md:text-5xl font-bold text-primary mb-2 font-serif",children:t.value}),o.jsx("div",{className:"text-lg font-semibold text-foreground mb-2",children:t.label}),o.jsx("div",{className:"text-sm text-muted-foreground",children:t.description})]},r))})}function ME({rows:e}){return o.jsx("div",{className:"my-8 sm:my-12 -mx-4 sm:mx-0 overflow-x-auto",children:o.jsxs("table",{className:"w-full min-w-[500px] border rounded-lg overflow-hidden",children:[o.jsx("thead",{className:"bg-muted",children:o.jsxs("tr",{children:[o.jsx("th",{className:"text-left p-4 font-serif text-base md:text-lg font-semibold",children:"Feature"}),o.jsx("th",{className:"text-center p-4 font-serif text-base md:text-lg font-semibold text-primary",children:"Top EX4 Decompiler"}),o.jsx("th",{className:"text-center p-4 font-serif text-base md:text-lg font-semibold",children:"Other Tools"})]})}),o.jsx("tbody",{children:e.map((t,r)=>o.jsxs("tr",{className:"border-t hover-elevate","data-testid":`comparison-row-${r}`,children:[o.jsx("td",{className:"p-3 sm:p-4 font-medium text-sm md:text-base",children:t.feature}),o.jsx("td",{className:"p-3 sm:p-4 text-center",children:typeof t.recommended=="boolean"?t.recommended?o.jsx(Vh,{
147className:"h-6 w-6 text-green-500 mx-auto"}):o.jsx(Bl,{className:"h-6 w-6 text-muted mx-auto"}):o.jsx("span",{className:"text-sm md:text-base font-semibold text-primary",children:t.recommended})}),o.jsx("td",{className:"p-3 sm:p-4 text-center",children:typeof t.alternatives=="boolean"?t.alternatives?o.jsx(Vh,{className:"h-6 w-6 text-green-500 mx-auto"}):o.jsx(Bl,{className:"h-6 w-6 text-muted mx-auto"}):o.jsx("span",{className:"text-sm md:text-base text-muted-foreground",children:t.alternatives})})]},r))})]})})}function Os({title:e,description:t,buttonText:r="Visit ForexMQ5"}){return o.jsxs("div",{className:"my-12 sm:my-16 bg-primary/5 border-2 border-primary/20 rounded-lg p-6 sm:p-8 md:p-12 text-center",children:[o.jsx("h3",{className:"font-serif text-2xl md:text-3xl font-semibold mb-4 text-foreground",children:e}),o.jsx("p",{className:"text-base md:text-lg text-muted-foreground mb-6 max-w-2xl mx-auto leading-relaxed",children:t}),o.jsx("a",{href:"https://forexmq5.com",target:"_blank",rel:"noopener noreferrer",children:o.jsxs(Ie,{size:"sm",className:"sm:min-h-10 md:min-h-11 text-sm sm:text-base md:text-lg px-4 sm:px-6 md:px-8","data-testid":"button-cta-section",children:[o.jsx(za,{className:"mr-2 h-4 w-4 sm:h-5 sm:w-5"}),r]})})]})}function jr(){const[t,r]=$f(),a=i=>{var n;t!=="/"?(r("/"),setTimeout(()=>{var s;(s=document.getElementById(i))==null||s.scrollIntoView({behavior:"smooth"})},100)):(n=document.getElementById(i))==null||n.scrollIntoView({behavior:"smooth"})};return o.jsx("footer",{className:"border-t bg-muted/30 mt-24",children:o.jsxs("div",{className:"max-w-7xl mx-auto px-6 py-12",children:[o.jsxs("div",{className:"grid md:grid-cols-3 gap-12 mb-8",children:[o.jsx("div",{children:o.jsx("p",{className:"text-sm text-muted-foreground leading-relaxed",children:"Independent review site for EX4 to MQ4 decompilation services. We test and review professional decompilation services like forexmq5.com to help traders and developers find the best EX4 to MQ4 solution."})}),o.jsxs("div",{children:[o.jsx("h4",{className:"font-serif font-semibold mb-4",children:"Quick Links"}),o.jsxs("ul",{className:"space-y-2 text-sm text-muted-foreground",children:[o.jsx("li",{children:o.jsx("button",{onClick:()=>a("intro"),className:"hover:text-foreground transition-colors text-left","data-testid":"link-footer-intro",children:"What is EX4 Decompilation"})}),o.jsx("li",{children:o.jsx("button",{onClick:()=>a("review"),className:"hover:text-foreground transition-colors text-left","data-testid":"link-footer-review",children:"Best EX4 to MQ4 Decompiler Review"})}),o.jsx("li",{children:o.jsx("button",{onClick:()=>a("how-it-works"),className:"hover:text-foreground transition-colors text-left","data-testid":"link-footer-how",children:"How EX4 to MQ4 Works"})}),o.jsx("li",{children:o.jsx(Z,{href:"/blog",className:"hover:text-foreground transition-colors","data-testid":"link-footer-blog",children:"Blog"})})]})]}),o.jsxs("div",{children:[o.jsx("h4",{className:"font-serif font-semibold mb-4",children:"Legal"}),o.jsxs("ul",{className:"space-y-2 text-sm text-muted-foreground",children:[o.jsx("li",{children:o.jsx(Z,{href:"/privacy-policy",className:"hover:text-foreground transition-colors","data-testid":"link-privacy-policy",children:"Privacy Policy"})}),o.jsx("li",{children:o.jsx(Z,{href:"/terms-of-service",className:"hover:text-foreground transition-colors","data-testid":"link-terms-of-service",children:"Terms of Service"})}),o.jsx("li",{children:o.jsx(Z,{href:"/disclaimer",className:"hover:text-foreground transition-colors","data-testid":"link-disclaimer",children:"Disclaimer"})}),o.jsx("li",{children:o.jsx(Z,{href:"/contact",className:"hover:text-foreground transition-colors","data-testid":"link-contact",children:"Contact"})})]})]})]}),o.jsx("div",{className:"pt-8 border-t text-center text-sm text-muted-foreground",children:o.jsxs("p",{children:["© ",2026," forexdec. All rights reserved."]})})]})})}const xr=w.forwardRef(({className:e,...t},r)=>o.jsx("div",{ref:r,className:De("shadcn-card rounded-xl border bg-card border-card-border text-card-foreground shadow-sm",e),...t}));
147xr.displayName="Card";const SE=w.forwardRef(({className:e,...t},r)=>o.jsx("div",{ref:r,className:De("flex flex-col space-y-1.5 p-6",e),...t}));SE.displayName="CardHeader";const CE=w.forwardRef(({className:e,...t},r)=>o.jsx("div",{ref:r,className:De("text-2xl font-semibold leading-none tracking-tight",e),...t}));CE.displayName="CardTitle";const IE=w.forwardRef(({className:e,...t},r)=>o.jsx("div",{ref:r,className:De("text-sm text-muted-foreground",e),...t}));IE.displayName="CardDescription";const $i=w.forwardRef(({className:e,...t},r)=>o.jsx("div",{ref:r,className:De("p-6 pt-0",e),...t}));$i.displayName="CardContent";const RE=w.forwardRef(({className:e,...t},r)=>o.jsx("div",{ref:r,className:De("flex items-center p-6 pt-0",e),...t}));RE.displayName="CardFooter";const jE=ec("whitespace-nowrap inline-flex items-center rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 hover-elevate ",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground shadow-xs",secondary:"border-transparent bg-secondary text-secondary-foreground",destructive:"border-transparent bg-destructive text-destructive-foreground shadow-xs",outline:" border [border-color:var(--badge-outline)] shadow-xs"}},defaultVariants:{variant:"default"}});function Lr({className:e,variant:t,...r}){return o.jsx("div",{className:De(jE({variant:t}),e),...r})}const Cv="/assets/1_3vG0NvvWrJNjxElC-Wkfww_1771098201329-DRrYZtpd.jpg";function qE(){return o.jsx(xr,{className:"my-8 border-primary/20",children:o.jsx($i,{className:"p-6",children:o.jsxs("div",{className:"flex flex-col sm:flex-row gap-6",children:[o.jsx("div",{className:"flex-shrink-0 flex justify-center sm:justify-start",children:o.jsx("img",{src:Cv,alt:"Alex M - MQL4 Development Expert",className:"w-20 h-20 rounded-full object-cover border-2 border-primary/20"})}),o.jsxs("div",{className:"flex-1",children:[o.jsxs("div",{className:"flex flex-wrap items-center gap-2 mb-2",children:[o.jsx("h3",{className:"text-lg font-semibold",children:"Alex M"}),o.jsxs(Lr,{variant:"secondary",className:"text-xs",children:[o.jsx(Ui,{className:"w-3 h-3 mr-1"}),"Verified Expert"]})]}),o.jsx("p",{className:"text-sm text-muted-foreground mb-3",children:"MQL4 & MQL5 Expert Advisor Developer"}),o.jsx("p",{className:"text-sm leading-relaxed mb-4",children:"Alex M has over 10 years of experience developing Expert Advisors, custom indicators, and scripts for MetaTrader 4 and MetaTrader 5. She has built hundreds of EAs for traders worldwide, from simple moving average crossover systems to complex multi-pair grid and martingale strategies. Her deep understanding of MQL4 internals and EA architecture makes her reviews of decompiler tools uniquely practical and informed."}),o.jsx("div",{className:"flex flex-wrap gap-2",children:o.jsx(Lr,{variant:"outline",className:"text-xs",children:"10+ Years MQL4 EA Developer"})})]})]})})})}const du="/assets/blog_mt4-set-file-recovery-and-validation-DmVB8v9H.png",cu="/assets/blog_mt4-ea-dll-dependency-audit-C2S0j6DF.png",hu="/assets/blog_mt4-magic-number-conflict-guide-DDhZHnx_.png",uu="/assets/blog_mt4-broker-server-time-ea-schedule-D9Kv3ejv.png",pu="/assets/blog_mt4-four-digit-five-digit-broker-ea-SdC-b6u0.png",mu="/assets/blog_mt4-ea-spread-slippage-risk-review-BbQ0eBtq.png",fu="/assets/blog_detect-martingale-grid-logic-mql4-r2zUJYKm.png",gu="/assets/blog_mt4-ea-news-filter-troubleshooting-D88YMbjT.png",vu="/assets/blog_mt4-ea-account-lock-license-checks-C16O3Azx.png",yu="/assets/blog_expert-advisor-source-code-contract-clauses-CjzVgBqH.png",bu="/assets/blog_mt4-strategy-tester-model-quality-guide-BcPRBFAx.png",wu="/assets/blog_forward-test-recovered-mql4-ea-Bnk1QhBv.png",xu="/assets/blog_fix-mql4-compiler-warnings-recovered-code-DgV4CgI_.png",ku="/assets/blog_refactor-recovered-mql4-code-safely-VeiUbFkC.png",Au="/assets/blog_document-mt4-ea-input-parameters-K_k3fI6o.png",Tu="/assets/blog_verify-ex4-file-integrity-hash-D4znI7t7.png",Eu="/assets/blog_mt4-ea-malware-security-review-BAUnXW05.png",Mu="/assets/blog_mt4-vps-logs-ea-diagnostics-CyoUNZJM.png",Su="/assets/blog_mql4-indicator-buffer-debugging-guide-BpmkB903.png",Cu="/assets/blog_mt4-multi-timeframe-indicator-validation-CuHGcM9A.png",Iu="/assets/blog_mt4-ea-dependency-inventory-checklist-xIwjtuj7.png",Ru="/assets/blog_mql4-source-code-escrow-guide-Bujmeye5.png",ju="/assets/blog_expert-advisor-business-continuity-plan-CMIPrdzf.png",qu="/assets/blog_ex4-recovery-service-quote-checklist-BBAU2CIQ.png",Pu="/assets/blog_ex4-source-recovery-confidentiality-checklist-DdGb5n4X.png",Fs="/assets/blog_recovered-mql4-code-acceptance-checklist-CS0eMT3p.png",Du="/assets/blog_mql4-event-handlers-explained-u0PblRvG.png",Lu="/assets/blog_mql4-order-management-risk-controls-BqeyRQZY.png",PE=[{slug:"mt4-ea-release-checklist-version-control-testing-rollback",title:"MT4 EA Release Checklist: Version Control, Testing, and Rollback",metaTitle:"MT4 EA Release Checklist: Version Control, Testing, Rollback",metaDescription:"A practical release process for MT4 Expert Advisors: identify source and EX4 versions, record settings and dependencies, test changes, and keep a rollback copy.",keywords:"MT4 EA release checklist, MQL4 version control, Expert Advisor deployment, MT4 rollback plan, EA release management",excerpt:"Keep each MT4 EA release traceable by tying the MQ4, compiled EX4, settings, dependencies, build details, and test evidence to one version. This checklist covers review, staging, and rollback.",date:"September 24, 2026",dateISO:"2026-09-24",lastModified:"September 24, 2026",lastModifiedISO:"2026-09-24",readTime:"10 min read",featuredImage:Fs,imageAlt:"Checklist for validating and releasing an Expert Advisor with documented settings and s
147ource files",tableOfContents:[{id:"release-unit",title:"Define What Counts as One Release"},{id:"source-of-truth",title:"Keep a Single Source of Truth"},{id:"identify-version",title:"Identify the Exact Version"},{id:"preserve-baseline",title:"Preserve the Known-Good Baseline"},{id:"build-record",title:"Record the Build Environment"},{id:"test-plan",title:"Test the Change Against a Baseline"},{id:"stage-release",title:"Stage the Release Carefully"},{id:"rollback-plan",title:"Prepare a Real Rollback Plan"},{id:"release-record",title:"Complete the Release Record"},{id:"conclusion",title:"Make Every Release Reproducible"}],content:`
148<p>An Expert Advisor release is more than a new EX4 file copied into the MT4 data folder. A change can alter entry timing, order size, stop handling, broker compatibility, or the way the program reads its settings. If the MQ4, compiled binary, preset, and test results are not tied together, it becomes difficult to tell which version produced an observed result or how to restore the previous behavior.</p>
149
150<p>This checklist is for EA owners and maintainers who have authority to update a system they own or are licensed to maintain. It describes a controlled software release, not a promise of trading performance. A release should be considered ready only when the exact files are identifiable, the intended change is clear, the relevant tests have been recorded, and a known-good version can be restored.</p>
151
152<h2 id="release-unit">Define What Counts as One Release</h2>
153
154<p>Start by treating the release as a package rather than a single executable. Depending on the EA, the package may include MQ4 source, the compiled EX4, one or more SET files, custom indicators, include files, DLLs, configuration files, installation notes, and a test report. Not every component changes each time, but the release record should identify which versions were used.</p>
155
156<p>Draw a boundary around the change. For example, “correct symbol suffix handling” is testable. “Improve the EA” is not. Record the request, the reason, the expected behavior, and the areas that should not change. If recovered code is part of the project, distinguish the untouched recovery deliverable from the working source that is subsequently edited. The guide to <a href="/blog/recover-lost-mq4-expert-advisor-source-code">recovering lost MQ4 source</a> explains why keeping those copies separate matters.</p>
157
158<h2 id="source-of-truth">Keep a Single Source of Truth</h2>
159
160<p>Choose one private, access-controlled location as the authoritative source repository. Avoid editing whichever copy happens to be open in MetaEditor while separate copies live on a VPS, shared drive, email attachment, and laptop. Multiple active “final” files make it easy to compile one version and deploy another.</p>
161
162<p>Use version control for source and text configuration where practical. Keep binary releases and large test evidence in an appropriate controlled archive, and link them to the source revision that produced them. Do not put account passwords, API tokens, personal account data, or private license credentials in a repository or release note. Use a secure secrets store for sensitive values and document only where authorized operators obtain them.</p>
163
164<p>For projects without a repository, establish a simple folder structure and make release folders immutable after approval. Give working copies clear names such as <code>working</code>, <code>candidate</code>, and <code>released</code>; avoid ambiguous names such as <code>final-new-latest2</code>.</p>
165
166<h2 id="identify-version">Identify the Exact Version</h2>
167
168<p>Assign each release a unique identifier, such as a date plus an increment or a source-control tag. Put that identifier in a release note and, where appropriate, in the EA's visible version property. Do not rely on the file modification time alone: copying a file can change its timestamp, and two different builds may share the same visible product name.</p>
169
170<p>Record a checksum for the released EX4 and any critical companion file when you need to confirm that a copy has not changed. A hash can show that two files are identical or different; it cannot tell you whether a program is safe or correct. See the guide to <a href="/blog/verify-ex4-file-integrity-hash">verifying EX4 file integrity with hashes</a> for the distinction between identity and behavior.</p>
171
172<h2 id="preserve-baseline">Preserve the Known-Good Baseline</h2>
173
174<p>Before changing code or settings, archive the current source, EX4, preset, dependency list, and available logs. Capture the terminal build, broker server, symbol spelling, timeframe, account type (demo or live), and relevant EA inputs. Redact credentials and account identifiers before sharing evidence outside the authorized team.</p>
175
176<p>Keep a known-good copy outside the live terminal directory. Do not overwrite the deployed EX4 as the only backup. The baseline is the comparison point for regression tests and the source of a rollback if the candidate fails. If the system has no known-good version, say so in the release record; do not describe an untested file as a rollback option.</p>
177
178<h2 id="build-record">Record the Build Environment</h2>
179
180<p>Compile the candidate with a recorded MetaEditor and terminal build. Retain the compiler output, including warnings, and list the required include files, custom indicators, libraries, or DLLs. A compile that succeeds on one developer's machine may fail elsewhere if a dependency or compiler setting is missing.</p>
181
182<p>Do not silently bundle a different dependency version. Record the exact filename and version where available, and confirm that the project has permission to use and distribute it. If a DLL or external service is involved, document its purpose and the conditions under which it is enabled. A dependency inventory can help surface missing pieces before a release moves to a new terminal or VPS.</p>
183
184<h2 id="test-plan">Test the Change Against a Baseline</h2>
185
186<p>Write tests around the requested change and the behavior most likely to be affected. Use the same settings and comparable market data for the previous and candidate builds when possible. Record what was tested, what result was expected, what actually happened, and any differences that remain unexplained.</p>
187
188<ul>
189  <li><strong>Compile check:</strong> note the compiler build, errors, warnings, and dependencies.</li>
190  <li><strong>Initialization check:</strong> confirm the EA loads on the intended symbol and reports expected status in Experts and Journal logs.</li>
191  <li><strong>Behavior check:</strong> exercise the changed path and compare orders, stops, sizing, and timing with the baseline where a reliable reference exists.</li>
192  <li><strong>Boundary check:</strong> test relevant limits such as spread, session time, missing data, broker symbol suffix, or rejected trade requests.</li>
193  <li><strong>Regression check:</strong> verify important behavior outside the requested change has not unex
193pectedly shifted.</li>
194</ul>
195
196<p>Backtests depend on data, modeling assumptions, spread, commission, and execution conditions. Record those inputs and do not interpret a matching backtest as proof of future performance. A demo forward test can expose runtime and broker differences, but it also cannot guarantee live results. The detailed guide to <a href="/blog/forward-test-recovered-mql4-ea">forward testing recovered MQL4</a> covers a controlled observation process.</p>
197
198<h2 id="stage-release">Stage the Release Carefully</h2>
199
200<p>Install the candidate in an isolated test terminal or demo environment first. Use the intended SET file and dependencies, and confirm the correct EX4 is loaded after a terminal restart. Check the Experts and Journal tabs for initialization failures, repeated order attempts, missing files, and other unexpected messages.</p>
201
202<p>For a change that affects risk or order management, have an authorized reviewer examine the test record before deployment. Keep the deployment window, responsible operator, affected accounts or terminals, and planned observation period in the release note. Deploy to one controlled environment before expanding to other terminals, if the operating setup allows a staged rollout.</p>
203
204<h2 id="rollback-plan">Prepare a Real Rollback Plan</h2>
205
206<p>A rollback plan names the exact previous EX4, settings, dependencies, and steps needed to restore them. Confirm that the files are available and readable before release day. State who can authorize a rollback and what observations trigger one, such as repeated initialization errors, a change in order sizing, missing protective behavior, or divergence from the expected test path.</p>
207
208<p>Restoring the old binary may not be enough if settings or companion files also changed. Keep those related versions together and document any state that persists outside the program, such as terminal global variables, external data files, or account-side orders. Never assume that replacing a file automatically reverses orders already placed or settings already changed.</p>
209
210<h2 id="release-record">Complete the Release Record</h2>
211
212<p>Keep the release record short enough that people will maintain it. A useful entry includes:</p>
213
214<ul>
215  <li>Release identifier, date, owner, and reviewer.</li>
216  <li>Purpose of the change and the source revision.</li>
217  <li>MQ4, EX4, SET, and dependency versions or hashes.</li>
218  <li>Compiler and terminal build used.</li>
219  <li>Tests performed, observed results, and open issues.</li>
220  <li>Deployment target, approval, and rollback file locations.</li>
221</ul>
222
223<p>Mark unknowns as unknown. If a behavior could not be reproduced because a service, license, data feed, or dependency was unavailable, write that down. A precise limitation is more useful to the next maintainer than a vague statement that the release was “fully tested.”</p>
224
225<h2 id="conclusion">Make Every Release Reproducible</h2>
226
227<p>A dependable MT4 release process keeps the source, compiled binary, settings, dependencies, and test evidence connected. It preserves the last known-good version, makes the new change explicit, checks the relevant behavior in a controlled environment, and provides a practical way to restore the prior files.</p>
228
229<p>Use this process for changes that matter to your system, scale the checks to the risk, and keep permissions clear. The aim is not paperwork for its own sake. It is being able to answer, later and with evidence: what changed, which file ran, what was tested, and how to return to the previous state.</p>
230    `},{slug:"mt4-set-file-recovery-and-validation",title:"Recovering and Validating MT4 SET Files After an EA Migration",metaTitle:"Recover and Validate MT4 SET Files After EA Migration | 2026",metaDescription:"Learn how to locate, recover, map, and validate MT4 SET files after an EA migration. Use a structured parameter review before testing or live deployment.",keywords:"MT4 SET file recovery, validate MT4 EA settings, Expert Advisor migration, MT4 input parameters, restore EA presets, MetaTrader SET file",excerpt:"A recovered EA is only part of an MT4 migration. This practical guide shows how to find SET backups, compare parameter labels, rebuild a controlled preset, and validate every setting before relying on it.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:du,imageAlt:"organized MT4 Expert Advisor settings file with parameter sliders, backup folder, and green validation checks",tableOfContents:[{id:"why-set-files-matter",title:"Why SET Files Matter After a Migration"},{id:"protect-the-evidence",title:"Protect the Original Files First"},{id:"find-backups",title:"Find SET Files and Related Backups"},{id:"read-the-file",title:"Read What a SET File Can and Cannot Preserve"},{id:"match-inputs",title:"Match Old Settings to the Current EA Inputs"},{id:"rebuild-preset",title:"Rebuild a Controlled Working Preset"},{id:"validate-settings",title:"Validate Settings With Green Checks"},{id:"test-without-assumptions",title:"Test Without Assuming Old Results Return"},{id:"migration-decisions",title:"Decision Steps for Common Migration Problems"},{id:"handover",title:"Document the Final Configuration"},{id:"conclusion",title:"Conclusion"}],content:`
231<p>An Expert Advisor migration can look complete when the EX4 loads in a new MT4 terminal, but that is only the softw
231are half of the job. The settings that made the EA behave a particular way may be stored separately in a SET file, remembered only in screenshots, or scattered across backups. A robot with the correct filename and the wrong inputs is not a restored configuration. It is an unfamiliar configuration wearing a familiar label.</p>
232
233<p>SET files deserve careful treatment because they turn rows of input fields and parameter sliders into a repeatable preset. They may hold a lot size, a session window, an identifier, symbol rules, filters, and risk limits. They can also hold values that are no longer meaningful after a broker change, an EA update, a code recovery, or a platform move. Recovering the file is useful. Trusting it without validation is not.</p>
234
235<img src="${du}" alt="organized MT4 Expert Advisor settings file with parameter sliders, backup folder, and green validation checks" style="width:100%;border-radius:8px;margin:24px 0;" />
236
237<p>This guide takes an evidence based approach to recovering and checking an MT4 preset after an EA migration. It is written for users who have a legitimate right to use and maintain the EA. It does not promise that an old preset will reproduce prior trading results, and it should not be treated as financial advice. The aim is narrower and more practical: establish which values came from where, determine whether the current EA understands them, and create a documented configuration that can be tested safely.</p>
238
239<p>For readers still sorting the executable and source side of a project, this site also explains <a href="/blog/recover-lost-mq4-expert-advisor-source-code">how lost MQ4 source recovery differs from a simple file copy</a>. A SET file is not source code. It is a configuration record, and its value depends on the exact EA version that reads it.</p>
240
241<h2 id="why-set-files-matter">Why SET Files Matter After a Migration</h2>
242
243<p>In MT4, an EA exposes inputs through its Properties window. A user can enter a number, choose a true or false option, type text, or select from a list. The platform can save those current inputs as a SET file and load them later. This is convenient for a single terminal, but it becomes essential when an EA moves between computers, brokers, installations, or versions.</p>
244
245<p>The visible chart is not a reliable record of the configuration. A chart may show the symbol and timeframe, yet omit important choices such as whether new entries are enabled, which magic number identifies orders, or how the EA interprets a suffix. The Journal may show that the EA initialized, but it does not prove every intended input was loaded. A screenshot can be helpful, but it often cuts off lower fields and does not preserve the exact text of a parameter.</p>
246
247<p>There are three reasons to treat the preset as a distinct migration artifact:</p>
248
249<ol>
250  <li><strong>Repeatability.</strong> A named preset gives the operator one source of truth rather than relying on memory or manual slider changes.</li>
251  <li><strong>Traceability.</strong> It can be compared with a backup, a vendor instruction, an old terminal, or a later revised preset.</li>
252  <li><strong>Risk control.</strong> It makes it easier to spot a default value that silently replaced an intended limit during installation.</li>
253</ol>
254
255<p>None of this means a SET file is self authenticating. It is plain configuration data, not a certificate that the attached EA is the right version, that the broker environment matches, or that the setup is appropriate for a live account. The file must be read in context.</p>
256
257<h2 id="protect-the-evidence">Protect the Original Files First</h2>
258
259<p>Before opening, importing, or editing anything, make a small migration evidence folder outside the active MT4 data folder. Copy the original SET files, the original EA file, any old screenshots, relevant logs, and notes about the prior terminal. Give the folder a date and a clear purpose, such as “EURUSD EA migration evidence.” Work on copies. This avoids the common mistake of overwriting the only file that records a previous configuration.</p>
260
261<p>A useful inventory has more value than a complicated folder structure. The following table provides a practical minimum.</p>
262
263<table>
264  <thead><tr><th>
264Item</th><th>What to record</th><th>Why it matters</th></tr></thead>
265  <tbody>
266    <tr><td>EA file</td><td>Filename, location, date, file size, known version</td><td>Input names can change between EA builds.</td></tr>
267    <tr><td>SET file</td><td>Original filename, copy location, date found</td><td>Preserves the starting point and its provenance.</td></tr>
268    <tr><td>Terminal context</td><td>Broker, account type, symbol spelling, timeframe</td><td>Some values depend on the operating environment.</td></tr>
269    <tr><td>Supporting evidence</td><td>Screenshots, instructions, old chart template, notes</td><td>Helps resolve unclear labels or missing fields.</td></tr>
270    <tr><td>Validation record</td><td>Reviewer, date, test result, unresolved questions</td><td>Creates a repeatable handover rather than a guess.</td></tr>
271  </tbody>
272</table>
273
274<p>Do not rename original files to make them look cleaner. Copy them, then use descriptive names for working versions. For example, “Original_GridEA_EURUSD.set” can remain untouched while “Working_GridEA_EURUSD_v2_checked.set” is edited. A date alone is not always enough because system copy dates can change during transfer.</p>
275
276<p>If the EA itself was recovered or rebuilt, keep that fact prominent. A recovered MQ4 compiled today may expose parameters in a different order, use revised defaults, or require manual reconstruction of a dependency. The broader <a href="/">ex4 to mq4 decompiler</a> topic concerns code recovery, while SET validation concerns the much narrower question of whether this particular configuration still maps to this particular program.</p>
277
278<h2 id="find-backups">Find SET Files and Related Backups</h2>
279
280<p>The first recovery task is a disciplined search, not a rushed import. In MT4, use File, Open Data Folder to identify the active terminal location rather than assuming every installation uses the same Windows path. Then examine the terminal’s Experts or Tester areas as applicable, plus folders copied from old computers. A SET file may be beside other strategy tester presets, in a manually created backup folder, attached to a project archive, or saved under a name that does not match the EA.</p>
281
282<p>Search for the .set extension across backup drives, cloud sync folders, downloaded archives, desktop exports, and prior terminal data folders. Also search for likely EA names, magic numbers, symbol names, or the word “preset.” A user who named files by account, month, or broker may find “ICM_15m_2024.set” long before finding the EA name. Preserve archive paths in the inventory because the path can explain which setup a file belonged to.</p>
283
284<h3>Use surrounding artifacts as clues</h3>
285
286<p>A SET file by itself may be ambiguous. Its neighbors can supply context. A chart template can identify the intended symbol and timeframe. A text note may define a session in broker server time. A report can reveal the magic number used for historic orders. An old screenshot may show which checkboxes were enabled. None of these artifacts should be used to invent an absent value, but together they can help label an otherwise generic preset.</p>
287
288<p>Be especially cautious with copied terminal folders. A cloud synchronization conflict can leave several files with similar names, and the newest modified date may represent a transfer rather than a configuration change. Instead of selecting the newest file automatically, compare candidate files side by side and record why one was selected for validation.</p>
289
290<h3>Search checklist</h3>
291
292<ul>
293  <li>Open the active MT4 data folder and note its full path.</li>
294  <li>Copy every candidate SET file before loading any of them.</li>
295  <li>Search old terminal folders, archives, removable media, and cloud backups for .set files.</li>
296  <li>Collect chart templates and screenshots that appear to belong to the same EA.</li>
297  <li>Record the broker, symbol spelling, timeframe, and account context for each candidate.</li>
298  <li>Mark unknown files as unknown instead of assigning them to an EA by guesswork.</li>
299</ul>
300
301<h2 id="read-the-file">Read What a SET File Can and Cannot Preserve</h2>
302
303<p>A SET file generally stores input names and values in a text oriented format. That makes it possible to inspect a copy in a suitable text editor, but editing should be deliberate. The format can include additional fields used for optimization ranges, and an input can look understandable while still being obsolete for the present EA. The definitive check is whether the current EA loads the value into a matching input and behaves as expected in a controlled test.</p>
304
305<p>Think of each setting as belonging to one of four groups. This classification is more useful than treating every numeric field as equally important.</p>
306
307<table>
308  <thead><tr><th>
308Group</th><th>Examples</th><th>Validation focus</th></tr></thead>
309  <tbody>
310    <tr><td>Identity</td><td>Magic number, order comment, instance label</td><td>Confirm it will not collide with another EA or manual order.</td></tr>
311    <tr><td>Market context</td><td>Symbol filter, suffix, timeframe, session hours</td><td>Check the new broker and server time assumptions.</td></tr>
312    <tr><td>Execution and safety</td><td>Lot rule, maximum spread, stop settings, trade limit</td><td>Review every value manually before any live use.</td></tr>
313    <tr><td>Strategy behavior</td><td>Indicator periods, entry filters, spacing, exit rule</td><td>Confirm the current EA defines the same meaning.</td></tr>
314  </tbody>
315</table>
316
317<p>A parameter name is not always a full explanation. “Risk” could mean percentage of balance, a lot multiplier, a fixed amount, or an internal scoring threshold. “StartHour” might be local computer time, broker server time, or GMT. The settings file cannot settle that ambiguity alone. Look for vendor documentation, comments in authorized source, an input description, or a controlled test observation. Where meaning remains unknown, label the setting unresolved and do not turn a plausible interpretation into a fact.</p>
318
319<p>Likewise, a zero can mean disabled, unlimited, automatic, or an actual zero value. A true or false option can reverse its safety meaning depending on the label. Read labels in full and write down the intended interpretation before moving the corresponding slider or field.</p>
320
321<h2 id="match-inputs">Match Old Settings to the Current EA Inputs</h2>
322
323<p>Load a copy of the candidate preset onto a noncritical chart with the current EA attached. Open the Inputs tab and compare the displayed values with the original file. Do not click OK simply because the platform accepted the import. MT4 may ignore unknown keys without delivering a prominent explanation, and a renamed input can leave the new default in place.</p>
324
325<p>Create a mapping sheet with one row per meaningful parameter. This can be a spreadsheet or a simple document. The act of mapping is what turns recovery into validation.</p>
326
327<table>
328  <thead><tr><th>Old parameter</th><th>Old value</th><th>Current input</th><th>Status</th><th>Reviewer note</th></tr></thead>
329  <tbody>
330    <tr><td>MagicNumber</td><td>42015</td><td>MagicNumber</td><td>Match</td><td>Unique in the destination account.</td></tr>
331    <tr><td>TradeStart</td><td>08:00</td><td>SessionStart</td><td>Needs confirmation</td><td>Confirm time basis before use.</td></tr>
332    <tr><td>MaxSpread</td><td>25</td><td>MaximumSpreadPoints</td><td>Match with unit check</td><td>Verify points versus pips.</td></tr>
333    <tr><td>UseNewsFilter</td><td>true</td><td>No visible equivalent</td><td>Unresolved</td><td>Do not assume the function still exists.</td></tr>
334  </tbody>
335</table>
336
337<p>Use clear status labels: Match, Renamed, Unit check, Removed, New default, and Unresolved. “Renamed” requires evidence that the new field has the same meaning. “Unit check” is crucial for points, pips, digits, lots, percentages, and minutes. “New default” should be reviewed rather than accepted. “Removed” can be harmless, but it can also mean the new EA no longer has a safeguard or a strategy component.</p>
338
339<p>One practical example is a five digit broker migration. An old limit labeled “MaxSpread=25” might have meant 2.5 pips if the EA measures points, but an EA that uses pips would interpret 25 very differently. The number has not changed. Its operational meaning may have. This is why a copied preset cannot substitute for an input level review.</p>
340
341<h2 id="rebuild-preset">Rebuild a Controlled Working Preset</h2>
342
343<p>After mapping, build a clean working preset from the Inputs tab rather than repeatedly loading and altering the original candidate. Start with the values that are confirmed. Then add renamed values only after their meaning has been checked. Leave unresolved fields at a documented temporary value, preferably one that avoids unintended new entries during testing if the EA provides such a mode. Never hide uncertainty by silently choosing what feels typical.</p>
344
345<p>A useful naming convention contains the EA name, market context, timeframe, version, and validation state. For example, “RangeEA_EURUSD_M15_v3_reviewed.set” says far more than “new.set.” Avoid names like “final” unless there is a defined change process, because a supposedly final preset often needs a later update.</p>
346
347<h3>Preset rebuilding checklist</h3>
348
349<ol>
350  <li>Attach the verified EA file to a test chart with the intended symbol and timeframe.</li>
351  <li>Enter all confirmed identity and environment values first.</li>
352  <li>Review execution and safety fields one at a time, including their units.</li>
353  <li>Map strategy fields only where documentation or testing supports equivalence.</li>
354  <li>Record every default that differs from the old file and why it was retained or changed.</li>
355  <li>Save the result under a new, descriptive filename.</li>
356  <li>Reload the saved working preset and confirm the visible inputs did not change.</li>
357</ol>
358
359<p>This process is intentionally slower than dragging parameter sliders until a chart looks familiar. It produces a configuration another person can review. It also makes later troubleshooting possible because the team can distinguish a code issue from a preset issue.</p>
360
361<h2 id="validate-settings">Validate Settings With Green Checks</h2>
362
363<p>A useful validation record is a set of explicit green checks, not a vague statement that “the EA loaded.” Each check should have an observable condition. The following checklist can be copied into a migration record.</p>
364
365<table>
366  <thead><tr><th>
366Green check</th><th>What to verify</th><th>Evidence to keep</th></tr></thead>
367  <tbody>
368    <tr><td>File check</td><td>The working SET reloads and displays the intended values.</td><td>Saved preset and dated screenshot of Inputs tab.</td></tr>
369    <tr><td>EA check</td><td>The EA name and known version match the mapping sheet.</td><td>File details or documented version note.</td></tr>
370    <tr><td>Chart check</td><td>Symbol and timeframe match the intended operating context.</td><td>Chart screenshot or setup record.</td></tr>
371    <tr><td>Identity check</td><td>Magic number and comment do not conflict with existing automation.</td><td>Account order review.</td></tr>
372    <tr><td>Unit check</td><td>Spread, distance, volume, and time settings use the expected units.</td><td>Input notes and controlled test output.</td></tr>
373    <tr><td>Safety check</td><td>Limits and permissions reflect the approved test stage.</td><td>Signed or dated checklist.</td></tr>
374  </tbody>
375</table>
376
377<p>There should also be a red flag list. Stop and investigate if the EA reports invalid inputs, fails to initialize, identifies a different symbol than expected, opens a trade during a no trade test, or cannot explain a critical setting. A green smiley or initialization message is not enough on its own. It says the program attached, not that the preset is correct.</p>
378
379<p>Configuration validation is closely related to code validation, but the two are not interchangeable. The site’s guide to <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating a recovered MQL4 EA before live deployment</a> covers the wider review sequence. The SET work described here supplies a controlled input baseline for that wider sequence.</p>
380
381<h2 id="test-without-assumptions">Test Without Assuming Old Results Return</h2>
382
383<p>Once the preset passes its input checks, test it in an environment that fits the project. A strategy tester run can reveal whether inputs load, code branches execute, and obvious errors occur. A demo or isolated observation setup can expose execution differences that a historical test cannot. Neither process guarantees future performance. Market data, spread, slippage, server time, symbol specifications, and the EA version may all differ from the old environment.</p>
384
385<p>Use tests to answer concrete questions rather than to chase a familiar equity curve. Does the session filter open and close at the expected server time? Does a symbol suffix prevent the EA from recognizing the chart? Does the maximum spread block work in the current quote format? Does the magic number appear as intended? Does a deliberately disabled entry setting actually prevent new orders? These observations validate configuration behavior without claiming that a historical result will recur.</p>
386
387<p>Keep one change per test where practical. If the EA is moved to a new broker, a new symbol spelling, and a revised preset all at once, a difference in behavior cannot be attributed confidently. Record the test dates, model assumptions, data source where relevant, and changes made. A result that is not reproducible is weak evidence for a migration decision.</p>
388
389<h2 id="migration-decisions">Decision Steps for Common Migration Problems</h2>
390
391<p>Migration uncertainty is easier to manage with simple decision rules. The following sequence avoids treating every mismatch as a reason to guess.</p>
392
393<ol>
394  <li><strong>Does the old parameter appear in the current Inputs list?</strong> If yes, compare value and units. If no, continue to the next question.</li>
395  <li><strong>Is there written documentation or authorized source evidence for a renamed equivalent?</strong> If yes, record the evidence and test the mapping. If no, mark the field unresolved.</li>
396  <li><strong>Is the field critical to order identity, trade permission, volume, spread, loss control, or schedule?</strong> If yes, do not approve the preset until the meaning is resolved.</li>
397  <li><strong>Can the current EA be tested with new entries disabled or in a controlled environment?</strong> If yes, verify behavior there. If no, seek qualified technical review before relying on the configuration.</li>
398  <li><strong>Did the broker or symbol context change?</strong> If yes, retest symbol, digits, spread, session, and volume assumptions even when the parameter names match.</li>
399</ol>
400
401<p>Some problems cannot be solved from a SET file. If a new EA build removed a filter, changed its calculation, or handles symbols differently, an old value cannot restore the old logic. If source recovery is part of the migration, an independent review of the service at ForexMQ5 may be relevant for users with documented rights and a legitimate maintenance purpose. This review site does not provide recovery services, and configuration evidence should be kept separate from any request.</p>
402
403<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
404  <h3 style="margin-top:0;">Review a Professional Recovery Option</h3>
405  <p>
405Users with a documented right to recover an EA can review the specialist service at ForexMQ5 before deciding on a technical route. A SET file inventory can help define the maintenance scope.</p>
406  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
407</div>
408
409<h2 id="handover">Document the Final Configuration</h2>
410
411<p>A successful migration ends with a handover package, not just a SET file left on one computer. Store the approved working preset, the original candidate, the mapping sheet, test notes, and a short setup instruction together. Include the intended EA version, symbol, timeframe, account context, and any unresolved limitations. If a colleague must reproduce the setup later, they should not need to infer whether “v3” was a broker change, a risk change, or a repaired file.</p>
412
413<p>Use a change log for every later edit. Each entry can be brief: date, editor, field changed, old value, new value, reason, and validation performed. This protects against configuration drift, where several small slider adjustments accumulate until nobody can explain the live preset. It also makes rollback possible when a change proves unsuitable in a test.</p>
414
415<p>Access control matters too. A SET file can reveal operational preferences even though it is not the EA source. Keep it with the same sensible care used for account specific project material. Do not publish an account preset merely because it is text readable, and do not distribute it to people who have no operational need.</p>
416
417<h2 id="conclusion">Conclusion</h2>
418
419<p>Recovering an MT4 SET file after an EA migration is not a clerical afterthought. It is a structured comparison between an old configuration record and the EA, broker, chart, and account context that exist now. The reliable path is to preserve originals, locate every candidate backup, classify settings by importance, map old labels to current inputs, rebuild a clean preset, and earn each green validation check with evidence.</p>
420
421<p>The process does not promise that an older setup will produce the same trading outcome. It does provide something more defensible: a clear account of what was loaded, what was changed, what remains unknown, and what was actually tested. Users researching the technical recovery stage can start with the site’s <a href="/">ex4 decompiler</a> review resources, then keep configuration validation as its own documented discipline.</p>
422`},{slug:"mt4-ea-dll-dependency-audit",title:"MT4 EA DLL Dependency Audit: Find Missing Libraries Before Trading",metaTitle:"MT4 EA DLL Dependency Audit: Find Missing Libraries Before Trading",metaDescription:"Learn how to audit an MT4 Expert Advisor DLL dependency chain, identify missing libraries, assess security prompts, and test safely before trading.",keywords:"MT4 EA DLL dependency audit, missing MT4 DLL libraries, Expert Advisor DLL check, MT4 allow DLL imports, EA library troubleshooting",excerpt:"A missing or untrusted DLL can stop an MT4 Expert Advisor before its trading logic runs. This practical review guide explains how to map dependencies, investigate errors, and make an informed deployment decision.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:cu,imageAlt:"MT4 trading terminal connected to modular software library blocks with a security shield and diagnostic magnifier",tableOfContents:[{id:"why-dll-audit-matters",title:"Why a DLL Audit Comes Before Trading"},{id:"dll-basics",title:"What an EA DLL Dependency Actually Is"},{id:"start-with-evidence",title:"Start With the Terminal Evidence"},{id:"build-dependency-map",title:"Build a Dependency Map"},{id:"classify-findings",title:"Classify Missing, Blocked, and Risky Libraries"},{id:"security-review",title:"Review Security and Trust Boundaries"},{id:"controlled-test",title:"Use a Controlled Test Procedure"},{id:"examples",title:"Practical Diagnostic Examples"},{id:"decision-framework",title:"Make a Deployment Decision"},{id:"when-source-is-unavailable",title:"When Source Code Is Unavailable"},{id:"conclusion",title:"Conclusion"}],content:`
423<p>An MT4 Expert Advisor can appear to load normally and still be unable to do its intended work. One frequent reason is a Dynamic Link Library dependency. The EA may rely on a small companion module for licensing, calculations, a data feed, file conversion, encryption, or communication with another program. If that module is missing, incompatible, blocked by terminal settings, or unsafe to trust, the problem sits below the visible trading rules. Turning on automated trading and hoping for the best is not a sensible diagnostic method.</p>
424
425<p>This guide approaches DLL review as a pre-trading audit. It is written for traders, EA owners, and technical reviewers who need to understand what a compiled MT4 robot expects from its environment. It does not assume that every DLL is malicious or that every missing file is a defect. A library can be a legitimate part of a documented system. Equally, a library request can create a security, compatibility, or operational question that deserves an answer before the EA reaches a funded account.</p>
426
427<img src="${cu}" alt="MT4 trading terminal connected to modular software library blocks with a security shield and diagnostic magnifier" style="width:100%;border-radius:8px;margin:24px 0;" />
428
429<p>The review site does not provide DLL repair or trading services. Its role is to help readers separate evidence from assumption and choose an appropriate next step. For an owner examining a compiled robot, an <a href="/">mt4 ea decompiler</a> can be part of a wider source recovery discussion, but it is not a substitute for checking the files, settings, and vendor documentation already available. The first useful result of an audit is often modest: a clear list of what the EA needs, where that need is failing, and what must be verified.</p>
430
431<h2 id="why-dll-audit-matters">Why a DLL Audit Comes Before Trading</h2>
432
433<p>MT4 runs an EA inside a trading terminal, but a DLL can extend the EA beyond ordinary MQL4 functions. That extension may read a local device, call an operating system function, query a licensing component, connect to a vendor application, or perform a calculation outside the terminal. The convenience comes with dependency risk. The EA is no longer just the EX4 file and its input settings. Its behavior depends on a chain of files, permissions, versions, and machine conditions.</p>
434
435<p>When the chain breaks, the outcome is not always a clean error. An EA might fail to initialize, attach but remain inactive, reject orders after a time check, display a licence warning, or use a fallback path that changes expected behavior. A trader who sees only the smiling or frowning icon on the chart can misdiagnose the issue as a broker problem, market closure, or a poor strategy. The terminal journals and the library chain often provide a more direct explanation.</p>
436
437<p>An audit also protects against the opposite mistake: copying a requested DLL into a system folder simply because a seller instructed 
437it. Windows libraries can have broad access to the computer depending on their design and permissions. A file name alone does not establish origin, safety, or compatibility. The right question is not, “How can this warning be suppressed?” It is, “What is this component, why does this EA require it, and is there sufficient reason to permit it in this environment?”</p>
438
439<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:20px;margin:28px 0;">
440<h3 style="margin-top:0;">Audit principle</h3>
441<p style="margin-bottom:0;">Do not enable DLL imports on a live trading installation merely to see whether an EA starts. Identify the dependency, verify its provenance, and test the complete setup in a separate environment first.</p>
442</div>
443
444<h2 id="dll-basics">What an EA DLL Dependency Actually Is</h2>
445
446<p>A DLL is a compiled Windows library that exposes functions another program can call. In MQL4, a developer can declare imported functions and specify the library that contains them. At runtime, Windows and MT4 must be able to locate and load that library. The library may itself require other libraries. This creates a dependency tree rather than a single file check.</p>
447
448<p>For example, an EA called RangePilot.ex4 might call LicenseStatus from VendorAuth.dll. VendorAuth.dll may depend on a Microsoft runtime and a configuration file placed beside it. If any component is absent or the architecture is unsuitable, the visible error may name VendorAuth.dll even though the file exists. The first missing item in the chain is not necessarily the only issue.</p>
449
450<table>
451<thead><tr><th>Component</th><th>Typical purpose</th><th>Audit question</th></tr></thead>
452<tbody>
453<tr><td>EX4 Expert Advisor</td><td>Trading logic and imported declarations</td><td>Which library names does it request?</td></tr>
454<tr><td>Vendor DLL</td><td>Licence, calculation, bridge, or utility feature</td><td>Who supplied it and which version is expected?</td></tr>
455<tr><td>Nested DLL</td><td>Runtime support or specialist capability</td><td>Is it present and compatible with Windows?</td></tr>
456<tr><td>Configuration or data file</td><td>Keys, endpoints, model data, or settings</td><td>Does the library require a specific location or access right?</td></tr>
457<tr><td>MT4 permission setting</td><td>Terminal approval for library calls</td><td>Is the request disabled intentionally or accidentally?</td></tr>
458</tbody>
459</table>
460
461<p>Not all imports mean the same thing. A library used to calculate a proprietary indicator may have a different risk profile from one that opens a network connection or reads a hardware identifier. A documented bridge to a regulated data source can be understandable, while an unnamed binary distributed through an archive with no version notes warrants more caution. The audit should describe functions and behavior where evidence allows, without pretending that a file name proves intent.</p>
462
463<h2 id="start-with-evidence">Start With the Terminal Evidence</h2>
464
465<p>Begin without changing settings. Preserve the original package, note the EA name and version shown in its properties, and take copies of the Experts and Journal messages that occur when it is attached to a chart. Record the terminal build, Windows edition, whether the system is 32-bit or 64-bit, and the folder in which the EA and supplied files were installed. These details make a vendor support request more useful and prevent a later reviewer from guessing what happened.</p>
466
467<p>MT4 has data folders distinct from the program installation in many setups. The proper location for a supplied library can depend on the terminal's data path and the vendor's instructions. Moving files between random Windows directories may hide the real problem, introduce a conflicting version, or create a setup that cannot be reproduced on a VPS. Use the terminal's own folder navigation and the installation documentation as the starting reference.</p>
468
469<h3>Evidence collection checklist</h3>
470<ul>
471<li>Keep an untouched copy of the download or installer and note its source.</li>
472<li>Record the EX4 and DLL file names, sizes, modified dates, and version labels if available.</li>
473<li>Capture the exact journal message, including punctuation and error number.</li>
474<li>Note whether the EA fails during initialization, only at order time, or after a scheduled event.</li>
475<li>Write down terminal build, broker server, Windows architecture, and whether the test is local or on a VPS.</li>
476<li>Keep the supplied readme, invoice, licence terms, and vendor installation instructions together.</li>
477</ul>
478
479<p>This record helps distinguish a technical setup issue from a commercial restriction. For instance, a “cannot load” message points toward a file path, ar
479chitecture, or nested dependency issue. A message stating that a licence is inactive may instead mean that the DLL loaded successfully and made a deliberate decision. Both deserve attention, but the remedies and permissions are different.</p>
480
481<p>Readers troubleshooting a robot after moving terminals should also review the related <a href="/blog/expert-advisor-vps-transfer-audit-mt4">MT4 VPS transfer audit</a>. A working desktop installation does not prove that a VPS has the same DLLs, runtimes, permissions, terminal build, or file paths. Migration is a common moment for a hidden dependency to surface.</p>
482
483<h2 id="build-dependency-map">Build a Dependency Map</h2>
484
485<p>The practical objective is a plain-language map. Start at the EA, list every supplied library, then identify what each library needs to load and operate. The map can be built from vendor documentation, import declarations when source is available, file properties, error messages, and a reputable dependency inspection tool used on an isolated copy. Do not execute an unknown file merely to inspect its name or metadata.</p>
486
487<p>A useful map separates confirmed facts from open questions. “VendorAuth.dll is supplied in the package” is a fact. “VendorAuth.dll sends account data to a licensing server” is only a fact if documentation, observable traffic in a controlled test, or a trusted technical review supports it. Labeling uncertainty prevents a spreadsheet from becoming false reassurance.</p>
488
489<table>
490<thead><tr><th>Dependency</th><th>Expected location</th><th>Status</th><th>Evidence</th><th>Next action</th></tr></thead>
491<tbody>
492<tr><td>VendorAuth.dll</td><td>MT4 library folder</td><td>Present, blocked</td><td>Terminal settings and journal</td><td>Confirm why imports are required</td></tr>
493<tr><td>msvcp runtime</td><td>Windows runtime installation</td><td>Unknown</td><td>Dependency inspection</td><td>Confirm vendor-supported prerequisite</td></tr>
494<tr><td>licence.dat</td><td>Vendor documented data folder</td><td>Missing</td><td>Installation guide</td><td>Ask vendor for authorised replacement</td></tr>
495<tr><td>Remote endpoint</td><td>Network connection</td><td>Unverified</td><td>Vendor documentation</td><td>Assess privacy and availability impact</td></tr>
496</tbody>
497</table>
498
499<p>Pay close attention to names that look generic. A library named common.dll may be a normal vendor component, but its generic name makes it easier to confuse with an unrelated file. Hashes can help confirm whether two copies are identical, yet a matching hash only proves sameness with the comparison copy. It does not prove the original was trustworthy. Prefer a current, authenticated vendor distribution channel and a written version reference when one exists.</p>
500
501<h3>Questions for the EA vendor</h3>
502<ol>
503<li>Which DLLs and supporting files are mandatory for this exact EA version?</li>
504<li>What folder should each item occupy in a standard MT4 data installation?</li>
505<li>Does the library require a particular Visual C++ runtime, .NET component, service, or Windows feature?</li>
506<li>Is the library 32-bit, and is it supported with the current MT4 build?</li>
507<li>What functions does it perform, including any network, account, or licensing activity?</li>
508<li>What error messages indicate a missing component versus a licence or configuration problem?</li>
509<li>Does a current signed installer or checksum exist for the release?</li>
510</ol>
511
512<p>A transparent answer does not make a trading system suitable, but it makes a technical decision possible. Evasive instructions such as “disable your antivirus and copy this everywhere” do the opposite. They expand the risk without identifying the dependency or offering a way to validate it.</p>
513
514<h2 id="classify-findings">Classify Missing, Blocked, and Risky Libraries</h2>
515
516<p>It is tempting to call every load failure “missing DLL.” That phrase covers several different conditions. Classification prevents an operator from applying the wrong fix.</p>
517
518<h3>Missing or incorrectly placed</h3>
519<p>The named file is absent from the documented location, or the EA expects a different file name. A clean reinstall from a vendor-provided package may resolve this category. Before replacing anything, compare the EA version with the package version. Pairing a newer EX4 with an older companion library can create another failure.</p>
520
521<h3>Present but unable to load</h3>
522<p>The DLL is visible in the folder but Windows cannot load it. Causes can include a missing nested runtime, corruption, file blocking after download, a required configuration file, or an architecture mismatch. MT4 commonly relies on 32-bit libraries, so a 64-bit-only library may not work even on a 64-bit operating system. The journal text and dependency map guide the next step.</p>
523
524<h3>Present but not permitted</h3>
525<p>MT4 can disable DLL calls at the terminal or EA level. This is a security control, not an error to override casually. The correct response is to understand the import before granting permission. An EA that cannot operate without a documented, trusted DLL may be appropriate for a segregated test terminal. An EA whose library purpose remains unknown is not ready for expanded permissions.</p>
526
527<h3>Loaded but operationally fragile</h3>
528<p>Some libraries load but depend on a remote licence server, a changing machine identifier, a fixed local path, or a network service. Such a setup can work in a brief demo and fail during a VPS restart, internet interruption, vendor outage, or account migration. The audit should state this as an operational dependency. It is relevant even when the file itself appears legitimate.</p>
529
530<h2 id="security-review">Review Security and Trust Boundaries</h2>
531
532<p>Allowing DLL imports changes the trust boundary of a trading installation. MQL4 code is constrained by the terminal environment in ways that a native Windows library may not be. The exact capabilities depen
532d on the library and system permissions, so reviewers should avoid blanket claims. Still, the general principle is clear: a library that is allowed to run should be treated as software that requires its own provenance review.</p>
533
534<p>Start with origin. Was the file downloaded from the vendor's authenticated site, delivered through a signed installer, or shared by an unrelated third party? Is there a release note that ties the DLL version to the EA version? Is the vendor identifiable and reachable? Malware scanning can add a signal, but a clean scan is not proof of suitability. Conversely, a detection can be a false positive or a serious warning. A disputed result should lead to a careful vendor conversation and an isolated review, not an instant exception.</p>
535
536<p>Next, consider information flow. A licensing library may legitimately collect an account number or machine identifier to enforce a paid subscription. The operator should know that this occurs, understand the vendor's terms, and decide whether that arrangement is acceptable. A library that accesses files, launches processes, or uses the network without documentation creates unanswered questions. It should not be deployed to an account containing credentials or valuable operational data simply because the EA promises attractive results.</p>
537
538<p>Segregation is a practical control. A separate Windows user, virtual machine, or test VPS can limit exposure to personal files and unrelated applications. This does not make unsafe software safe, and it does not remove the need to respect licence terms. It does create a more controlled setting for observing whether the EA initializes, how the library behaves, and whether the setup can be reproduced without touching a production terminal.</p>
539
540<h2 id="controlled-test">Use a Controlled Test Procedure</h2>
541
542<p>A dependency audit ends with a test plan, not with a guess. The plan should confirm the library load, the EA initialization path, expected permissions, and basic operational behavior before any live use. A demo account can reduce market exposure, but it does not solve device or credential risk. Keep test scope proportionate to what has been verified.</p>
543
544<ol>
545<li><strong>Create an isolated installation.</strong> Use a clean MT4 data environment or separate machine profile. Do not reuse a terminal containing unrelated EAs or sensitive documents.</li>
546<li><strong>Install only documented components.</strong> Place the EA, libraries, and configuration files in the specified locations. Record every file added.</li>
547<li><strong>Keep DLL imports disabled initially.</strong> Attach the EA and collect its messages. This establishes what permission it requests.</li>
548<li><strong>Verify provenance and purpose.</strong> Compare versions with vendor records, review documentation, and resolve missing or unknown nested dependencies.</li>
549<li><strong>Enable only the necessary permission.</strong> If the library is understood and trusted for testing, enable the relevant EA setting rather than broadly changing unrelated terminal controls.</li>
550<li><strong>Observe initialization and restart behavior.</strong> Restart the terminal, reconnect the account, and confirm that the EA reports the same state. Note network or licence prompts.</li>
551<li><strong>Test the stated function without live orders.</strong> Where possible, use a demo or disabled trading setting to confirm calculations, signals, logs, and error handling.</li>
552<li><strong>Document the result.</strong> Save the final dependency map, messages, settings, and unresolved risks. A passing test is evidence for that configuration only.</li>
553</ol>
554
555<p>Do not confuse a successful Strategy Tester run with a complete DLL audit. Testers may not reproduce external calls, licensing checks, network behavior, broker symbol details, or VPS restrictions in the same way as a live terminal. The separate guide to an <a href="/blog/mt4-ea-broker-symbol-name-mismatch-fix">MT4 broker symbol name mismatch</a> shows another example of an environment-specific issue that can remain hidden until a robot meets the actual account conditions.</p>
556
557<h2 id="examples">Practical Diagnostic Examples</h2>
558
559<h3>Example 1: The library is present but MT4 says it cannot load</h3>
560<p>A trader receives an EA and AuthBridge.dll in the same archive. Both are placed in the documented folder, yet the Experts tab reports that the library cannot be loaded. The audit should not stop at confirming that AuthBridge.dll exists. A dependency inspection of an isolated copy may show that it expects a runtime absent from the machine. The appropriate action is to ask the vendor for the supported prerequisite and installation method, rather than downloading similarly named DLLs from file-sharing sites.</p>
561
562<h3>Example 2: Enabling imports removes the error but creates a new question</h3>
563<p>An EA initializes only after “Allow DLL imports” is selected. Its documentation says the library validates the subscription. The technical problem may now be resolved, but the audit continues: what account or machine data is transmitted, what happens if the vendor server is unavailable, and can the licence be transferred to a VPS? A well-documented answer can support a controlled deployment choice. No answer means the operator is accepting an unknown operational dependency.</p>
564
565<h3>Example 3: A copied installation fails after a VPS move</h3>
566<p>A robot works on a home computer and fails on a VPS. The EA file was copied, but its companion library, runtime, or licence data was not. Another possibility is that the licence is intentionally tied to the original machine. The correct action is not to modify the library or bypass the check. 
566Compare the two dependency maps, use the authorised vendor migration process, and document any change in account or machine identifiers.</p>
567
568<h2 id="decision-framework">Make a Deployment Decision</h2>
569
570<p>After the evidence and controlled test, make a simple decision rather than allowing uncertainty to drift into production. The following categories are useful because they connect technical findings to an action.</p>
571
572<table>
573<thead><tr><th>Finding</th><th>Deployment view</th><th>Appropriate next step</th></tr></thead>
574<tbody>
575<tr><td>All components documented, sourced, and reproducibly tested</td><td>Conditional readiness</td><td>Maintain records and review changes before updates</td></tr>
576<tr><td>Known component missing, vendor gives clear supported instructions</td><td>Hold pending retest</td><td>Install from authorised source in the test environment</td></tr>
577<tr><td>Library purpose or origin cannot be established</td><td>Not ready</td><td>Do not enable imports; request documentation or abandon use</td></tr>
578<tr><td>Licence or account restriction blocks the library</td><td>Authorisation issue</td><td>Use the vendor's authorised support path</td></tr>
579<tr><td>Library works only through fragile, undocumented conditions</td><td>Operational risk</td><td>Assess whether the dependency is acceptable before use</td></tr>
580</tbody>
581</table>
582
583<p>This framework does not rate strategy quality or predict trading performance. It answers a narrower question: is the software environment understood well enough to proceed to the next evaluation stage? A trader may still decide that a documented library is too much operational complexity for a particular VPS or account. That is a valid conclusion. Reliability includes the ability to reinstall, update, and diagnose a system without emergency guesswork.</p>
584
585<h2 id="when-source-is-unavailable">When Source Code Is Unavailable</h2>
586
587<p>Compiled-only EAs limit what a buyer can inspect directly. Legitimate documentation and the vendor's explanations should therefore carry more weight, not less. A purchaser should not assume that a paid licence grants permission to extract, alter, or remove a DLL dependency. Licence terms, ownership, and local law still matter. Requests to bypass an activation library or obtain a competitor's implementation are not appropriate audit goals.</p>
588
589<p>Where a reader owns the relevant code or has explicit written authority to maintain it, source recovery can sometimes support a technical review. The site's coverage of <a href="/">decompile ex4 to mq4</a> options explains that recovered output may require careful validation and may not recreate original comments, structure, or every dependency detail. The service at ForexMQ5 is reviewed as a professional option for authorised EX4 to MQ4 recovery needs, not as a means to defeat licensing or copy another party's strategy. Any recovered project should retain its evidence of ownership, limited purpose, and confidentiality controls.</p>
590
591<p>For most purchasers, the better first step is simpler: ask the vendor for a dependency manifest, supported installation package, change log, and migration instructions. A vendor that cannot explain an essential binary component leaves the buyer unable to assess continuity. That concern is separate from whether the EA has ever produced a profitable backtest.</p>
592
593<h2 id="conclusion">Conclusion</h2>
594
595<p>A DLL warning is not a checkbox problem. It is evidence that an MT4 EA depends on software outside the visible robot file. Before trading, identify the library chain, preserve terminal evidence, distinguish missing files from permission and licence issues, verify provenance, and test only in a controlled environment. The aim is not to make every EA run. It is to know what must run, why it is trusted, and what can cause it to fail.</p>
596
597<p>That discipline gives traders a clearer decision: proceed with a documented and reproducible configuration, pause for authorised vendor support, or decline software whose dependencies remain unexplained. In automated trading, a strategy is only one part of the system. The supporting libraries, permissions, machine setup, and recovery plan deserve the same careful attention before a real order is allowed to depend on them.</p>
598`},{slug:"mt4-magic-number-conflict-guide",title:"MT4 Magic Number C
598onflicts: Stop Expert Advisors Managing the Wrong Trades",metaTitle:"MT4 Magic Number Conflicts: Stop EAs Managing Wrong Trades",metaDescription:"Learn how MT4 magic number conflicts let Expert Advisors manage the wrong trades, and use a practical identity plan to isolate every robot safely.",keywords:"MT4 magic number conflict, Expert Advisor managing wrong trades, MQL4 magic number, MT4 EA trade isolation, OrderMagicNumber, EA order management",excerpt:"When two MT4 robots reach for the same order ticket, a shared or weak magic number is often the missing identity control. This guide explains how to diagnose collisions, design clear tags, and validate an EA before it manages live orders.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:hu,imageAlt:"Two MT4 Expert Advisors separated by clear magic-number identity tags and a warning symbol",tableOfContents:[{id:"the-ticket-grab",title:"The Ticket Grab Problem"},{id:"what-a-magic-number-does",title:"What a Magic Number Actually Identifies"},{id:"collision-patterns",title:"The Conflict Patterns to Recognize"},{id:"triage",title:"Triage When a Robot Touches the Wrong Trade"},{id:"identity-design",title:"Designing a Clear Identity Scheme"},{id:"mql4-filtering",title:"Safe MQL4 Order Filtering"},{id:"testing-plan",title:"A Test Plan Before Live Use"},{id:"recovered-eas",title:"Special Care for Recovered or Unfamiliar EAs"},{id:"operating-checklist",title:"Daily Operating Checklist"},{id:"conclusion",title:"Conclusion: Make Every Trade Ownable"}],content:`
599<p>One MT4 chart can look calm while two Expert Advisors are quietly arguing over the same order. Robot A sees a buy position and trails its stop. Robot B sees that same position and decides its exit condition is met. Neither decision is necessarily irrational in isolation. The failure is that both programs believe the ticket belongs to them.</p>
600
601<p>MT4 gives an Expert Advisor a simple way to label orders: the magic number. Used carefully, that number acts like an identity tag. Used casually, copied between installations, or ignored in order-selection code, it creates a path for one robot to close, modify, count, or protect another robot's trade. The outcome may be confusing trade history, broken position limits, unexpected closes, or risk controls that no longer match the strategy that opened the position.</p>
602
603<img src="${hu}" alt="Two MT4 Expert Advisors separated by clear magic-number identity tags and a warning symbol" style="width:100%;border-radius:8px;margin:24px 0;" />
604
605<p>This independent review guide explains the engineering problem rather than promising a trading result. It is relevant to traders running several EAs, developers maintaining legacy MQL4, and owners examining recovered source code. Anyone assessing an <a href="/">ex4 to mq4 decompiler</a> path should treat order ownership as a core audit item. Readable code is useful only when its order-management rules can be understood and tested.</p>
606
607<h2 id="the-ticket-grab">The Ticket Grab Problem</h2>
608
609<p>In MT4, every open market order and pending order has a ticket number assigned by the trading server. A ticket is unique for that order. It does not tell an EA which strategy is allowed to manage it. That permission is created by the EA's own logic, usually by checking symbol, order type, magic number, and sometimes a comment or other context before taking action.</p>
610
611<p>Consider a common setup. A trader attaches a trend EA to EURUSD H1 and a recovery EA to EURUSD M15. Both use magic number 10001 because the second copy retained the developer's default input. The trend EA opens a buy. On the next tick, the recovery EA loops through orders, sees an EURUSD buy with magic number 10001, and includes it in its own basket. It may move the stop, calculate the wrong average entry, or close the order as part of a recovery rule. The trade ticket has not changed. The ownership assumption has.</p>
612
613<p>The same issue can occur even where magic numbers differ if the management loop filters only by symbol. A condition such as OrderSymbol() == Symbol() is not an ownership check. It merely says that an order belongs to the instrument on the current chart. On EURUSD, that can include manual trades, another EA's trades, a copied signal, and a different instance of the same EA.</p>
614
615<div style="background:#fff4e5;border:1px solid #f0c36d;border-radius:8px;padding:20px;margin:28px 0;">
616  <h3 style="margin-top:0;">Warning sign</h3>
617  <p>If an EA changes a stop loss, take profit, or order state that its journal never reported opening, pause automated management. A shared magic number is one possible cause, but a missing magic filter, symbol suffix mismatch, or manual intervention can produce a similar symptom.</p>
618</div>
619
620<p>This is not only a coding concern. A sound configuration process matters just as much. A correctly written EA can still collide with another instance if users give both the same identifier. Conversely, a carefully assigned identifier does not protect an account if an EA ignores it when scanning orders. Protection requires both a unique plan and code that enforces the plan.</p>
621
622<h2 id="what-a-magic-number-does">What a Magic Number Actually Identifies</h2>
623
624<p>A magic number is an integer stored with an order when an EA sends it. In MQL4, OrderSend accepts the magic number as one of its parameters, and OrderMagicNumber reads it back after an order has been selected. Manual MT4 orders ordinarily use zero. That convention is useful, but it is not a security boundary. A program can deliberately use zero, a human can place a trade that resembles an EA trade, and a copied EA can reuse any value.</p>
625
626<p>The magic number should answer a narrow operational question: which management domain created this order? A management domain can be a strategy, a specific account deployment, or a strategy and symbol pair. It should not be treated as proof of who authored code, a guarantee that an order is safe, or a substitute for checking the trading account and symbol.</p>
627
628<table>
629  <thead><tr><th>
629Field</th><th>What it can help establish</th><th>What it cannot establish alone</th></tr></thead>
630  <tbody>
631    <tr><td>Ticket number</td><td>The individual server order</td><td>Which EA owns the management decision</td></tr>
632    <tr><td>Magic number</td><td>The EA's intended strategy identity</td><td>Whether the value is unique across the account</td></tr>
633    <tr><td>Symbol</td><td>The traded instrument</td><td>Which of several EAs on that symbol may act</td></tr>
634    <tr><td>Order type</td><td>Buy, sell, or pending-order category</td><td>Whether the trade belongs to the current strategy</td></tr>
635    <tr><td>Order comment</td><td>A human-readable diagnostic clue</td><td>A reliable primary identifier, since servers may alter it</td></tr>
636  </tbody>
637</table>
638
639<p>Think of the fields together. An EA that manages only orders matching its expected symbol, its expected magic number, and relevant order types has a much narrower reach than one that scans everything. Account-level checks can narrow it further where an EA is meant for a single deployment. The goal is not elaborate tagging for its own sake. The goal is to make an unintended match unlikely and visible.</p>
640
641<h2 id="collision-patterns">The Conflict Patterns to Recognize</h2>
642
643<p>Magic-number trouble is rarely announced as a neat compiler error. It normally appears as behavior that looks random until the order history is compared with each EA's configuration. These patterns deserve a deliberate review.</p>
644
645<h3>Copied defaults</h3>
646<p>Many commercial or custom EAs expose a MagicNumber input with one default value. Installing two copies without changing it means they speak the same identity. This can happen across different charts, timeframes, symbols, or versions. The default itself is not defective. Reusing it without a deployment plan is the problem.</p>
647
648<h3>One strategy, multiple charts</h3>
649<p>Some strategies are designed to run once per symbol, while others support separate instances per timeframe. If the EA uses a single magic number for all instances and filters only by magic and symbol, two charts of the same pair can still share a basket. A timeframe is not recorded on an order, so it cannot be recovered later from OrderSelect. An EA that needs instance separation must encode it in its configuration or identity design.</p>
650
651<h3>Manual orders caught in a wide net</h3>
652<p>A loop that does not check OrderMagicNumber can modify manual positions. The reverse is possible too: an EA using magic zero can collide with manual activity. Traders who want a strict manual account should generally keep it separate from automated systems, but code should still behave defensively.</p>
653
654<h3>Different brokers, same visible pair</h3>
655<p>EURUSD, EURUSDm, and EURUSD.a may all refer to related broker symbols. A simplistic string comparison can cause an EA to miss its own order after a migration. Overly loose normalization can make it manage another chart's order. The site's guide to <a href="/blog/mt4-ea-broker-symbol-name-mismatch-fix">MT4 broker symbol name mismatches</a> covers the naming side of that investigation. Symbol handling and magic handling are separate controls that should agree.</p>
656
657<h3>Old code and partial upgrades</h3>
658<p>A developer may update entry logic but leave an old close-all routine behind. The new orders receive a fresh magic number, yet the routine closes every order on the current symbol. Another variation occurs when a recovered EA has several internal modules with hard-coded magic values. Changing the visible input may not change each module. This is why configuration labels alone do not prove the running behavior.</p>
659
660<h2 id="triage">Triage When a Robot Touches the Wrong Trade</h2>
661
662<p>When a suspected conflict happens, the first goal is containment, not a quick edit. Closing charts, changing inputs, or recompiling immediately can erase clues about what occurred. The following sequence gives a practical, cautious starting point.</p>
663
664<ol>
665  <li><strong>Stop further automated actions.</strong> Disable AutoTrading or remove the affected EAs after noting the time. Do not assume that closing one chart stops every instance.</li>
666  <li><strong>Capture evidence.</strong> Save account history, screenshots of open orders, the Experts and Journal entries, EA input sets, and the relevant EX4 or M
666Q4 version. Record ticket, symbol, open time, magic number, comment, and every modification.</li>
667  <li><strong>Build an ownership list.</strong> For each active EA instance, write its chart, symbol, timeframe, version, intended magic number, and intended order types. Include pending orders and manual positions.</li>
668  <li><strong>Compare the affected ticket.</strong> Identify which instance reported an entry or management event nearest the change. A ticket's magic number can show an intended source, but logs and code reveal which EA actually acted.</li>
669  <li><strong>Inspect filters before re-enabling.</strong> Look at every routine that counts, modifies, closes, trails, or deletes orders. The entry function may filter correctly while a helper function does not.</li>
670  <li><strong>Reproduce away from a live account.</strong> Use a controlled demo or test environment with deliberately distinct labels. A test should prove both that each EA manages its own ticket and that it ignores the other one.</li>
671</ol>
672
673<p>A disciplined incident note is valuable. It avoids the vague conclusion that “MT4 mixed up trades.” MT4 stores the fields it was given. The mistake is usually in deployment or selection logic. The precise diagnosis might be “EA B's trailing routine filtered by EURUSD but not magic number” or “both EURUSD instances were configured with 4102.” That statement can be fixed, tested, and documented.</p>
674
675<h2 id="identity-design">Designing a Clear Identity Scheme</h2>
676
677<p>A good magic-number scheme is boring enough that another person can audit it. Random large numbers may reduce accidental duplication, but they are hard to operate. A structured scheme helps an owner see what a value means while retaining enough room for future instances.</p>
678
679<p>One example is a six-digit format: SS PP II. The first two digits identify the strategy family, the next two identify the instrument group or deployment, and the final two identify the instance. Under that convention, 120305 could mean strategy 12, deployment group 03, instance 05. The exact digits are less important than the registry that defines them. A developer must confirm the chosen range remains a valid integer for the EA and broker environment.</p>
680
681<table>
682  <thead><tr><th>Deployment</th><th>Suggested tag</th><th>Registry note</th></tr></thead>
683  <tbody>
684    <tr><td>Trend EA, EURUSD H1, primary</td><td>120301</td><td>Family 12, EURUSD group 03, instance 01</td></tr>
685    <tr><td>Trend EA, GBPUSD H1, primary</td><td>120401</td><td>Same family, different symbol group</td></tr>
686    <tr><td>Recovery EA, EURUSD M15</td><td>270301</td><td>Different strategy family, same symbol group</td></tr>
687    <tr><td>Manual trading</td><td>0</td><td>Reserved and never used by automated systems</td></tr>
688  </tbody>
689</table>
690
691<p>Keep the registry in a location that survives a VPS move. A simple spreadsheet or deployment record can work. Its useful columns are account alias, broker server, EA name and version, chart symbol, timeframe, magic number, installation date, and person responsible for changes. Do not rely on a chart label that disappears after a template is replaced.</p>
692
693<h3>Decide the ownership boundary first</h3>
694
695<p>Before allocating numbers, decide what must be isolated. If one EA uses an internal basket across EURUSD timeframes, its instances may intentionally share a magic number. If separate charts must calculate stops and exposure independently, they need separate numbers. There is no universal rule that every chart should be unique. The correct rule follows the strategy's intended order-management scope.</p>
696
697<h3>Reserve ranges</h3>
698
699<p>Reserve a range for each strategy family and do not repurpose an old value merely because an EA is removed. Historical orders, delayed pending orders, backups, and a forgotten VPS copy can return the value to use. A small retired-number list reduces that chance. For a multi-account operation, decide whether numbers repeat per account or include an account deployment segment. Both can work if the management code never crosses accounts and records are clear.</p>
700
701<h2 id="mql4-filtering">Safe MQL4 Order Filtering</h2>
702
703<p>Order-management code should make ownership checks explicit at the point of action. A loop that selects an order is only the beginning. Before OrderModify, OrderClose, or OrderDelete, the EA should verify that the selected ticket matches its domain. The following illustrative pattern is not a complete trading system, but it shows the essential gate.</p>
704
705<pre><code>bool IsMyMarketOrder(int expectedMagic, string expectedSymbol) {
706  if (OrderSymbol() != expectedSymbol) return(false);
707  if (OrderMagicNumber() != expectedMagic) return(false);
708  int type = OrderType();
709  if (type != OP_BUY && type != OP_SELL) return(false);
710  return(true);
711}</code></pre>
712
713<p>A close or trailing loop can call this after OrderSelect and before any state-changing instruction. Pending orders need their own intentional rule. An EA that manages pending entr
713ies should check the expected pending types rather than assuming every selected order is a market position. Likewise, a basket system may need to confirm direction, comment format, or a stored relationship between tickets, but those checks should supplement rather than replace the magic number.</p>
714
715<p>There are implementation details worth reviewing:</p>
716
717<ul>
718  <li><strong>Use the configured value consistently.</strong> Do not send orders with an input called MagicNumber and then filter with an unrelated hard-coded literal.</li>
719  <li><strong>Check after selection.</strong> OrderMagicNumber and OrderSymbol describe the currently selected order. Calling them without a successful OrderSelect risks acting on stale assumptions.</li>
720  <li><strong>Log identity with actions.</strong> A useful message includes EA name, expected magic, ticket, symbol, action, and result. It shortens later diagnosis.</li>
721  <li><strong>Handle failed modifications.</strong> A failed OrderModify should report GetLastError and should not lead the EA to assume a protective stop changed.</li>
722  <li><strong>Avoid broad emergency routines.</strong> A button or condition named close all should state exactly whether it means all orders for this EA, all automated orders, or the entire account.</li>
723</ul>
724
725<p>These checks do not make an EA profitable or suitable for a particular account. They only reduce one category of operational ambiguity. Risk settings, broker execution, spread, and market conditions remain separate matters. The priority here is that a strategy's action reaches only the tickets it was designed to control.</p>
726
727<h2 id="testing-plan">A Test Plan Before Live Use</h2>
728
729<p>A visual chart review cannot prove isolation. The practical test is adversarial: create nearby orders that look tempting to the EA and confirm it leaves them alone. Test on a non-live environment whenever possible, and use small, controlled conditions rather than trying to infer behavior from a long backtest.</p>
730
731<h3>Minimum isolation test matrix</h3>
732
733<table>
734  <thead><tr><th>Test case</th><th>Setup</th><th>Expected result</th></tr></thead>
735  <tbody>
736    <tr><td>Own market order</td><td>Matching symbol and magic number</td><td>EA may manage it according to its rules</td></tr>
737    <tr><td>Other EA, same symbol</td><td>Matching symbol, different magic number</td><td>EA must ignore it</td></tr>
738    <tr><td>Other EA, different symbol</td><td>Different symbol and different magic number</td><td>EA must ignore it</td></tr>
739    <tr><td>Manual order</td><td>Matching symbol, magic number zero</td><td>EA must ignore it unless zero is deliberately supported</td></tr>
740    <tr><td>Pending order</td><td>Matching magic number, pending type</td><td>Only the documented pending-order routine may act</td></tr>
741    <tr><td>Duplicate instance</td><td>Two charts intentionally assigned one tag</td><td>Behavior must match the stated shared-basket design</td></tr>
742  </tbody>
743</table>
744
745<p>Start by placing or simulating known tickets, then trigger only the management event under examination. For example, test a trailing stop routine without also testing a new entry at the same moment. Read the logs and order history after each case. The pass condition is not merely “no error appeared.” It is a documented match between the expected ticket action and the observed ticket action.</p>
746
747<p>After passing the basic matrix, test restarts. MT4 terminals and VPS sessions do restart, and an EA may reconstruct its state by scanning open orders. A program that behaves correctly immediately after opening a trade can still seize another strategy's ticket after initialization if its startup scan omits a filter. Also test a changed broker symbol, a removed chart, and an orphan pending order if those situations are relevant to the deployment.</p>
748
749<h2 id="recovered-eas">Special Care for Recovered or Unfamiliar EAs</h2>
750
751<p>An unfamiliar EX4 deserves extra caution because its magic-number behavior may not be visible in the inputs. A recovered source project can make review easier, but recovery may produce renamed variables, flattened routines, or code that needs technical cleanup. The review site recommends treating source recovery as the beginning of an audit, not as an automatic approval for live deployment.</p>
752
753<p>Search the recovered MQL4 for OrderSend, OrderMagicNumber, OrderSelect, OrderClose, OrderModify, and OrderDelete. Then trace every path from selection to action. Note all numeric literals passed as magic values and every comparison that decides whether an order is “mine.” If a number appears in one function but not the inputs, record 
753it. If a loop lacks a magic-number condition, flag it for review even when it currently runs on a dedicated account.</p>
754
755<p>Readers needing a broader source review can use the site's guide on <a href="/blog/how-to-read-recovered-mql4-expert-advisor-code">how to read recovered MQL4 Expert Advisor code</a>. The key question for this topic is simple: can a reviewer point to the exact condition that prevents this EA from touching every nearby ticket? If not, it is not ready to share an account with other automated systems.</p>
756
757<p>For owners with a documented right to recover their own code, ForexMQ5 is reviewed as a professional recovery option. The service should not be used to bypass licensing controls or obtain a third party's strategy. A recovery request and later use remain the customer's responsibility.</p>
758
759<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
760  <h3 style="margin-top:0;">Need Source for an Authorised EA Review?</h3>
761  <p>Readers with a legitimate recovery or maintenance need can assess the professional option reviewed at ForexMQ5, then verify order ownership before any deployment.</p>
762  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
763</div>
764
765<h2 id="operating-checklist">Daily Operating Checklist</h2>
766
767<p>Once isolation is tested, it still needs routine maintenance. Most conflicts arise after a copy, update, VPS transfer, or new chart is added rather than during the original installation. The following checklist is designed for a trader or operator who wants a repeatable handover process.</p>
768
769<ol>
770  <li>Before adding an EA, check the magic-number registry for an unused value that matches the intended ownership boundary.</li>
771  <li>Record the EA name, version, source file hash if available, broker server, account alias, chart symbol, timeframe, and assigned number.</li>
772  <li>Confirm the chart symbol exactly as the broker presents it, including suffixes or prefixes.</li>
773  <li>Review inputs after loading a preset. A set file can overwrite a carefully chosen number with an old default.</li>
774  <li>On first run, inspect the Experts log and confirm new orders show the expected identity and comment.</li>
775  <li>After an update or restart, repeat the other-EA and manual-order isolation checks in a controlled environment.</li>
776  <li>Keep manual trading separate where practical, and never assume a manual ticket is invisible to an EA.</li>
777  <li>When retiring an EA, remove its charts, pending orders, scheduler entries, and VPS copies before freeing its number.</li>
778</ol>
779
780<p>For a broader review of compiled software before it reaches an account, the site's <a href="/">mt4 ea decompiler</a> resources place code understanding, documented rights, and controlled validation ahead of convenience. That approach is especially helpful when an EA is old, purchased, inherited, or transferred between operators.</p>
781
782<h2 id="conclusion">Conclusion: Make Every Trade Ownable</h2>
783
784<p>A magic number is small, but its role is large. It is the first practical answer to the question every order-management routine should ask: is this ticket mine to touch? When the answer is encoded clearly, checked consistently, and backed by a deployment registry, multiple Expert Advisors can share an MT4 account with far less ambiguity. When the answer is missing, two rational robots can manage the same trade according to incompatible rules.</p>
785
786<p>The most useful response is not to trust a default input or assume that a chart boundary protects an order. Define the ownership boundary, allocate a unique and documented identity where needed, inspect every selection loop, and test negative cases that the EA must ignore. If source code is recovered or unfamiliar, verify these controls before considering any live use. That process will not remove trading risk, but it can stop a preventable software identity conflict from adding to it.</p>
787`},{slug:"mt4-broker-server-time-ea-schedule",title:"Broker Server Time and MT4 EAs: Fix Trading Session Schedule Errors",metaTitle:"Broker Server Time and MT4 EA Session Schedule Errors",metaDescription:"Learn how MT4 broker server time affects Expert Advisor sessions, news filters, daily resets, and backtests. Use a practical clock-mapping workflow to fix schedule errors.",keywords:"MT4 broker server time, MT4 EA session schedule, forex session time conversion, MQL4 TimeCurrent, Expert Advisor trading hours, broker GMT offset",excerpt:"An EA can have correct entry logic and still trade at the wrong hour. This practical guide explains how to map broker server time to market sessions, handle seasonal changes, test schedules, and document a reliable MT4 clock model.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:uu,imageAlt:"World clocks beside an MT4 forex terminal showing a synchronized trading session timeline",tableOfContents:[{id:"why-clock-errors-matter",title:"Why a One-Hour Error Changes an EA"},{id:"four-clocks",title:"The Four Clocks Around an MT4 Schedule"},{id:"build-clock-map",title:"Build a Broker Clock Map Before Editing Code"},{id:"session-design",title:"Design Sessions as Windows, Not Magic Hours"},{id:"mql4-time-functions",title:"MQL4 Time Functions and Common Traps"}
787,{id:"seasonal-changes",title:"DST and Broker Offset Changes"},{id:"testing-workflow",title:"A Repeatable Testing Workflow"},{id:"failure-patterns",title:"Schedule Failures and Their Fixes"},{id:"recovered-eas",title:"When a Recovered EA Has Hidden Time Assumptions"},{id:"deployment-checklist",title:"Deployment Checklist"},{id:"conclusion",title:"Conclusion"}],content:`
788<p>An MT4 Expert Advisor can appear to have a strategy problem when it actually has a clock problem. A breakout EA intended to begin at the London open enters during the quiet hour before it. A news filter switches off too late. A Friday cutoff happens after the broker has widened conditions. A daily loss limit resets at an unexpected time. In each case, the indicator calculations and order rules may be working exactly as written. The schedule is simply being interpreted against a different clock than the person operating the terminal expected.</p>
789
790<p>That distinction is easy to miss because a chart makes time look singular. The lower edge of an MT4 chart shows broker server time, while a trader may be reading local wall time, an economic calendar may publish UTC, and a VPS may run in another time zone. Add daylight-saving changes and a broker that adjusts its own server offset, and a fixed number such as 08:00 becomes an incomplete instruction.</p>
791
792<img src="${uu}" alt="World clocks beside a forex terminal illustrating a synchronized MT4 trading session timeline" style="width:100%;border-radius:8px;margin:24px 0;" />
793
794<p>This guide provides a practical method for diagnosing and preventing those mistakes. It is written for EA owners, testers, and developers who need to reason about schedules, including people reviewing a compiled robot whose original assumptions are unclear. Readers considering an <a href="/">ex4 to mq4</a> recovery should regard a clock audit as part of understanding the result, not an optional final tweak. This article does not promise that a particular session is profitable or recommend a trading plan. Its purpose is narrower: make the time rule mean the same thing in code, on a chart, in a test, and on the intended broker account.</p>
795
796<h2 id="why-clock-errors-matter">Why a One-Hour Error Changes an EA</h2>
797
798<p>Time is often an input to an EA, not merely a display setting. Many systems use time to decide when to create a range, permit entries, close exposure, reset counters, or ignore volatile calendar events. An hour of drift can therefore alter the data the strategy sees as well as the moment it can trade.</p>
799
800<p>Consider an EA that records the high and low from 00:00 through 07:59, then trades a breakout from 08:00. If its author meant 08:00 London time but the program uses broker time, the measured range shifts whenever the broker clock and London do not align. The range may include a different liquidity period and the entry window may no longer correspond to the intended market activity. Calling this a bad optimization would be misleading. It is a definition mismatch.</p>
801
802<table>
803<thead><tr><th>Schedule feature</th><th>What a clock mismatch can change</th><th>Observable symptom</th></tr></thead>
804<tbody>
805<tr><td>Opening range</td><td>The candles included in the range</td><td>Different levels from the author’s examples</td></tr>
806<tr><td>Session entry gate</td><td>Whether an otherwise valid signal is allowed</td><td>Orders arrive early, late, or not at all</td></tr>
807<tr><td>News pause</td><td>The minutes blocked around an event</td><td>EA trades during the intended pause</td></tr>
808<tr><td>Daily reset</td><td>Which orders belong to a day</td><td>Trade limit or loss counter resets unexpectedly</td></tr>
809<tr><td>Weekend exit</td><td>When positions are closed or disabled</td><td>Exposure remains open beyond the planned cutoff</td></tr>
810</tbody>
811</table>
812
813<p>A useful first rule is this: never describe an EA time setting only as a number. Record the clock that gives the number meaning. “Trade from 08:00 to 11:00 broker time” is testable. “Trade London morning” needs a conversion rule before it can become code. “Use GMT+2” is still incomplete unless it says whether that offset is fixed all year or changes with the broker.</p>
814
815<p>For readers learning how an EA reaches these decisions, the site’s guide to <a href="/blog/how-to-read-recovered-mql4-expert-advisor-code">reading decompiled MQ4 code from EX4</a> can help identify time conditions, variables, and order gates without treating recovered output as a ready-to-run system.</p>
816
817<h2 id="four-clocks">The Four Clocks Around an MT4 Schedule</h2>
818
819<p>A reliable investigation starts by separating clocks that are commonly blended together. They can show the same hour on some days, which is why the problem stays hidden until a seasonal transition or a move to another broker.</p>
820
821<ol>
822<li><strong>Broker server time.</strong>
822 This is the time shown on the MT4 chart and normally associated with server-side market data. It is the most important reference for chart-bar schedules and many EA calls.</li>
823<li><strong>UTC.</strong> Coordinated Universal Time is a stable reference used by many event feeds and cross-broker records. UTC itself does not observe daylight saving time.</li>
824<li><strong>Market-region time.</strong> A strategy description may refer to London, New York, Tokyo, or another region. These civil clocks can move seasonally according to local rules.</li>
825<li><strong>Device or VPS local time.</strong> This is the computer operating system’s time. It may be useful for monitoring, but it is unsafe as an assumed substitute for the broker chart clock.</li>
826</ol>
827
828<p>There can be a fifth input: the tester’s historical environment. A backtest is built from historical bars stamped in the broker’s data convention. If an EA applies a current offset to old data, the test can place a historical session at the wrong market hour. That is why a schedule that looks correct in a current demo can produce confusing historical results.</p>
829
830<p>The names of MQL4 functions matter. <code>TimeCurrent()</code> is the last known server time, typically updated by incoming ticks. <code>TimeLocal()</code> reflects the terminal computer’s local clock. <code>TimeGMT()</code> provides a GMT-oriented value, subject to terminal behavior and connectivity. A program may use any of them, or it may derive time from a bar timestamp. Before changing an input, establish which source the EA actually uses.</p>
831
832<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;">
833<h3 style="margin-top:0;">The clock sentence</h3>
834<p>Write one sentence that every tester can repeat: “This EA forms its range in broker server time, converts the intended London session using the broker’s published seasonal convention, and checks entries only on a new bar.” If that sentence cannot be written, the schedule is not yet defined well enough to validate.</p>
835</div>
836
837<h2 id="build-clock-map">Build a Broker Clock Map Before Editing Code</h2>
838
839<p>Do not begin with an offset copied from a forum. Broker server conventions vary, and the offset may be different across the year. Instead, make a small clock map using observations from the actual terminal and the exact account environment that will be tested. A map is more useful than a remembered difference because it records date, source, and scope.</p>
840
841<h3>Step 1: capture an observed timestamp</h3>
842
843<p>At a known UTC moment, note the time at the right edge of an active MT4 chart. Record the symbol, broker, server name if visible, account type, and date. Then record the matching UTC time from a reliable independent clock. The difference is the observed broker offset for that moment. Do not infer it from the computer taskbar.</p>
844
845<h3>Step 2: repeat across seasonal boundaries</h3>
846
847<p>One observation only proves one date. Capture another around the parts of the year where the relevant market region or broker may change clock convention. The aim is not to predict every broker policy from general principles. It is to identify the convention experienced by this terminal.</p>
848
849<h3>Step 3: state the intended market session</h3>
850
851<p>Specify whether the design is tied to a market city’s civil time, a fixed UTC window, or the broker’s own day. A rollover-focused EA may correctly use broker midnight because its accounting logic follows broker daily bars. A London-open system may be better defined against London civil time. An event filter may be most naturally expressed in UTC. There is no universal best clock.</p>
852
853<h3>Step 4: make the conversion explicit</h3>
854
855<p>For a fixed UTC target, conversion is simple in concept: broker session time equals UTC session time plus the broker offset applicable at that date. For a region-based target, convert the region’s civil time to UTC first, then UTC to broker time. The difficult part is not arithmetic. It is selecting the correct date-specific offsets at both ends.</p>
856
857<table>
858<thead><tr><th>
858Map field</th><th>Example entry</th><th>Why it matters</th></tr></thead>
859<tbody>
860<tr><td>Observation date</td><td>2026-09-07</td><td>Offsets are date dependent</td></tr>
861<tr><td>Broker chart time</td><td>14:15</td><td>Defines the terminal reference</td></tr>
862<tr><td>Matching UTC</td><td>11:15</td><td>Allows an observed offset</td></tr>
863<tr><td>Intended session basis</td><td>London civil time</td><td>States what the strategy means</td></tr>
864<tr><td>EA time source</td><td>TimeCurrent on new tick</td><td>Shows which clock code reads</td></tr>
865<tr><td>Review owner</td><td>Tester name and date</td><td>Makes future troubleshooting easier</td></tr>
866</tbody>
867</table>
868
869<p>Use the map to challenge assumptions. If the chart says 10:00 when UTC is 08:00, a parameter called “LondonStart=08” is not automatically correct or incorrect. Its meaning depends on whether the EA expects broker hours, UTC hours, or an internal conversion. Changing it blindly can move a schedule twice.</p>
870
871<h2 id="session-design">Design Sessions as Windows, Not Magic Hours</h2>
872
873<p>A robust schedule has a start, an end, a basis, and boundary behavior. A vague pair of inputs such as StartHour and EndHour tells little about the intended implementation. A clear design also answers whether the interval includes its first minute, whether it crosses midnight, and what happens if no tick arrives exactly at the boundary.</p>
874
875<p>For example, define a session as: permit new entries from 08:00:00 inclusive until 10:59:59 inclusive in broker time, check the gate when a signal is evaluated, and manage existing orders outside the window according to separate exit rules. That avoids an accidental interpretation that all EA actions must stop at 11:00.</p>
876
877<h3>Use a session specification sheet</h3>
878
879<ul>
880<li>Name the session by purpose, such as “London range build” or “pre-weekend entry stop.”</li>
881<li>State its reference clock and whether it tracks a civil market clock or fixed UTC.</li>
882<li>Write the start and end including whether each boundary is included.</li>
883<li>State whether an overnight window such as 22:00 to 02:00 is valid.</li>
884<li>Separate new-entry permission from order management, trailing, and emergency exits.</li>
885<li>List holidays, early closes, and calendar pauses as separate controls rather than hidden hour exceptions.</li>
886</ul>
887
888<p>Overnight windows deserve a direct test. A simple condition that checks whether <code>hour &gt;= start &amp;&amp; hour &lt; end</code> works when start is 08 and end is 12. It fails for a 22:00 to 02:00 session because no hour can be both at least 22 and less than 2. In that case, the logical condition usually needs an OR relationship, and the definition needs to say which broker date owns the after-midnight portion.</p>
889
890<p>A separate issue is tick dependence. An EA that evaluates <code>TimeCurrent()</code> only in <code>OnTick()</code> cannot act at an exact boundary if no tick arrives then. For a liquid symbol this may be a small delay, but it should still be understood. For quiet symbols, market pauses, or a terminal without a connection, the delay can be more visible. A timer-driven design may be appropriate for some monitoring tasks, yet it should be tested carefully in the target terminal rather than assumed to solve every timing issue.</p>
891
892<h2 id="mql4-time-functions">MQL4 Time Functions and Common Traps</h2>
893
894<p>Time bugs often come from plausible code. The following review questions are more useful than memorizing one preferred function.</p>
895
896<table>
897<thead><tr><th>Question</th><th>What to inspect</th><th>Potential correction</th></tr></thead>
898<tbody>
899<tr><td>What clock drives entry gating?</td><td>TimeCurrent, TimeLocal, bar time, or input offset</td><td>Align inputs and documentation to that source</td></tr>
900<tr><td>When is it evaluated?</td><td>Every tick, new bar, timer, or order event</td><td>Test behavior at sparse-tick boundaries</td></tr>
901<tr><td>How is day of week obtained?</td><td>Server timestamp versus local timestamp</td><td>Use the same basis as the session rule</td></tr>
902<tr><td>What resets a counter?</td><td>Calendar date, broker midnight, or first tick</td><td>Make reset conditions observable in logs</td></tr>
903<tr><td>Where is the offset stored?</td><td>Hard-coded constant, input, or calculation</td><td>Document seasonal maintenance responsibility</td></tr>
904</tbody>
905</table>
906
907<p>A common trap is extracting only the hour. Hour-only logic can be sufficient for an all-hour window, but it cannot express a 08:30 start, a five-minute event buffer, or a precise cutoff. Another trap is calculating the broker offset from local computer time. That makes an EA portable only by accident: the same set file can behave differently on a VPS in another location.</p>
908
909<p>Hard-coded offsets are not inherently wrong. They can be appropriate in a controlled environment where a tested release is maintained for a known server convention. The risk arises when the number is undocumented or described as a market time. A visible input named <code>BrokerUtcOffset</code>, a note saying who updates it, and a test date are safer than a mysterious addition buried in an expression.</p>
910
911<p>When reviewing an unfamiliar robot, search for <code>TimeCurrent</code>, <code>TimeLocal</code>, <code>TimeGMT</code>, <code>TimeHour</code>, <code>TimeDayOfWeek</code>, <code>iTime</code>, and inputs containing hour, session, GMT, UTC, start, end, Friday, or rollover. Also inspect conditions that compare a timestamp to a constant. Time logic is often split between initialization, signal functions, and trade-management code.</p>
912
913<h2 id="seasonal-changes">
913DST and Broker Offset Changes</h2>
914
915<p>Daylight saving time is not a programming detail to wave away. Market regions may change clocks on different dates, and broker server policies may follow a different convention. During the weeks when one clock has moved and another has not, a formerly correct fixed offset can be wrong by an hour. The exact behavior should be checked against the broker and the chosen session basis, not guessed from a calendar label.</p>
916
917<p>There are two defensible approaches. First, define the strategy in broker server time and accept that its relationship to a named market session may shift if the broker changes convention. This is often simplest for systems built around broker daily candles. Second, define the strategy against UTC or a market-region clock and implement a date-aware conversion process. This is closer to the intended session but requires deliberate maintenance and historical testing.</p>
918
919<p>The dangerous middle ground is claiming a strategy follows London or New York while leaving an old fixed offset unexplained. A schedule note should identify the owner of the seasonal check. It can be a developer, a tester, or an automated routine that has itself been validated. No one should discover the responsibility after an unexpected order.</p>
920
921<h3>Seasonal review checklist</h3>
922
923<ol>
924<li>Check the broker chart offset against UTC on the review date.</li>
925<li>Confirm whether the target market session uses a seasonal civil clock or fixed UTC.</li>
926<li>Review the EA’s offset input, conversion code, and comments.</li>
927<li>Use historical chart dates around relevant clock changes to inspect session placement.</li>
928<li>Record the result and schedule the next review before a known transition period.</li>
929</ol>
930
931<h2 id="testing-workflow">A Repeatable Testing Workflow</h2>
932
933<p>Timing validation is not complete when an EA places one expected trade. It needs evidence that it refuses trades outside the window and preserves the same intended meaning across representative dates. Start in a controlled environment and use a harmless diagnostic mode if the EA supports it. The goal is to observe decisions, not chase performance.</p>
934
935<h3>1. Make the schedule visible</h3>
936
937<p>Log the server timestamp, UTC reference if calculated, current offset, session state, and reason for a blocked or allowed entry. A log line such as “server 08:30, session OPEN” is helpful. A more useful line says which session definition opened and which time basis was used. If source changes are available, avoid logging sensitive account information and make logging switchable.</p>
938
939<h3>2. Test boundaries deliberately</h3>
940
941<p>Create test cases one minute before the start, exactly at the start where possible, one minute after, one minute before the end, and immediately after the end. Test an overnight window separately. Verify that a signal is handled as designed at each point. Boundary tests catch more schedule defects than a long, unstructured run.</p>
942
943<h3>3. Compare terminal, journal, and chart</h3>
944
945<p>When an order appears, compare the order timestamp, the chart bar, and the EA log. They should tell a coherent story using the same broker-time basis. If a third-party news calendar is involved, annotate its published time basis before comparing it with the terminal.</p>
946
947<h3>4. Use historical dates with purpose</h3>
948
949<p>Pick dates before, during, and after a relevant seasonal transition. Check whether the intended session is attached to the same market period rather than merely the same broker hour. Historical data quality, symbol-specific trading breaks, and tester modeling settings can affect conclusions, so record them alongside results.</p>
950
951<p>This process complements, rather than replaces, broader validation. The article on <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating recovered MQL4 before live deployment</a> covers additional checks for compilation, dependencies, and controlled testing after code recovery.</p>
952
953<h2 id="failure-patterns">Schedule Failures and Their Fixes</h2>
954
955<h3>The EA trades one hour early after a clock change</h3>
956<p>First, compare current broker server time to UTC and confirm whether the desired session follows a civil market clock. Then inspect whether a fixed offset is used. The repair may be an input adjustment, a date-aware conversion, or a revised specification. Do not “fix” it by changing both the offset and the session start without tracing the existing conversion.</p>
957
958<h3>The EA works on a home computer but not a VPS</h3>
959<p>Look for <code>TimeLocal()</code> or local-time assumptions. A VPS in a different time zone can expose this immediately. Where the strategy is meant to follow broker 
959charts, using a server-oriented source is often more predictable. Any change should be backtested and observed because a time-source swap can affect more than entry gating.</p>
960
961<h3>The Friday cutoff misses open orders</h3>
962<p>Determine whether the cutoff controls only new entries or also manages existing positions. Then inspect day-of-week and hour checks against server time. A condition evaluated only on ticks may not fire at the expected minute if the symbol is inactive. Define the desired fallback behavior explicitly rather than assuming the next tick is close enough.</p>
963
964<h3>The backtest and forward test disagree</h3>
965<p>Check the historical broker timestamps, the EA’s offset logic, and the dates used. A current offset applied to an earlier period can shift the tested session. Also ensure the same symbol suffix, spread assumptions, and test settings are not being mistaken for a time issue. Isolate one variable at a time.</p>
966
967<h2 id="recovered-eas">When a Recovered EA Has Hidden Time Assumptions</h2>
968
969<p>Time review is particularly important when source has been recovered from an EX4 or inherited without documentation. Variable names may be generic, comments may be absent, and a simple numeric constant may represent an offset, a session start, or a broker-specific workaround. Recovered code should be treated as evidence to inspect, not as proof of the original author’s intent.</p>
970
971<p>A careful reviewer can build a behavior map: list every time input and function, trace each condition to the action it gates, then compare that behavior with chart examples and available vendor material. Preserve the original file and test on copies. If the requester has legitimate rights to inspect the code, the <a href="/">mql4 decompiler</a> topic is only the beginning of the work. Understanding the result, documenting assumptions, and validating it in the correct terminal environment matter just as much.</p>
972
973<p>For a legitimate source-recovery or maintenance need, this review site describes ForexMQ5 as a professional option to consider. Their team’s output should still be checked for schedule assumptions, broker dependencies, and safe test behavior before any production use.</p>
974
975<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
976<h3 style="margin-top:0;">Need a Professional Recovery Option?</h3>
977<p>Readers with documented rights to a custom EA can evaluate the professional recovery service at ForexMQ5, then use a structured clock review before relying on any recovered schedule.</p>
978<a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
979</div>
980
981<h2 id="deployment-checklist">Deployment Checklist</h2>
982
983<ul>
984<li>Confirm the exact broker server time and matching UTC time on the target account.</li>
985<li>Write whether each session is based on broker time, UTC, or a named market-region clock.</li>
986<li>Document each start, end, inclusion rule, and overnight case.</li>
987<li>Identify the MQL4 time source and when the EA evaluates it.</li>
988<li>Test entry, exit, reset, and news-pause boundaries in a controlled environment.</li>
989<li>Review dates around seasonal changes and record the observed result.</li>
990<li>Check whether VPS local time can influence the program.</li>
991<li>Keep a dated clock map with broker, account, symbol, and tester details.</li>
992<li>Do not treat a single favorable backtest as proof that a schedule is correctly aligned.</li>
993<li>Review risk controls independently before any live use.</li>
994</ul>
995
996<h2 id="conclusion">Conclusion</h2>
997
998<p>Broker server time is part of an EA’s operating environment. It determines where chart bars begin, how many time functions are interpreted, and when a session gate can act. The dependable solution is not to memorize a popular GMT offset. It is to identify every relevant clock, declare the intended session basis, map the broker’s observed convention, and test boundaries across dates that can expose a mismatch.</p>
999
1000<p>That discipline also makes maintenance easier. A future tester can see why a parameter exists, who checked it, and what should happen when clocks change. Whether an EA is newly developed, purchased under appropriate rights, or being reviewed after legitimate source recovery, a synchronized clock model turns an ambiguous schedule into a testable engineering requirement.</p>
1001`},{slug:"mt4-four-digit-five-digit-broker-ea",title:"4-Digit vs 5-Digit Brokers: Make MT4 Expert Advisors Calculate Pips Correctly",metaTitle:"4-Digit vs 5-Digit Brokers: MT4 EA Pip Calculation Guide",metaDescription:"Learn why MT4 Expert Advisors fail on 4-digit and 5-digit quotes, how Point, Digits, pip size and stop levels interact, and how to test a safer MQL4 conversion.",keywords:"4 digit vs 5 digit broker, MT4 EA pip calculation, MQL4 Point Digits, Expert Advisor pip conversion, five digit forex quotes, MT4 stop loss calculation",excerpt:"A robot that treats every price point as one pip can place stops ten times too close on a five-digit MT4 broker. This practical guide explains quote precision, conversion patterns, audit checks, and controlled testing.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:pu,imageAlt:"magnified forex price quote beside a calculator and MT4 trading robot",tableOfContents:[{id:"why-precision-matters",title:"Why Quote Precision Matters to an EA"},{id:"read-the-quote",title:"Reading 4-Digit, 5-Digit, 3-Digit, and 2-Digit Quotes"},{id:"separate-terms",title:"Separate Pip, Point, Tick, and Price"},{id:"where-errors-appear",title:"Where Precision Errors Appear in MQL4"},{id:"conversion-pattern",title:"A Safer Pip Conversion Pattern"},{id:"worked-examples",title:"Worked Price and Risk Examples"},{id:"broker-constraints",title:"Broker Constraints Beyond Digits"},{id:"audit-recovered-code",title:"Auditing Recovered or Older EA Code"},{id:"test-plan",title:"A Controlled MT4 Test Plan"},{id:"decision-path",title:"Decision Path for Owners and Buyers"},{id:"conclusion",title:"Conclusion: Make Units Explicit"}],content:`
1002<p>A price chart can make a four digit and five digit broker look almost identical. Both may show EURUSD moving through familiar levels, both may accept an MT4 Expert Advisor, and both may describe a stop as 20 pips. Under the surface, however, the platform can expose prices in different increments. A robot that confuses that increment with a pip can calculate every stop loss, take profit, trailing distance, grid interval, and slippage limit at the wrong scale.</p>
1003
1004<p>The classic failure is simple. An EA was written when EURUSD commonly appeared as 1.2345. It uses <strong>Point</strong> as though it represents one pip. The same EA is installed where the quote is 1.23456. Point is now one tenth of a conventional pip, so a requested 20 pip stop becomes 2 pips. Orders can be rejected, positions can close almost immediately, or a strategy can behave unlike its test report. The reverse mistake makes a 20 pip instruction become 200 pips, which may be even harder to notice until a trade is already open.</p>
1005
1006<p>This guide is educational and focuses on unit handling in MQL4. It does not predict trading results or tell a reader what risk is appropriate. Its purpose is to help an EA owner identify whether a program is calculating in pips, points, ticks, or raw price correctly before relying on it. That matters especially when source has been recovered, inherited, or obtained with an older robot. An <a href="/">ex4 to mq4 decompiler</a> can make an older program readable for an authorized maintenance review, but readable code still needs this kind of unit audit.</p>
1007
1008<img src="${pu}" alt="magnified forex quote showing decimal precision with a calculator and automated trading robot" style="width:100%;border-radius:8px;margin:24px 0;" />
1009
1010<h2 id="why-precision-matters">Why Quote Precision Matters to an EA</h2>
1011
1012<p>MT4 stores and trades price values, not human labels such as “a modest stop.” The terminal supplies a symbol price, a smallest quoted increment, and a digit count. An EA transforms its input parameters into price distances, then sends those distances to the trade server. Each transformation must use the intended unit. A parameter named StopLoss=30 does not explain whether 30 means pips, points, price units, or something else. The author’s conversion code supplies that meaning.</p>
1013
1014<p>Precision affects more than protective orders. A breakout EA might require price to move 15 pips before entering. A mean reversion robot might add an order every 25 pips. A spread filter might refuse new trades above 2 pips. A trailing stop might move by 1 pip after a 10 pip gain. If a tenfold conversion error reaches any of these conditions, the strategy logic changes, even when every order is technically accepted.</p>
1015
1016<p>It is tempting to call this a broker issue. Usually it is a portability issue in the EA. The broker is entitled to quote its symbol with the precision it supports. Robust code asks the terminal what it is dealing with and converts a user facing pip parameter consistently. A careful source review is often more productive than changing every input by a factor of ten, because manual input adjustments can fix one feature while breaking another.</p>
1017
1018<p>For a wider check of nonstandard symbol naming and suffixes, readers can compare this problem with the site’s guide to <a href="/blog/mt4-ea-broker-symbol-name-mismatch-fix">MT4 EA broker symbol name mismatches</a>. Symbol names and quote precision are different issues, but both show why an EA should discover its trading environment rather than assume one broker’s conventions.</p>
1019
1020<h2 id="read-the-quote">Reading 4-Digit, 5-Digit, 3-Digit, and 2-Digit Quotes</h2>
1021
1022<p>For many non JPY currency pairs, a traditional four digit quote might show EURUSD at 1.2345. The last decimal place is commonly called one pip, so a move from 1.2345 to 1.2346 is one pip. A five digit quote might show 1.23456. Its final decimal place is usually a fractional pip, often called a pipette. A move of one pip is 0.00010, which contains ten five digit points of 0.00001 each.</p>
1023
1024<p>JPY pairs need separate attention because their conventional pip is normally at the second decimal place. A two digit USDJPY quote at 156.78 has a pip size of 0.01. A three digit quote at 156.789 has a point size of 0.001 and still has a pip size of 0.01. Therefore the same broad pattern applies, but the raw numbers differ. Hard coding 0.0001 as a universal pip is wrong for JPY pairs and can be wrong for other instruments too.</p>
1025
1026<table>
1027  <thead><tr><th>
1027Example symbol</th><th>Displayed quote</th><th>Digits</th><th>Point</th><th>Typical pip size</th><th>Points per pip</th></tr></thead>
1028  <tbody>
1029    <tr><td>EURUSD, traditional</td><td>1.2345</td><td>4</td><td>0.0001</td><td>0.0001</td><td>1</td></tr>
1030    <tr><td>EURUSD, fractional</td><td>1.23456</td><td>5</td><td>0.00001</td><td>0.0001</td><td>10</td></tr>
1031    <tr><td>USDJPY, traditional</td><td>156.78</td><td>2</td><td>0.01</td><td>0.01</td><td>1</td></tr>
1032    <tr><td>USDJPY, fractional</td><td>156.789</td><td>3</td><td>0.001</td><td>0.01</td><td>10</td></tr>
1033  </tbody>
1034</table>
1035
1036<p>The word “typical” is deliberate. Forex pairs fit these conventions more often than many CFDs, metals, indices, energies, and cryptocurrencies. A gold symbol may have two or three digits, yet its commercially meaningful price increment need not map cleanly to the forex pip convention. An EA that trades more than major currency pairs should rely on a documented instrument specific definition, not a digit rule copied from EURUSD.</p>
1037
1038<h2 id="separate-terms">Separate Pip, Point, Tick, and Price</h2>
1039
1040<p>Confusing vocabulary is the source of many coding mistakes. In MT4, <strong>Point</strong> is normally the smallest price change represented by the quote. The predefined <strong>Digits</strong> value indicates decimal precision for the current chart symbol. A pip is a market convention used to express a larger, trader friendly price distance. For five digit non JPY forex quotes and three digit JPY quotes, one conventional pip equals ten points.</p>
1041
1042<p>A tick is not always identical to a point. For a particular symbol, the server can define a minimum trade price change or tick size that requires separate inspection. Contract size, tick value, lot step, and margin currency are separate concepts again. A program can calculate a stop distance in pips correctly and still estimate monetary risk poorly if it assumes every symbol has the same tick value. Keep price distance conversion and cash risk conversion as two visible, independently checked steps.</p>
1043
1044<p>Raw price is the final unit sent to order functions. Suppose Ask is 1.23456 and a buy order needs a 25 pip protective stop. The intended raw price distance is 25 multiplied by 0.00010, or 0.00250. The stop price is 1.23206 before normalization and broker rule checks. Multiplying 25 by Point on this five digit quote yields 0.00025, only 2.5 pips. The arithmetic is valid, but it answers a different question.</p>
1045
1046<p>The useful discipline is to name variables for their units. pipDistance, pointDistance, priceDistance, entryPrice, and stopPrice communicate intent. Names such as distance, level, p, or x force a later reviewer to reconstruct intent from context. That is risky in trade management code where one multiplication can materially alter behavior.</p>
1047
1048<h2 id="where-errors-appear">Where Precision Errors Appear in MQL4</h2>
1049
1050<p>Start by examining inputs. Inputs labelled Stop Loss, Take Profit, Trailing Stop, Break Even, Grid Step, Max Spread, and Slippage deserve attention. Their labels may say pips while the code uses them directly with Point. Conversely, an input may intentionally be in points but presented to a user as pips. Neither design is automatically broken, but input text, conversion code, and user documentation must agree.</p>
1051
1052<p>Next, search every multiplication and division involving Point, Digits, MarketInfo, and NormalizeDouble. A common legacy line resembles stop = Ask - StopLoss * Point. It is safe only if StopLoss is meant to be points. If a settings panel says 20 pips, it is only safe on a symbol where a pip equals Point. Similar patterns hide in pending order offsets, trailing conditions, spread comparisons, and error recovery that retries an order at a changed price.</p>
1053
1054<p>Spread is a frequent trap. In MQL4, MODE_SPREAD is commonly returned in points. A value of 18 on a five digit EURUSD quote represents 1.8 conventional pips, not 18 pips. A filter written as if the return were pips can reject normal conditions or permit spreads far above the intended cap. Display both the raw point value and the converted pip value in test logs, so a reviewer can see which one the EA uses.</p>
1055
1056<p>Slippage parameters also need a broker aware interpretation. Many MT4 order 
1056calls receive slippage in points. An author may expose a setting described as “maximum slippage in pips,” then pass it directly to OrderSend. On five digit quotes that grants one tenth of the expected price tolerance. This can look like a strategy that “cannot enter” when it is really an input unit mismatch.</p>
1057
1058<h2 id="conversion-pattern">A Safer Pip Conversion Pattern</h2>
1059
1060<p>A straightforward pattern is to calculate a pip size once for the active symbol, then use that value for all forex pip inputs. For the common MT4 convention, five or three digits indicate a fractional pip quote, so the pip size is Point multiplied by 10. Otherwise it is Point. The code should be initialized after selecting the correct symbol and refreshed if the EA can trade symbols with different properties.</p>
1061
1062<pre><code>double PipSize(string symbol) {
1063   int digits = (int)MarketInfo(symbol, MODE_DIGITS);
1064   double point = MarketInfo(symbol, MODE_POINT);
1065   if (digits == 3 || digits == 5) return point * 10.0;
1066   return point;
1067}
1068
1069double PriceDistanceFromPips(string symbol, double pips) {
1070   return pips * PipSize(symbol);
1071}</code></pre>
1072
1073<p>This pattern is deliberately modest. It makes the common four digit, five digit, two digit, and three digit forex cases explicit. It does not declare that every instrument uses a forex pip. If an EA trades XAUUSD, US30, or a broker specific synthetic symbol, its specification should say what a “pip” means for that instrument. In some designs, it is clearer to expose inputs as ticks or absolute price distance rather than attach a misleading pip label.</p>
1074
1075<p>For a buy position, the broad sequence is: read the current executable price, convert the requested pip distance to a raw price distance, subtract for a stop or add for a target, normalize to the symbol digits, and validate the result against server constraints. For a sell position, the directions reverse. Keeping these stages separate is easier to audit than combining everything into one long expression.</p>
1076
1077<p>NormalizeDouble is useful for formatting a calculated price to the symbol precision, but it is not a repair tool for a wrong distance. Rounding 1.23431 to five digits will not turn a 2.5 pip stop into 25 pips. Nor does normalization guarantee a valid order. The server can still reject a level that sits too close to price or violates a freeze zone.</p>
1078
1079<h2 id="worked-examples">Worked Price and Risk Examples</h2>
1080
1081<h3>Example 1: EURUSD stop calculation</h3>
1082<p>Assume Ask is 1.08642 on a five digit quote. A buy configuration requests a 30 pip stop. Point is 0.00001 and the pip size is 0.00010. The price distance is 30 multiplied by 0.00010, or 0.00300. The initial stop price is 1.08342. A legacy calculation of 30 multiplied by Point gives 0.00030 and a stop at 1.08612, only 3 pips away. The latter may be inside a broker minimum or may close from ordinary price movement.</p>
1083
1084<h3>Example 2: USDJPY trailing logic</h3>
1085<p>Assume a three digit USDJPY quote and a requested 12 pip trailing distance. Point is 0.001, while the normal pip size is 0.01. The price distance should be 0.12. If a trailing routine compares current price with open price plus 12 times Point, it begins managing after 0.012, or 1.2 pips, and sets a much tighter trail than the settings suggest. The code should use the same conversion helper for the activation threshold and the trail distance.</p>
1086
1087<h3>
1087Example 3: cash risk is not a pip conversion</h3>
1088<p>A trader might set an EA to risk a defined currency amount. The program first needs the stop distance in raw price terms, then needs symbol specific information to estimate the value of that movement at the chosen volume. Contract characteristics and account currency can affect the estimate. Do not assume a familiar value per pip from EURUSD applies to every pair, account, or CFD. A prudent review compares the EA’s estimate with terminal values and uses a demo or test environment before any live reliance.</p>
1089
1090<h2 id="broker-constraints">Broker Constraints Beyond Digits</h2>
1091
1092<p>Digits solve only one part of order validity. MT4 servers may impose a stop level, a freeze level, minimum and maximum lot sizes, a lot step, trading session restrictions, and changing spreads. MODE_STOPLEVEL indicates a minimum distance in points in many MT4 environments. If an EA asks for a 3 pip stop on a five digit symbol with a 50 point minimum, the calculated level must be at least 5 pips away before other conditions are considered.</p>
1093
1094<p>A zero stop level is not a promise that every distance will be accepted. Some environments use dynamic restrictions that the terminal cannot fully express before an order attempt. The EA should handle returned trade errors transparently, log the proposed prices and distances, and avoid endlessly retrying a bad request. Moving a stop farther away as an automatic fallback changes the strategy, so that behavior should be documented and deliberately chosen.</p>
1095
1096<p>Bid and Ask are another source of apparent precision defects. A buy opens at Ask and a sell opens at Bid, while a chart may visually emphasize Bid. Stop and target distances should be measured from the relevant execution side. A 20 pip buy target can look short on a Bid chart by approximately the spread, even when the arithmetic is correct. Testers should distinguish a quote side issue from a digit conversion issue before editing code.</p>
1097
1098<h2 id="audit-recovered-code">Auditing Recovered or Older EA Code</h2>
1099
1100<p>Recovered MQL4 can preserve the broad behavior of an EX4 but may need cleanup, naming, and validation. A reviewer should not assume that readable output is automatically maintainable source. If the goal is to verify whether a robot handles broker precision, build a short audit sheet and trace every price distance from input to order function.</p>
1101
1102<ul>
1103  <li>Record each user facing distance input and its stated unit.</li>
1104  <li>Find every Point, Digits, MODE_POINT, and MODE_SPREAD reference.</li>
1105  <li>Trace stop, target, trailing, grid, breakeven, and slippage calculations separately.</li>
1106  <li>Check whether the active chart symbol differs from the symbol sent to orders.</li>
1107  <li>Confirm that the correct Bid or Ask side is used at entry and modification.</li>
1108  <li>Log raw points, calculated pips, price distances, and final normalized prices.</li>
1109  <li>Inspect error handling for invalid stops and repeated order attempts.</li>
1110</ul>
1111
1112<p>Readers assessing what recovered source can and cannot reveal may also find the explanation of <a href="/blog/how-to-read-decompiled-mq4-code-from-ex4">how to read decompiled MQ4 code from an EX4</a> useful. It provides a complementary code reading framework. Precision inspection is one concrete task within that broader review, not proof that all logic or intent has been recovered perfectly.</p>
1113
1114<p>Where a legitimate owner has lost source and wants a professionally handled recovery route, this independent review site treats the service at ForexMQ5 as an option to evaluate. The owner should retain evidence of ownership or authorization and define maintenance goals before requesting any work.</p>
1115
1116<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
1117  <h3 style="margin-top:0;">Need Source for a Documented EA Maintenance Review?</h3>
1118  <p>ForexMQ5 is reviewed as a professional recovery option for owners with a legitimate, documented reason to inspect and maintain an EX4 based project.</p>
1119  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
1120</div>
1121
1122<h2 id="test-plan">A Controlled MT4 Test Plan</h2>
1123
1124<p>Do not begin by changing live inputs. First preserve the original EX4, the recovered or edited source, compiler version, terminal build, symbol specification, and settings file. Compile a named test build so a result can be traced back to a specific change. Then use a demo or controlled environment with no assumption that a historical test guarantees future performance.</p>
1125
1126<ol>
1127  <li><strong>Print environment values.</strong> Log Symbol, Digits, Point, Bid, Ask, spread in points, and the calculated pip size when the EA initializes.</li>
1128  <li><strong>Test one fixed trade setup.</strong> Use a visible stop and target such as 10 and 20 pips. Record the entry price, proposed levels, actual accepted levels, and their differences in raw price.</li>
1129  <li><strong>Repeat on alternate precision.</strong> Where available, run the identical logic on a four digit or two digit quote and a five digit or three digit quote. Equivalent pip settings should produce equivalent pip distances.</li>
1130  <li><strong>Exercise each management branch.</strong> Trigger trailing, breakeven, pending order placement, spread filtering, and modification. A repaired entry calculation does not repair hidden management logic.</li>
1131  <li><strong>Test broker boundaries.</strong> Deliberately request a level close to the minimum distance in a safe environment. Confirm that the EA reports a clear reason rather than silently placing a materially different order.</li>
1132  <li><strong>Review the journal and code together.</strong> Compare logs with the formula. If the final order is wrong, locate the first stage where the unit changed, rather than applying a factor of ten at random.</li>
1133</ol>
1134
1135<p>A compact test table can prevent confusion:</p>
1136<table>
1137  <thead><tr><th>Check</th><th>Expected result on 5 digits</th><th>Failure signal</th></tr></thead>
1138  <tbody>
1139    <tr><td>20 pip stop</td><td>Distance equals 0.00200 on EURUSD</td><td>Distance equals 0.00020</td></tr>
1140    <tr><td>2 pip spread cap</td><td>Compares against 20 points</td><td>Compares against 2 points</td></tr>
1141    <tr><td>10 pip trail</td><td>Uses 0.00100 distance on EURUSD</td><td>Moves after 1 pip</td></tr>
1142    <tr><td>Price formatting</td><td>Final level has symbol digit precision</td><td>Unnormalized or rejected level</td></tr>
1143  </tbody>
1144</table>
1145
1146<p>Backtests can help expose a conversion error, but their modeling, data quality, spread assumptions, and order simulation need scrutiny. A seemingly exceptional result from a tight accidental stop is not evidence of a sound strategy. The site’s general <a href="/">EA decompiler software</a> review context also emphasizes treating recovered code as a starting point for verification, not an immediate production deployment.</p>
1147
1148<h2 id="decision-path">Decision Path for Owners and Buyers</h2>
1149
1150<p>Use this decision sequence when an EA behaves differently after moving brokers. First, identify the actual traded symbol and print its digits and point. Second, calculate one known pip distance by hand from the live quote. Third, inspect whether the EA defines a pip size or uses Point directly. Fourth, check stops, targets, spread, trailing, and slippage independently. Fifth, review broker stop and freeze constraints. Only after those checks should an owner modify code or inputs.</p>
1151
1152<p>If source is available, the cleanest repair is usually a small, documented conversion helper plus a test pass that replaces inconsistent calculations. If only an EX4 exists, the owner should first confirm authorization and decide whether source recovery is proportionate to the maintenance need. A buyer who lacks rights to inspect or alter vendor code should ask the vendor for a compatible build or documented broker settings rather than attempting to bypass restrictions.</p>
1153
1154<p>When evaluating an older product, ask the vendor or developer precise questions: Does every distance input use pips or points? Is the answer different for JPY pairs? Does the EA trade metals or indices? How does it calculate spread? What happens when the server rejects a stop? Specific answers and a controlled test are more useful than a generic statement that the robot works with all brokers.</p>
1155
1156<h2 id="conclusion">Conclusion: Make Units Explicit</h2>
1157
1158<p>Four digit and five digit pricing does not have to make an MT4 EA fragile. The essential rule is that Point describes quote resolution, while a conventional pip may be larger. For common five digit non JPY and three digit JPY forex quotes, one pip is generally ten points. Convert user facing pip settings once into a raw price distance, use the correct execution side, normalize final prices, and then respect broker constraints.</p>
1159
1160<p>The strongest safeguard is not a magic multiplier. It is explicit units, descriptive variables, logs that show each conversion, and a controlled comparison across quote precisions. That approach helps an owner distinguish a true strategy problem from an arithmetic portability problem, and it gives any future maintainer a clear basis for checking the robot safely.</p>
1161`},{slug:"mt4-ea-spread-slippage-risk-review",title:"MT4 EA Spread and Slippage Review: Protect Automated Entries From Bad Execution",metaTitle:"MT4 EA Spread and Slippage Review: Safer Automated Entries",metaDescription:"A practical review of MT4 EA spread and slippage controls. Learn how to inspect execution logic, test poor fills, and set sensible safeguards before automated trading.",keywords:"MT4 EA spread filter review, MT4 slippage protection, automated forex execution risk, Expert Advisor spread control, MQL4 order entry safeguards",excerpt:"A profitable entry rule can be undermined between signal and fill. This review explains how MT4 EAs should measure spread, handle slippage, respond to rejection, and be tested under difficult execution conditions.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:mu,imageAlt:"MT4 Expert Advisor order passing through a narrowing execution channel with a spread gauge and risk shield",tableOfContents:[{id:"execution-channel",title:"The Narrowing Channel Between Signal and Fill"},{id:"spread-basics",title:"What a Spread Control Actually Measures"},{id:"slippage-basics",title:"Slippage Is a Fill Problem, Not a Setting Alone"},{id:"review-framework",title:"A Review Framework for MT4 Entry Protection"},{id:"mql4-logic",title:"Practical MQL4 Logic to Inspect"},{id:"failure-modes",title:"Failure Modes That Defeat Good Intentions"},{id:"testing-plan",title:"A Test Plan for Bad Execution"},{id:"decision-steps",title:"Decision Steps Before Enabling an EA"},{id:"recovery-audit",title:"Why Recovered Code Can Need an Execution Audit"},{id:"conclusion",title:"Conclusion: Make Entry Quality Observable"}],content:`
1162<p>An automated strategy does not enter a trade when its indicator crosses a line. It enters only when an order request reaches a broker, a quote remains available, and the broker returns a fill. That interval can be short, but it is a narrowing execution channel. A calm market can leave room for a modest spread and a near requested price. During a rollover, a session change, a data release, or a thin market, the same channel may become restrictive. Quotes can change, spreads can expand, and an otherwise valid signal can become an expensive entry.</p>
1163
1164<p>This is where a spread gauge and a risk shield belong in an MT4 Expert Advisor. The gauge observes the cost visible before sending an order. The shield decides whether the current conditions justify an attempt, how the program reacts if price moves, and when it should stand aside. Neither device guarantees a favorable result. They do make the EA's assumptions visible and testable, which is more useful than treating execution as a harmless detail.</p>
1165
1166<img src="${mu}" alt="MT4 automated order moving through a narrow execution channel with spread gauge and risk shield" style="width:100%;border-radius:8px;margin:24px 0;" />
1167
1168<p>This independent review looks at the controls worth seeking in an EA that opens market orders on MetaTrader 4. It is not a promise about any broker, symbol, or strategy. Execution depends on the account type, liquidity, connection, broker rules, market conditions, and the exact code. Readers considering an <a href="/">mt4 ea decompiler</a> to inspect a robot they are entitled to examine should focus on whether the program protects its own entry assumptions rather than merely displaying attractive historical results.</p>
1169
1170<h2 id="execution-channel">The Narrowing Channel Between Signal and Fill</h2>
1171
1172<p>It helps to separate three events that are often compressed into the word “entry.” First, the EA evaluates a signal from completed or current price data. Second, it reads a tradable quote and decides whether conditions meet its limits. Third, it submits an order and receives a response. The first event belongs to strategy logic. The latter two belong to execution logic. A strategy may be coherent at the first stage yet fail to produce comparable live trades if the latter stages are ignored.</p>
1173
1174<p>For a buy order, the relevant immediate price is generally Ask. For a sell order, it is generally Bid. The difference is the spread. A buy begins with that cost already embedded because a position bought at Ask would normally be valued against Bid. The EA may calculate a signal from Bid based chart data, then pay Ask when it acts. That difference is ordinary market mechanics, not necessarily a broker error. The question is whether the strategy's expected move is large enough to tolerate it.</p>
1175
1176<p>Slippage is different. It is the difference between the price sought by the order and the price at which it is filled, if a fill occurs. In MT4, requested price, allowed deviation, execution model, quote updates, and server rules all influence what happens. An allowed slippage parameter is not a force field around price. It is part of a request, and the response can still be a fill, a requote, an off quotes condition, an invali
1176d price error, or another failure path.</p>
1177
1178<table>
1179<thead><tr><th>Stage</th><th>Useful question</th><th>Control an EA can use</th></tr></thead>
1180<tbody>
1181<tr><td>Signal</td><td>Is a new trade genuinely indicated?</td><td>Bar, indicator, position, and session checks</td></tr>
1182<tr><td>Preflight quote</td><td>Is the visible spread acceptable now?</td><td>Maximum spread in normalized points</td></tr>
1183<tr><td>Order request</td><td>How much price movement can this setup tolerate?</td><td>Defined deviation and refreshed prices</td></tr>
1184<tr><td>Server response</td><td>What happens if the request fails or fills late?</td><td>Error handling, bounded retry, logging</td></tr>
1185<tr><td>Post fill</td><td>Does actual entry preserve the risk plan?</td><td>Ticket verification, stop validation, position check</td></tr>
1186</tbody>
1187</table>
1188
1189<p>The phrase “narrowing channel” is useful because it discourages a false binary view. There is no permanent state called good execution. The available room changes from tick to tick. A sensible EA has a defined rule for refusing an entry when the room becomes too narrow for its method. A short target strategy may need a much tighter rule than a position strategy with a wide expected move, but both should state the rule.</p>
1190
1191<h2 id="spread-basics">What a Spread Control Actually Measures</h2>
1192
1193<p>A basic spread check compares Ask minus Bid with a user selected maximum. In MQL4, that difference must be expressed in the same unit as the threshold. This sounds elementary, yet point normalization is one of the most common sources of misleading protections. A symbol quoted with five digits has a Point that differs from a one pip convention. Metals, indices, and broker specific symbols can use their own digits and tick conventions. A parameter named MaxSpreadPips is unsafe if the code silently compares it to raw points.</p>
1194
1195<p>Good review evidence includes a clear input label, a conversion that respects Digits or Point, and a journal line that reports what was observed. For example, the program could calculate <code>spreadPoints = (Ask - Bid) / Point</code>, compare that number to a MaxSpreadPoints input, and log both values when refusing an order. The exact design can vary. The important point is that a reader can tell what the threshold means on the intended symbol.</p>
1196
1197<h3>Ask these questions about the gauge</h3>
1198<ul>
1199<li>Does it read fresh Bid and Ask values immediately before the order rather than relying on an old value?</li>
1200<li>Is the threshold expressed in points, pips, price units, or a documented conversion?</li>
1201<li>Does the input work correctly on five digit, three digit, and unusual symbol quotes?</li>
1202<li>Does it apply to every entry path, including recovery entries, pending order placement, and grid additions?</li>
1203<li>Does it record a refusal so an operator can distinguish a protected skip from a broken EA?</li>
1204<li>Is zero interpreted deliberately: no limit, no spread allowed, or an invalid configuration?</li>
1205</ul>
1206
1207<p>A spread filter is not a verdict on a broker. It is a compatibility rule between a strategy and a current quote. A limit set too low may exclude most tradable periods. A limit set too high may make the filter ceremonial. The appropriate value should come from the strategy's holding period, stop distance, target distance, and observed conditions on the intended account, not from a generic number copied from a forum.</p>
1208
1209<p>Consider two hypothetical EAs. The first seeks a small movement shortly after a signal and closes quickly. A spread that consumes a meaningful share of that expected move changes its economics immediately. The second expects to hold for several days and uses a much wider protective stop. Spread still matters, but a one moment expansion may not have the same significance. A review should therefore ask whether the filter fits the design, not whether the filter exists.</p>
1210
1211<h2 id="slippage-basics">Slippage Is a Fill Problem, Not a Setting Alone</h2>
1212
1213<p>A common misconception is that entering a slippage value in OrderSend solves unfavorable fills. The parameter describes a tolerance in points for a request, but MT4 execution is not identical at every broker. Some accounts use processes where the requested price may be confirmed or requoted. Others may use market execution practices where price can move before the fill. Terminal and server behavior should be verified on the actual account rather than 
1213inferred from an input box.</p>
1214
1215<p>The review standard should be more demanding: after an order succeeds, does the EA inspect the ticket and the opened price? If the entry price is materially different from the strategy's reference, can the program still place a valid protective stop? Does it calculate risk from the actual fill, not the hoped for fill? A robot that assumes its intended price after a successful OrderSend can misstate distance to stop loss or take profit.</p>
1216
1217<p>There is also a difference between a rejected bad fill and an uncontrolled sequence of retries. Retrying once after a refreshed quote can be reasonable in a documented design. Retrying repeatedly without delay, while price is moving, may create duplicate exposure or enter after the signal has expired. The EA needs a retry budget, a new preflight check, and a way to confirm there is no existing position before trying again.</p>
1218
1219<table>
1220<thead><tr><th>Observed result</th><th>Unsafe reaction</th><th>More defensible reaction</th></tr></thead>
1221<tbody>
1222<tr><td>Spread exceeds limit</td><td>Submit anyway because signal is strong</td><td>Skip and log the current spread and limit</td></tr>
1223<tr><td>Requote or invalid price</td><td>Loop until a ticket appears</td><td>Refresh rates, recheck signal and spread, use a small retry cap</td></tr>
1224<tr><td>Order is filled</td><td>Assume requested price was received</td><td>Read ticket details and calculate protection from the actual open price</td></tr>
1225<tr><td>Stop placement fails</td><td>Leave the position unprotected without notice</td><td>Report the condition and follow a predefined safety response</td></tr>
1226<tr><td>Terminal reconnects</td><td>Send the signal again without checking trades</td><td>Scan magic number and symbol before any new request</td></tr>
1227</tbody>
1228</table>
1229
1230<h2 id="review-framework">A Review Framework for MT4 Entry Protection</h2>
1231
1232<p>When reviewing an EA, begin with the entry map. Locate every function that can call OrderSend, OrderModify, or place a pending order. A single well written spread test in the main signal function does not protect a separate martingale addition, a news recovery function, or an initialization routine. The reviewer should trace every route that can create exposure.</p>
1233
1234<p>Next, identify the configuration contract. Inputs should be understandable without reading source. Labels such as Max Spread Points, Allowed Deviation Points, Retry Count, and Trading Sessions are easier to audit than unexplained integer names. Defaults should be conservative enough to invite deliberate adjustment. An input is not useful if code later replaces it with a hard coded value.</p>
1235
1236<h3>Minimum review checklist</h3>
1237<ol>
1238<li>List all order creation paths and the magic numbers or comments used to identify them.</li>
1239<li>Confirm that each market entry refreshes rates and obtains the direction appropriate price.</li>
1240<li>Verify the spread comparison unit on the broker's intended symbol.</li>
1241<li>Read the rejection and retry branch, including conditions that terminate it.</li>
1242<li>Check whether existing orders are detected after a timeout, restart, or connection loss.</li>
1243<li>Confirm stop loss and take profit distances are calculated from actual fill information where necessary.</li>
1244<li>Look for journal messages that allow later reconstruction of a decision.</li>
1245<li>Test behavior when a threshold is disabled, malformed, or set below a viable value.</li>
1246</ol>
1247
1248<p>This is also where an independent review should resist marketing shortcuts. “ECN ready” or “low spread compatible” is not evidence by itself. The implementation needs to show how it refreshes price, accounts for digits, handles server errors, and avoids duplicate orders. A seller's backtest can be a useful artifact, but readers should also consult the site's guide to <a href="/blog/how-to-verify-forex-ea-backtest-results">verifying Forex EA backtest results</a> because a fixed historical spread does not demonstrate resilience in live conditions.</p>
1249
1250<h2 id="mql4-logic">Practical MQL4 Logic to Inspect</h2>
1251
1252<p>The following is a conceptual sequence, not a universal code recipe. An EA first checks whether trading is allowed and whether a valid new signal exists. It c
1252alls RefreshRates, calculates the current spread in its documented unit, and returns without placing an order if the spread is beyond limit. It selects Ask for buys or Bid for sells after refreshing rates. It submits a request with a deliberately chosen deviation. If the request fails on a transient quote condition, it waits only as the design permits, refreshes, confirms that the signal is still valid, confirms no matching position exists, and performs the preflight check again.</p>
1253
1254<p>After success, the program should select the ticket and capture OrderOpenPrice, OrderStopLoss, OrderTakeProfit, symbol, lot size, and magic number. If protective levels were not accepted at entry because of a broker constraint, a carefully bounded follow up modification may be necessary. The dangerous version is one that treats an error as invisible. A trade without its intended protection is not equivalent to a normal trade.</p>
1255
1256<p>There is no need to demand complexity for its own sake. A simple EA can have good discipline. In fact, a small clear sequence is easier to audit than a clever loop with hidden global flags. The desired properties are freshness, unit consistency, bounded behavior, and observability.</p>
1257
1258<h3>Illustrative decision flow</h3>
1259<ol>
1260<li>New signal appears and no matching position is open.</li>
1261<li>EA refreshes quotes and checks that Bid and Ask are valid.</li>
1262<li>EA converts spread into its documented unit and compares it with the configured maximum.</li>
1263<li>If acceptable, it sends one order request using a direction correct price and defined deviation.</li>
1264<li>On a transient failure, it performs at most the configured number of carefully revalidated attempts.</li>
1265<li>On success, it verifies the ticket, actual fill, and protective order state.</li>
1266<li>It writes enough information to the journal for an operator to understand the outcome.</li>
1267</ol>
1268
1269<p>A reader with access to source can inspect this directly. A reader with only a compiled file should not assume an input panel proves the underlying safeguards. Where the person has the necessary rights, an <a href="/">ex4 to mq4 decompiler</a> review can help frame the question of whether recovery is appropriate for maintenance or inspection. Recovered code may require careful interpretation and testing before it can support a conclusion.</p>
1270
1271<h2 id="failure-modes">Failure Modes That Defeat Good Intentions</h2>
1272
1273<p>Several patterns look protective at first glance but break under pressure. The first is a filter evaluated only once at initialization. Spread is dynamic, so a value collected when the terminal starts says little about the quote when an order is sent. The second is a pip conversion copied from a major currency pair and applied to every symbol. A limit can become ten times looser or tighter than the operator believes.</p>
1274
1275<p>The third is an error handler that retries without checking state. Suppose a request times out but the server actually accepted it. A second request may create a second position. The safer pattern checks open orders by symbol and magic number before retrying and treats ambiguity as a condition needing attention. Fourth, some EAs enter a market order and then calculate a stop from the requested rather than filled price. In a fast move, that can produce a stop distance different from the intended risk.</p>
1276
1277<p>Another concern is partial coverage. A vendor might add a maximum spread control to initial entries while a grid or averaging module continues to add positions at any spread. That difference should be stated plainly because the latter behavior can dominate total risk. Similarly, pending orders do not remove execution risk. The fill can occur in changing conditions, and an EA should define what it does after activation.</p>
1278
1279<h2 id="testing-plan">A Test Plan for Bad Execution</h2>
1280
1281<p>Backtesting remains useful for signal logic, but it cannot fully recreate a broker's live queue, connection interruptions, rejected prices, or sudden variable spreads. Testing should move through layers. Begin with a visual code or settings review. Then use a demo account to observe the journal and ticket history under ordinary conditions. Finally, if a user decides to take any live risk, a small and appropriate environment can reveal practical differences. None of these stages assures future performance.</p>
1282
1283<table>
1284<thead><tr><th>
1284Test case</th><th>What to observe</th><th>Acceptable evidence</th></tr></thead>
1285<tbody>
1286<tr><td>Normal liquid session</td><td>Unit conversion and ordinary entries</td><td>Journal shows current spread, limit, request, and ticket</td></tr>
1287<tr><td>Wide spread period</td><td>Whether entries are declined</td><td>No order and a clear skip record</td></tr>
1288<tr><td>Rapid quote changes</td><td>Requote and retry behavior</td><td>Bounded attempts with fresh checks</td></tr>
1289<tr><td>Restart with open trade</td><td>Duplicate prevention</td><td>EA recognizes the existing matching order</td></tr>
1290<tr><td>Protection placement problem</td><td>Response to failed modification</td><td>Explicit alert or predetermined safety action</td></tr>
1291</tbody>
1292</table>
1293
1294<p>Keep test notes precise. Record server name, account type, symbol spelling, digits, EA version, input values, time window, and relevant Experts or Journal messages. A chart screenshot alone cannot explain why an entry was skipped or why a fill differed. The goal is not to manufacture favorable results. It is to see whether the implementation behaves as claimed when the channel narrows.</p>
1295
1296<h2 id="decision-steps">Decision Steps Before Enabling an EA</h2>
1297
1298<p>A practical operator can use a short decision sequence before relying on automation. First, define the maximum execution cost the strategy can tolerate in its own terms. Second, examine whether the EA exposes and enforces that boundary. Third, confirm that the intended broker's symbols, digits, stop level, and account rules are compatible. Fourth, test a refusal case, not only a successful trade. Fifth, decide what notification or manual response is required if the EA cannot place protection.</p>
1299
1300<p>The answer may be to disable a strategy during predictable periods of poor liquidity rather than to inflate its limits. That is a trading and operational choice, not a defect in the platform. A transparent EA makes the choice possible. An opaque one can convert it into a surprise.</p>
1301
1302<h2 id="recovery-audit">Why Recovered Code Can Need an Execution Audit</h2>
1303
1304<p>Execution controls are often where an older EA needs maintenance. A robot can retain a recognizable entry signal while relying on assumptions from a previous broker, symbol format, or terminal build. Variable names may be unclear after source recovery, but comparisons involving Ask, Bid, Point, Digits, OrderSend, error codes, and magic numbers can still reveal the entry path. The site’s article on <a href="/blog/how-to-read-decompiled-mq4-code-from-ex4">how to read decompiled MQ4 code</a> offers a useful companion for readers who need to interpret those structures responsibly.</p>
1305
1306<p>Recovery does not automatically produce production ready source. It can provide a basis for authorized review, repair, or migration, but changes should be compiled and tested in a controlled environment. A reviewer should document what was changed: for example, a clarified spread conversion, a retry cap, or a missing ticket verification. That record helps distinguish an execution safeguard from an accidental strategy change.</p>
1307
1308<h2 id="conclusion">Conclusion: Make Entry Quality Observable</h2>
1309
1310<p>The most valuable spread and slippage safeguard is not a decorative input. It is a complete chain of decisions: fresh quotes, a correctly measured spread, a reasonable boundary, a controlled order request, an honest response to failure, verification of the actual fill, and a record an operator can inspect. This does not eliminate market risk, broker variation, or the possibility of loss. It does prevent the EA from pretending that every signal can be converted into the same trade.</p>
1311
1312<p>For a ForexMQ5 review audience, that distinction is central. A service or tool can help an entitled owner recover or inspect code, but the resulting EA still deserves an execution audit before it is trusted. Good automation does not force itself through a narrowing channel. It measures the channel, respects its limits, and makes its choice visible.</p>
1313`},{slug:"detect-martingale-grid-logic-mql4",title:"How to Detect Martingale and Grid Logic in MQL4 Source Code",metaTitle:"How to Detect Martingale and Grid Logic in MQL4 Code",metaDescription:"Learn practical ways to inspect recovered MQL4 for grid and martingale behaviour, lot escalation, order filters, spacing rules, and risk controls.",keywords:"detect martingale MQL4, grid trading logic MQL4, MQL4 code audit, Expert Advisor lot sizing, MT4 order inspection, recovered MQ4 review",excerpt:"A practical code-reading framework for identifying layered trade grids, increasing lot blocks, recovery rules, and the controls that can change an Expert Advisor's real exposure.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:fu,imageAlt:"Layered forex trade positions forming a grid beside MQL4 code under a magnifier",tableOfContents:[{id:"why-inspect",title:"Why Grid and Martingale Detection Matters"},{id:"terms",title:"Separate the Labels From the Behaviour"}
1313,{id:"start-map",title:"Start With an Order-Flow Map"},{id:"grid-signals",title:"Code Signals of a Trade Grid"},{id:"lot-signals",title:"Code Signals of Martingale Lot Sizing"},{id:"filters",title:"Filters That Change the Real Pattern"},{id:"walkthrough",title:"A Structured MQL4 Walkthrough"},{id:"risk-controls",title:"Read the Exit and Safety Controls"},{id:"decision-process",title:"A Repeatable Review Decision Process"},{id:"documentation",title:"Document Findings Without Overclaiming"},{id:"conclusion",title:"Conclusion"}],content:`
1314<p>An Expert Advisor can look calm in a chart report while carrying position logic that deserves close inspection. A strategy may open one trade, add another at a fixed distance, then increase the next lot size as price continues in the unfavorable direction. That sequence is often described as grid trading, martingale trading, or both. The labels are useful shorthand, but the important work is identifying what the MQL4 code actually does.</p>
1315
1316<p>This guide explains how a reviewer can trace that behavior in readable or recovered MQL4 source. It is written for owners, authorized maintainers, and buyers conducting due diligence on an EA they are entitled to examine. It does not establish that a particular strategy is suitable, deceptive, or unlawful. Code tells a reviewer what instructions exist; it cannot guarantee fills, spreads, broker execution, or future trading outcomes.</p>
1317
1318<p>The inspection starts with a simple principle: follow every path that can create, enlarge, close, or ignore an order. A setting named SafeMode may do little. A variable named GridStep may be repurposed. Conversely, a program can add positions without using either word in its names. The reliable evidence is the relationship among order selection, price distance, lot calculation, and the conditions surrounding OrderSend.</p>
1319
1320<img src="${fu}" alt="Layered trade positions forming a grid beside MQL4 code under a magnifier" style="width:100%;border-radius:8px;margin:24px 0;" />
1321
1322<h2 id="why-inspect">Why Grid and Martingale Detection Matters</h2>
1323
1324<p>Many automated strategies use more than one order for ordinary reasons. A system may scale into a planned position, split execution to control order size, hedge a correlated symbol, or place a defined stop order. Multiple tickets alone are not a grid. Increasing lots alone are not necessarily martingale. The concern arises when new exposure is repeatedly added in response to adverse movement, especially when the new volume grows and exits rely on a small pullback rather than a fixed loss limit.</p>
1325
1326<p>A code review makes the mechanism visible before a reviewer interprets promotional language or historical reports. It can answer practical questions: Does the EA count open orders for its own magic number? Does it compare current Bid or Ask with the most recent entry? Is the next volume derived from the previous trade? Is there a maximum level? Can a basket be liquidated by equity loss? Is a stop loss really passed to the broker, or is it merely an input never used?</p>
1327
1328<p>These answers matter in source recovery and purchasing reviews. A recovered file may be structurally untidy, with generic variable names and repeated blocks, yet still permit a useful behavioral map. Readers who need help interpreting the foundations of a reconstructed program can first review <a href="/blog/how-to-read-recovered-mql4-expert-advisor-code">how to read recovered MQL4 Expert Advisor code</a>. The goal here is narrower: recognize layered-position and loss-recovery patterns without mistaking every multi-order system for the same thing.</p>
1329
1330<h2 id="terms">Separate the Labels From the Behaviour</h2>
1331
1332<p>A precise vocabulary prevents an audit from becoming a debate over names. In this article, a grid means a rule that places or prepares positions at defined price intervals or level conditions. A martingale-style sizing rule means a rule that increases volume after one or more qualifying outcomes, often a loss or an existing adverse position. A recovery basket means a collection of positions managed toward a combined profit, loss, or break-even target. Any of these may occur independently.</p>
1333
1334<table>
1335<thead><tr><th>
1335Observed behavior</th><th>What to inspect</th><th>What it may indicate</th></tr></thead>
1336<tbody>
1337<tr><td>Orders appear at recurring price gaps</td><td>Point, pip conversion, last-open-price comparison</td><td>Price-level grid</td></tr>
1338<tr><td>Each added order is larger than the prior one</td><td>LotMultiplier, multiplication, level lookup</td><td>Martingale-style escalation</td></tr>
1339<tr><td>Orders are added only after a closed losing trade</td><td>History selection, OrderProfit, loss counters</td><td>Outcome-based martingale</td></tr>
1340<tr><td>All tickets close when combined profit reaches a target</td><td>Basket profit loop and close routine</td><td>Basket recovery management</td></tr>
1341<tr><td>Volume stays constant across levels</td><td>Fixed Lots passed to OrderSend</td><td>Grid without escalating volume</td></tr>
1342</tbody>
1343</table>
1344
1345<p>Direction also matters. A classic averaging-down long sequence buys at successively lower prices. A sell sequence can add as price rises. Some EAs alternate direction, run separate buy and sell baskets, or place pending orders above and below price. The review should record the direction condition rather than assume it from a function name such as BuyGrid.</p>
1346
1347<p>It is equally important to distinguish intended design from effective design. An input MaxTrades = 5 is a meaningful limit only if the order-counting code consistently applies it to all relevant tickets. A stop-loss input is not an active stop until the final OrderSend or OrderModify call receives a nonzero calculated price. Reviewers should treat inputs as claims and execution calls as evidence.</p>
1348
1349<h2 id="start-map">Start With an Order-Flow Map</h2>
1350
1351<p>Before reading individual formulas, make a compact map of the EA. Search for OrderSend, OrderModify, OrderClose, OrderDelete, OrderSelect, OrdersTotal, and OrdersHistoryTotal. In recovered source, wrappers may hide those calls inside functions such as OpenTrade, CloseAll, or ManageOrders. Follow each wrapper until the terminal trading function is found.</p>
1352
1353<ol>
1354<li><strong>List entry sites.</strong> Note every function that can submit a market or pending order and whether it handles buys, sells, or both.</li>
1355<li><strong>List order filters.</strong> Record symbol, magic number, order type, comment, and time filters. These determine which tickets belong to the strategy.</li>
1356<li><strong>List state variables.</strong> Look for counters, last-open price, last lot, loss streak, basket profit, and level number.</li>
1357<li><strong>Trace each call condition.</strong> Write the exact event that permits another order: a new bar, a price gap, a closed loss, a timer, or a manual flag.</li>
1358<li><strong>Trace exits separately.</strong> A basket target, individual take profit, trailing rule, hard stop, and emergency equity rule can coexist.</li>
1359</ol>
1360
1361<p>A one-page map is more useful than highlighting random lines. For example, suppose OnTick calls ManageBuyBasket, which loops through open orders, stores the lowest buy open price, and then calls SendBuy if Bid is below that price by StepPoints. That is strong evidence of a price-responsive averaging sequence. The same map should reveal whether SendBuy receives a fixed volume or a computed next lot.</p>
1362
1363<p>Check the units before judging a gap. MQL4 code may use Point, _Point, MarketInfo(Symbol(), MODE_POINT), or a custom pip adjustment for five-digit brokers. A condition written as 300 * Point can mean a very different visual distance than an unqualified claim of 300 pips. Comments can be wrong, especially in old or recovered code. Calculate the expression in the symbol's price precision and state the result as an implementation observation, not a promise about live fills.</p>
1364
1365<h2 id="grid-signals">Code Signals of a Trade Grid</h2>
1366
1367<p>A grid is usually revealed by a comparison between current market price and a prior reference price. The reference might be the first order, the newest order, the best entry, an average price, a manually stored anchor, or a pending-order ladder. The condition often contains a distance variable named GridStep, Distance, Step, PipStep, or Delta, but variable names are secondary.</p>
1368
1369<pre><code>if(buyCount &lt; MaxLevels &amp;&amp;
1370   Bid &lt; lowestBuyPrice - GridStep * Point)
1371{
1372   OpenBuy(nextLot);
1373}</code></pre>
1374
1375<p>This simplified pattern has three relevant parts. The count cap makes the sequence finite if it is correctly maintained. The price test adds a buy only after movement below the selected reference. The open call creates another layer. A reviewer should then inspect how lowestBuyPrice and nextLot are calculated. If lowestBuyPrice is recalculated from all open buys, the code may add at intervals below the deepest entry. If it uses the last ticket by time, it may space layers from the most recent trade instead.</p>
1376
1377<p>Other grids are built with pending orders. Search for OP_BUYLIMIT, OP_SELLLIMIT, OP_BUYSTOP, OP_SELLSTOP, and OrderSend calls whose price parameter is not the current Ask or Bid. A loop that starts from a base price and increments a level index can create a ladder before price reaches any level. Inspect cancellation logic too. Pending orders that remain after a basket closes can restart exposure unex
1377pectedly if the code does not delete them.</p>
1378
1379<h3>Grid inspection checklist</h3>
1380
1381<ul>
1382<li>Identify the reference price for each side of the market.</li>
1383<li>Convert the spacing expression into points or pips for the intended symbol format.</li>
1384<li>Find the maximum number of levels and verify that it applies before every new order.</li>
1385<li>Check whether spacing is fixed, volatility-adjusted, time-adjusted, or widened after each level.</li>
1386<li>Determine whether buy and sell baskets can operate at the same time.</li>
1387<li>Check whether manual trades or other EAs can be counted accidentally.</li>
1388<li>Locate pending-order cleanup after take profit, stop, restart, and error paths.</li>
1389</ul>
1390
1391<p>A grid may be conservative in one dimension and aggressive in another. A fixed number of widely spaced positions is not equivalent to an unrestricted sequence of closely spaced positions. Likewise, a grid with fixed lots behaves differently from one whose volume rises by level. The code review should preserve those distinctions instead of assigning a single risk label.</p>
1392
1393<h2 id="lot-signals">Code Signals of Martingale Lot Sizing</h2>
1394
1395<p>The clearest martingale-style clue is a next-lot formula derived from a prior lot and a multiplier greater than one. In readable code it may look direct:</p>
1396
1397<pre><code>double nextLot = NormalizeDouble(lastLot * LotMultiplier, 2);
1398if(lastClosedProfit &lt; 0)
1399   OpenBuy(nextLot);</code></pre>
1400
1401<p>In practice, the formula can be less obvious. A program may use an array such as LotsByLevel[0..5], a switch statement keyed by count, or a function that repeatedly doubles a base lot. It may calculate a target monetary recovery first and derive volume from tick value, stop distance, or a previous loss. The behavior remains worth recording even when it is not a literal doubling rule.</p>
1402
1403<p>Inspect the trigger with the same care as the formula. An outcome-based sequence reads closed-order history and increases after a net loss. A floating-loss sequence increases while an existing basket is below a price threshold, without waiting for a close. A hybrid may start with a fixed grid and multiply volume only after level three. Each has a different order-flow signature.</p>
1404
1405<table>
1406<thead><tr><th>Formula or structure</th><th>Review interpretation</th><th>Follow-up question</th></tr></thead>
1407<tbody>
1408<tr><td>baseLot * MathPow(multiplier, level)</td><td>Explicit level-based escalation</td><td>What constrains level?</td></tr>
1409<tr><td>lastLot * 2.0</td><td>Direct doubling behavior</td><td>Which order supplies lastLot?</td></tr>
1410<tr><td>LotTable[count]</td><td>Predefined progression</td><td>Are table bounds checked?</td></tr>
1411<tr><td>RiskPercent calculation</td><td>Could be risk sizing, not martingale</td><td>Does it rise after losses or levels?</td></tr>
1412<tr><td>NormalizeLots(volume)</td><td>Broker volume normalization</td><td>What formula existed before normalization?</td></tr>
1413</tbody>
1414</table>
1415
1416<p>Do not overlook broker constraints. Functions that clamp a value to MODE_MINLOT, MODE_MAXLOT, and MODE_LOTSTEP can alter a planned progression. A code path might calculate 0.015 lots, normalize it to 0.02, and produce a larger relative increase than its author expected. Or a progression may hit the maximum lot and continue opening at that maximum. This is not a reason to infer actual account risk from source alone, but it is relevant to describing the implemented sizing rule.</p>
1417
1418<p>One practical search strategy is to find every assignment to variables containing lot, volume, size, multiplier, factor, recovery, or level. Then work backward from the final lot argument in OrderSend. The important question is not whether an input is exposed, but whether the path from state to order volume is reachable in normal operation.</p>
1419
1420<h2 id="filters">Filters That Change the Real Pattern</h2>
1421
1422<p>Entry filters can make a grid or martingale component appear dormant in a short backtest. A trend filter may allow the first order only in a moving-average direction. A news-time block may suspend entries. A session rule may confine additions to specified hours. A spread threshold may stop an order from being sent at the moment the grid condition is true. These 
1422controls deserve credit when they are genuinely connected, but they do not erase the underlying recovery logic.</p>
1423
1424<p>Trace filters in order. An EA might calculate a sell signal, verify a session, count existing orders, check a price gap, and only then determine volume. Another might manage existing baskets on every tick even when its new-entry signal is disabled. Therefore, switching off a signal input may not prevent continuation orders. Reviewers should distinguish initial entries from add-on entries and emergency exits.</p>
1425
1426<p>Magic-number filtering is especially important. A typical loop selects an order and checks OrderSymbol() == Symbol() and OrderMagicNumber() == MagicNumber. Missing one of these conditions can cause the EA to treat unrelated manual positions as levels in its basket. Conversely, a zero magic number can be intentional for a manual-assist tool but makes order ownership harder to establish. Record what the source filters, rather than assuming tickets are isolated.</p>
1427
1428<h2 id="walkthrough">A Structured MQL4 Walkthrough</h2>
1429
1430<p>Consider this illustrative pseudocode. It is intentionally shortened, so it should be read as a method for inspection rather than production-ready trading code.</p>
1431
1432<pre><code>int count = CountOpen(OP_BUY, Magic);
1433double lastPrice = LastOpenPrice(OP_BUY, Magic);
1434double lots = BaseLots * MathPow(Multiplier, count);
1435
1436if(count == 0 &amp;&amp; BuySignal())
1437   SendMarketBuy(BaseLots);
1438
1439if(count &gt; 0 &amp;&amp; count &lt; MaxOrders &amp;&amp;
1440   Bid &lt; lastPrice - StepPoints * Point)
1441   SendMarketBuy(lots);
1442
1443if(BasketProfit(Magic) &gt;= BasketTarget)
1444   CloseBasket(Magic);</code></pre>
1445
1446<p>First, CountOpen establishes a level measure. The audit must inspect whether it counts only open market buys for the current symbol and magic number. Second, LastOpenPrice determines the anchor for the next layer. If it returns the newest buy, spacing is sequential. If it returns the lowest buy, the condition may differ. Third, MathPow(Multiplier, count) makes volume grow by count when Multiplier exceeds one. Fourth, the add-on condition responds to a move below the stored entry. Fifth, the exit is based on combined basket profit rather than a separate stop for each ticket.</p>
1447
1448<p>That evidence supports a measured description: the sample implements a capped, price-spaced buy basket with level-based volume escalation and a collective profit exit. It does not support claims about profitability, safety, intent, or live execution quality. To assess protections, the reviewer still needs to read CloseBasket, error handling, maximum-loss conditions, and every alternate path that can call SendMarketBuy.</p>
1449
1450<p>Now test edge paths on paper. What happens if CountOpen returns zero because OrderSelect fails? What happens after a terminal restart, when lastPrice is reconstructed? Does a failed order send leave the counter unchanged? Does the code set a cooldown that prevents multiple additions on a single fast tick? Recovered source can contain imperfect error handling, so a review should not assume the neat main path is the only path.</p>
1451
1452<h2 id="risk-controls">Read the Exit and Safety Controls</h2>
1453
1454<p>Grid and martingale detection is incomplete without an exit audit. Search every OrderSend and OrderModify call for stop-loss and take-profit arguments. A zero stop-loss can be deliberate if a basket controller closes positions, but then the basket controller becomes central. Find whether it runs on every tick, whether it is limited by trading hours, and whether it handles failed closes.</p>
1455
1456<p>Useful control candidates include MaxOrders, maximum lot, maximum spread, maximum drawdown, equity stop, time stop, daily loss guard, and a rule to close or disable after repeated failures. The wording is not enough. Follow each variable to a branch that returns, closes orders, or prevents a new order. A condition that only prints an alert is not a trade control.</p>
1457
1458<p>For a deeper deployment-oriented check after source recovery, the related guide on <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating recovered MQL4 before live deployment</a> covers controlled compilation and testing steps. A reviewer should treat any tests as evidence about a configured environment, not as certainty about future market behavior.</p>
1459
1460<h3>Control verification checklist</h3>
1461
1462<ol>
1463<li>Confirm the maximum order count is checked before every add-on route.</li>
1464<li>Confirm maximum volume uses the volume that will actually reach OrderSend.</li>
1465<li>Confirm a loss or equity guard has access to all relevant tickets.</li>
1466<li>Confirm stop and close routines filter symbol and magic number correctly.</li>
1467<li>Confirm error paths do not immediately retry a failed order without a limit.</li>
1468<li>Confirm pending orders are included in exposure and cleanup logic where appropriate.</li>
1469</ol>
1470
1471<h2 id="decision-process">A Repeatable Review Decision Process</h2>
1472
1473<p>A practical audit can end in a small decision record rather than a dramatic verdict. Start by deciding whether there is sufficient source visibility. If wrappers, missing functions, or compilation artifacts prevent tracing the final order 
1473call, label the result inconclusive and identify what is missing. A responsible reviewer does not fill gaps with assumptions.</p>
1474
1475<p>If the order path is visible, answer three questions. First, does adverse price movement or a loss state permit another order? Second, does the new order use a defined level spacing or ladder? Third, does volume increase as count, loss, or level grows? A yes to the first two supports a grid finding. A yes to the first and third supports a martingale-style finding. A yes to all three supports a layered grid with escalating volume. Then append the caps and exits that qualify the finding.</p>
1476
1477<p>Owners who need readable source for an authorized maintenance or review project may compare an <a href="/">mql4 decompiler</a> path with other recovery options. This independent review site discusses the service at ForexMQ5 in third-party terms. It does not itself perform recovery, audit a file, or guarantee what any recovered output will show.</p>
1478
1479<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
1480  <h3 style="margin-top:0;">Need an Authorized Source Recovery Option?</h3>
1481  <p>For a file the requester owns or is authorized to maintain, the reviewed service at ForexMQ5 may be a professional recovery option before a code inspection begins.</p>
1482  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
1483</div>
1484
1485<h2 id="documentation">Document Findings Without Overclaiming</h2>
1486
1487<p>A useful report identifies locations and conditions. Instead of writing “the EA is dangerous,” write “ManageBuyBasket calls OrderSend when Bid is at least StepPoints below the selected prior buy price, while nextLot is derived from BaseLots multiplied by Multiplier to the current order count.” Then note the configured values, code version, symbol assumptions, and any untraced functions.</p>
1488
1489<p>Include a short evidence table with function name, relevant condition, order effect, and limitation. Preserve a copy of the source reviewed and the input set used for interpretation. This makes the work repeatable if another maintainer reviews a later version. It also helps separate source facts from configuration facts. A multiplier exists in code even when it is set to 1.0 in one configuration; a cap exists in code even if a user changes it later.</p>
1490
1491<p>Keep the scope appropriate. Source inspection can identify operational logic and implementation gaps. It cannot prove that a developer intended to mislead anyone, that a strategy will lose money, or that a broker will execute every command as simulated. Avoid financial or legal conclusions unless qualified professionals have assessed the relevant evidence.</p>
1492
1493<h2 id="conclusion">Conclusion</h2>
1494
1495<p>Detecting grid and martingale logic is a tracing exercise, not a keyword search. Map the order functions, identify the ticket filters, calculate the price condition, follow the final lot formula, and read exits with the same rigor as entries. A layered sequence at fixed intervals may be a grid. A rising lot sequence after a loss or level may be martingale-style. When both occur together, document the precise constraints rather than relying on a broad label.</p>
1496
1497<p>The best outcome of an authorized MQL4 review is clarity: what opens a new position, what changes its size, what limits it, and what closes the basket. That clarity gives an owner or maintainer a sounder basis for testing, discussion, and further technical work without claiming more certainty than the code can provide. When source is unavailable but authority to inspect it is clear, an <a href="/">ex4 to mq4 decompiler</a> comparison can be the starting point for obtaining material that can be reviewed.</p>
1498`},{slug:"mt4-ea-news-filter-troubleshooting",title:"MT4 EA News Filter Troubleshooting: Why Calendar Protection Stops Working",metaTitle:"MT4 EA News Filter Troubleshooting: Calendar Protection | 2026",metaDescription:"Diagnose a broken MT4 EA news filter, from calendar data connections and time conversion to paused robots and safe post-news recovery checks.",keywords:"MT4 EA news filter troubleshooting, economic calendar connection, EA paused before news, MT4 calendar protection, Forex EA news volatility",excerpt:"An MT4 robot that should pause before major economic events can fail quietly when its calendar feed, clock logic, permissions, or state handling changes. This practical troubleshooting guide shows how to isolate the cause without guessing.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:gu,imageAlt:"MT4 Expert Advisor calendar filter troubleshooting before economic news volatility",tableOfContents:[{id:"what-a-news-filter-does",title:"What an MT4 News Filter Actually Does"},{id:"identify-the-failure",title:"Identify the Failure Before Changing Settings"},{id:"connection-chain",title:"Trace the Economic Calendar Connection"},{id:"time-and-event-logic",title:"Check Time, Currency, and Event Logic"},{id:"robot-state",title:"Inspect the Robot Pause and Resume State"},{id:"safe-diagnostic-plan",title:"A Safe Diagnostic Plan"},{id:"code-review-questions",title:"When a Code Review Is Necessary"},{id:"operational-checklist",title:"Operational Checklist for Future Events"},{id:"conclusion",title:"Conclusion"}],content:`
1499<p>An MT4 Expert Advisor can appear to have a news filter right up to the moment it matters. The chart shows the robot smiling, AutoTrading is enabled, and a high-impact release is approaching. Then the EA either opens a position during the fast move, or it pauses hours early and never returns. Both outcomes can look like a strategy problem when the more basic issue is calendar protection that has stopped receiving, interpreting, or applying event data.</p>
1500
1501<p>A news filter is not a single switch inside MetaTrader 4. It is a chain: an external economic-calendar source publishes an event, the terminal or EA obtains that data, the EA converts the event time, classifies its relevance, and changes its trading state. A break at any point can leave the robot unprotected or permanently sidelined. The practical response is to trace that chain in order instead of changing every input at once.</p>
1502
1503<img src="${gu}" alt="MT4 trading robot paused while checking economic calendar news data" style="width:100%;border-radius:8px;margin:24px 0;" />
1504
1505<p>This independent review guide focuses on troubleshooting, not on a promise that any filter can remove trading risk. Calendar schedules can change, liquidity can thin before an announced release, and price can react to unscheduled headlines. A filter is a risk-control feature with defined assumptions. It needs testing against the particular EA, broker server time, symbols, and calendar source in use.</p>
1506
1507<p>When the fault is in a compiled robot and the original developer is unavailable, the question can become whether the logic can be inspected lawfully. Readers with clear rights to their own software can start with the site’s <a href="/">mt4 ea decompiler</a> review resources. The aim should be maintenance and validation of an owned or authorised EA, never bypassing another vendor’s licence restrictions.</p>
1508
1509<h2 id="what-a-news-filter-does">What an MT4 News Filter Actually Does</h2>
1510
1511<p>News protection normally works by comparing the current time with a list of scheduled events. Each event record may contain a timestamp, affected currency, impact category, title, and sometimes a revised time. The EA decides whether an event matters to the symbol it trades, then applies a pre-news and post-news block. For EURUSD, an implementation might stop new entries around selected EUR and USD events while leaving management of an existing trade to separate rules.</p>
1512
1513<p>That simple description hides important design choices. Some EAs download a CSV or JSON feed with WebRequest. Some read a local file written by a companion script. Some query a DLL, scrape a page through an old component, or rely on a vendor-hosted endpoint. Others include a manually maintained event list. MT4 itself does not give every legacy EA a universal, permanent economic-calendar API. Therefore, a robot that worked last month may depend on infrastru
1513cture outside the terminal.</p>
1514
1515<table>
1516<thead><tr><th>Layer</th><th>What it must do</th><th>Typical failure symptom</th></tr></thead>
1517<tbody>
1518<tr><td>Calendar publisher</td><td>Provide current event records</td><td>Old events remain visible or new ones are absent</td></tr>
1519<tr><td>Network access</td><td>Reach the approved source</td><td>Request error, empty response, timeout</td></tr>
1520<tr><td>Parser</td><td>Read the returned format correctly</td><td>Download succeeds but no event is recognised</td></tr>
1521<tr><td>Time conversion</td><td>Match event time to broker or GMT time</td><td>Pause begins at the wrong hour</td></tr>
1522<tr><td>Decision logic</td><td>Match impact and currency to a symbol</td><td>Relevant events are ignored or unrelated events block trading</td></tr>
1523<tr><td>State control</td><td>Pause and later resume safely</td><td>EA stays paused after the event</td></tr>
1524</tbody>
1525</table>
1526
1527<p>Separating those layers avoids a common mistake: treating “news filter enabled” as proof that news protection is active. An enabled input only means the EA intends to use its filter. It does not prove that the latest event list was downloaded, that the endpoint was allowed, or that the dates made sense.</p>
1528
1529<h2 id="identify-the-failure">Identify the Failure Before Changing Settings</h2>
1530
1531<p>Start with a dated observation. Note the event name, scheduled time as displayed by the calendar source, symbol, broker server time shown in MT4, EA settings, and exact robot behavior. Did it trade through the event? Did it announce a block in the Experts tab? Did it disable only new orders, or did it close a position? A specific observation gives the investigation a comparison point.</p>
1532
1533<h3>Four failure patterns</h3>
1534
1535<ol>
1536<li><strong>No pause at all.</strong> The EA opens a new order inside what should be the protected window. Likely areas include an empty feed, inaccessible URL, currency matching, impact settings, or a time offset.</li>
1537<li><strong>Pause at the wrong time.</strong> The block starts one or more hours before or after the event. Check broker server time, GMT conversion, daylight-saving assumptions, and whether the calendar timestamp already includes a timezone.</li>
1538<li><strong>Pause is too broad.</strong> A robot trading one pair blocks around every event. The filter may treat all events as global, fail to parse currency fields, or use an overly general keyword list.</li>
1539<li><strong>Pause never clears.</strong> The EA correctly stops before news but remains idle. The stored next-event time may be stale, the resume condition may not run, or an error path may leave a Boolean pause flag set.</li>
1540</ol>
1541
1542<p>Do not diagnose this only from account history. A lack of trades may simply mean no entry signal occurred. Likewise, one trade near a release does not prove failure until its open time is compared with the configured buffer and the relevant event. Save screenshots or exports of the Inputs, Experts, and Journal areas while they are available. The distinction between a filter decision and an order rejection matters.</p>
1543
1544<div style="background:#fff8e8;border:1px solid #ead29a;border-radius:8px;padding:20px;margin:28px 0;">
1545<h3 style="margin-top:0;">First-response checklist</h3>
1546<ul>
1547<li>Record the broker server time and the calendar’s displayed timezone.</li>
1548<li>Export or copy the exact EA inputs before editing them.</li>
1549<li>Find the most recent successful calendar update, if the EA reports one.</li>
1550<li>Check whether the EA was attached and AutoTrading was permitted at that time.</li>
1551<li>Test on a non-live environment before changing network, DLL, or trading behavior.</li>
1552</ul>
1553</div>
1554
1555<h2 id="connection-chain">Trace the Economic Calendar Connection</h2>
1556
1557<p>The calendar connection is the most fragile part of many legacy filters. A provider can change its domain, require encrypted transport, alter field names, rate-limit old clients, or retire a format without changing anything on the trader’s chart. A terminal update, antivirus policy, VPS firewall, proxy, or Windows certificate issue can cause the same result. The filter may fail silently if its author did n
1557ot display response errors.</p>
1558
1559<h3>Check permitted WebRequest addresses</h3>
1560
1561<p>For EAs that use WebRequest, MT4 must be permitted to access the specific address under Tools, Options, Expert Advisors, “Allow WebRequest for listed URL.” The protocol and domain should match the address the EA expects. Adding a broad collection of unrelated sites is not a useful fix and enlarges the software’s network permissions. Add only a trusted, documented source required by the authorised robot, then restart or reattach it only if its documentation calls for that step.</p>
1562
1563<p>An approved URL is still not proof of a working request. Look for messages such as HTTP status codes, “failed to load,” “timeout,” “not allowed,” or a zero-length response. Error text may be visible in Experts or Journal, but a quiet log is not conclusive. Some EAs update only once per day, only at initialization, or only when a new bar forms. A diagnostic test should wait for the programmed refresh condition rather than assuming an immediate request.</p>
1564
1565<h3>Compare the data, not just the connection</h3>
1566
1567<p>If a local XML, CSV, JSON, or text file is involved, make a protected copy and inspect whether it contains upcoming events. Check its modification time, encoding, date format, and size. A file dated weeks ago is evidence of a stale update even if it looks structurally valid. An empty file may result from an interrupted download. A response containing an HTML error page can fool a weak parser that only checks whether a file exists.</p>
1568
1569<p>Do not replace a calendar URL with a random public feed simply because it returns data in a browser. The EA may expect particular columns or event codes. A valid-looking response can be misread as zero events, or worse, mapped incorrectly. The correct repair begins by identifying the expected schema and confirmation logic. For a purchased EA, ask the vendor whether the calendar endpoint or installation procedure has changed before attempting modifications.</p>
1570
1571<h3>VPS differences are often decisive</h3>
1572
1573<p>A filter can work on a home terminal and fail on the VPS that runs the account. Compare the MT4 build, EA file version, allowed URLs, Windows date and timezone, proxy settings, security software, and access to the calendar domain. Also compare file paths if the robot reads a local feed. Copying an EA to a new terminal does not necessarily copy its permissions or companion files. The site’s guide to an <a href="/blog/expert-advisor-vps-transfer-audit-mt4">MT4 VPS transfer audit</a> provides a useful wider checklist for configuration differences that are easy to miss.</p>
1574
1575<h2 id="time-and-event-logic">Check Time, Currency, and Event Logic</h2>
1576
1577<p>Time bugs are persuasive because they produce a visible but misleading result. Suppose an event is published at 13:30 UTC, the broker server is UTC+2, and the EA treats the incoming value as server time rather than UTC. A thirty-minute pre-news block may begin at 13:00 server time instead of 15:00 server time. Around daylight-saving transitions, a hard-coded offset may create a one-hour shift only during part of the year.</p>
1578
1579<table>
1580<thead><tr><th>Question</th><th>How to verify it</th><th>What a mismatch suggests</th></tr></thead>
1581<tbody>
1582<tr><td>What timezone is the feed using?</td><td>Read provider documentation and compare one known event</td><td>UTC versus local-time assumption</td></tr>
1583<tr><td>What time does MT4 report?</td><td>Compare TimeCurrent with a chart timestamp</td><td>Broker server offset</td></tr>
1584<tr><td>Does the EA adjust for summer time?</td><td>Review settings or documented logic</td><td>Seasonal one-hour error</td></tr>
1585<tr><td>Which currencies trigger a block?</td><td>Use a known EURUSD event in a test</td><td>Symbol or currency matching defect</td></tr>
1586<tr><td>Which impacts are included?</td><td>Compare input level with feed labels</td><td>Different impact taxonomy</td></tr>
1587</tbody>
1588</table>
1589
1590<p>Symbol naming creates a related trap. Brokers may call a pair EURUSD.a, EURUSDm, or EURUSD.pro. A well-built filter extracts the base and quote currencies before comparing events. A weaker one may rely on the six-character symbol. If the EA trades a broker-suffixed symbol, verify that currency detection still returns EUR and USD. This is especially important when an EA has recently moved brokers or a suffix was introduced after an account migration.</p>
1591
1592<p>Impact labels are not universal either. One source may use high, medium, and low, while another uses numeric importance or icons. If the parser looks for a word that no longer appears, every event can be discarded. The same applies to event names. A filter based on keywords such as “Payrolls” can miss a renamed calendar entry. Prefer testing with stored sample records from the current source rather than assuming the old vocabulary persists.</p>
1593
1594<h2 id="robot-state">Inspect the Robot Pause and Resume State</h2>
1595
1596<p>A functioning download does not guarantee correct trading behavior. The EA must apply the event decision on the right schedule and unwind it afterward. Common designs use a variable such as NewsTradingDisabled, a calculated nextNewsTime, or a rout
1596ine that returns false from the entry function. Each can fail differently after terminal restarts, chart changes, or an error during initialization.</p>
1597
1598<p>For example, a robot might set its pause flag when the clock enters the pre-news window, then rely on a later tick to clear the flag. If the market is quiet, a tick-dependent cleanup may be delayed. Another EA may load a cached event from yesterday and calculate a negative countdown incorrectly. A third might disable all trading through a global setting rather than limiting new entries. The actual behavior should be documented before a repair is proposed.</p>
1599
1600<h3>Separate entry control from trade management</h3>
1601
1602<p>Many users expect “news filter” to mean every open trade will be closed. That is not necessarily the intended design. A cautious EA may stop new orders while maintaining existing stops, targets, and trailing logic. Another may close positions at a configured time. Neither approach is automatically appropriate for every strategy. The troubleshooting task is to establish what the EA says it will do and whether it does that consistently, not to retrofit a preference without testing its consequences.</p>
1603
1604<p>After a paused period, confirm all of these: the block flag clears, the calendar refreshes, normal entry checks run, the spread filter has not independently prevented trading, and the terminal still permits algorithmic trading. A permanent pause sometimes has nothing to do with news. A broker market closure, expired licence, disabled AutoTrading button, or a separate daily-loss guard can look identical at the chart level.</p>
1605
1606<h2 id="safe-diagnostic-plan">A Safe Diagnostic Plan</h2>
1607
1608<p>Use a copy of the terminal or a demo environment for diagnosis. Do not force an uncertain EA to trade around a real release merely to prove that its filter works. Planned tests can use a future known event, controlled settings, and clear expected results. The purpose is to observe state transitions, not to seek volatility.</p>
1609
1610<ol>
1611<li><strong>Preserve a baseline.</strong> Copy the EX4, set file hashes where appropriate, export Inputs, and note the EA version and broker.</li>
1612<li><strong>Choose one relevant future event.</strong> Select an event matching one currency in the test symbol and record its published time and impact.</li>
1613<li><strong>Confirm data arrival.</strong> Before the buffer starts, verify the local data or EA message identifies the upcoming event.</li>
1614<li><strong>Observe the pre-news decision.</strong> Check that the EA reports or demonstrates its configured new-entry block at the calculated time.</li>
1615<li><strong>Observe post-news recovery.</strong> After the configured interval, verify that the block clears and the next event record is not stale.</li>
1616<li><strong>Change one variable only.</strong> If expected behavior fails, test timezone, URL permission, or symbol mapping separately and record each result.</li>
1617</ol>
1618
1619<p>A backtest may help test portions of entry logic, but it often cannot reproduce live WebRequest access or an externally refreshed calendar. Treat a backtest as limited evidence. The related guide on <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating a recovered MQL4 EA before live deployment</a> explains why controlled validation should cover platform behavior as well as historical performance.</p>
1620
1621<h2 id="code-review-questions">When a Code Review Is Necessary</h2>
1622
1623<p>If logs and settings point to a parsing or state defect, source-level review may be the only dependable way to establish what the EA actually expects. This should be limited to software the requester authored, owns, or is explicitly authorised to inspect. An EX4 from a marketplace purchase is not automatically permission to obtain or alter source, even if its filter is broken.</p>
1624
1625<p>For an owned custom robot, an <a href="/">ex4 to mq4</a> recovery discussion should begin with the narrow maintenance question: how is the calendar data obtained and how does the EA decide to pause? That keeps inspection directed at a documented fault rather than at copying a third party’s strategy.</p>
1626
1627<p>For an owned custom EA with lost source, an authorised recovery and review can answer focused questions: Which URL is requested? Is WebRequest checked for errors? What timezone conversion is applied? Are dates parsed with a fixed format? Does the code account for broker suffixes? Does the pause state persist across restart? Is a stale cache rejected? These questions are more useful than a vague request to “fix the news filter.”</p>
1628
1629<p>The service at ForexMQ5 is reviewed on this site as a professional recovery option for users with a legitimate, documented source-recovery purpose. Their team’s role is technical recovery, not a determination of a customer’s legal rights or a guarantee that a trading system is suitable. A scoped handover, with the original file, ownership records, observed failure, and desired test cases, gives an authorised maintainer a better starting point than a demand to remove protections.
1629</p>
1630
1631<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
1632<h3 style="margin-top:0;">Need to Review an Owned EA?</h3>
1633<p>For a documented recovery or maintenance need, readers can evaluate the professional service at ForexMQ5 and prepare a clear technical brief before requesting help.</p>
1634<a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
1635</div>
1636
1637<h2 id="operational-checklist">Operational Checklist for Future Events</h2>
1638
1639<p>Once a cause is corrected, make the filter observable. A short routine before significant scheduled events is more reliable than assuming a setting remains healthy indefinitely.</p>
1640
1641<ul>
1642<li>Verify the EA version and its calendar-source documentation after updates or VPS moves.</li>
1643<li>Check that the expected upcoming event appears in the data used by the EA.</li>
1644<li>Compare feed time, broker server time, and configured pre-news and post-news buffers.</li>
1645<li>Confirm allowed URLs and local companion files exist on the machine actually trading.</li>
1646<li>Review the Experts area for download, parsing, licence, or trading-permission messages.</li>
1647<li>Confirm whether the configured behavior blocks entries, manages open trades, or both.</li>
1648<li>After the event, confirm the robot resumed according to its documented rules.</li>
1649<li>Keep a change log so a later failure can be tied to a terminal, broker, VPS, or EA change.</li>
1650</ul>
1651
1652<p>It is also sensible to retain a manual operating plan. If the calendar source is unavailable, decide in advance whether the authorised operator will remove the EA, disable automated trading, or leave it running according to the system’s documented fallback rule. This is an operational choice, not financial advice, and it should be tested without relying on a live high-volatility event. The important point is that silence from a calendar feed should not be mistaken for “no news.”</p>
1653
1654<h2 id="conclusion">Conclusion</h2>
1655
1656<p>When calendar protection stops working, the right question is not simply whether the EA’s news input is enabled. Trace the route from published event to network access, parsed record, timezone calculation, currency match, and pause state. That method distinguishes a broken external feed from a broker-time mismatch, a symbol naming problem, and a robot that is paused for an unrelated reason.</p>
1657
1658<p>A well-documented test on a non-live setup can turn an unsettling surprise into a specific maintenance task. For source-controlled EAs, preserve the test evidence and correct the weakest link. For compiled software, seek the vendor’s supported fix first. If the requester clearly has rights to a custom robot whose source is lost, a narrowly scoped recovery review may help identify the logic that needs attention. In every case, a news filter deserves verification as an active system, not faith as a checkbox.</p>
1659`},{slug:"mt4-ea-account-lock-license-checks",title:"MT4 EA Account Locks and License Checks: Diagnose Authorization Failures",metaTitle:"MT4 EA Account Locks and License Checks: Diagnose Authorization Failures",metaDescription:"Diagnose an MT4 EA locked-account or licence error with a practical checklist for account number, broker server, key activation, terminal logs, and vendor support.",keywords:"MT4 EA account lock, MT4 EA licence check, Expert Advisor authorization failure, broker server EA lock, MT4 licence key diagnostic checklist",excerpt:"A locked trading account screen can look like an MT4 fault when an Expert Advisor is actually refusing an account, broker server, licence key, or activation state. This practical guide helps users document the signal, test the right variables, and escalate without attempting to bypass a vendor control.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:vu,imageAlt:"MT4 Expert Advisor licence screen showing an account authorization diagnostic checklist",tableOfContents:[{id:"what-an-account-lock-means",title:"What an MT4 Account Lock Usually Means"},{id:"separate-the-symptoms",title:"Separate the Visible Symptom From the Actual Check"},{id:"capture-evidence",title:"Capture Evidence Before Changing Anything"},{id:"diagnostic-checklist",title:"Account Lock Diagnostic Checklist"},{id:"account-and-server",title:"Account Number, Server, and Broker Variables"},{id:"licence-key-and-activation",title:"Licence Key and Activation State"},{id:"terminal-permissions",title:"Terminal Permissions and Environment Checks"},{id:"logs-and-test-cases",title:"Read Logs and Run Controlled Test Cases"},{id:"decision-tree",title:"A Practical Escalation Decision Tree"},{id:"vendor-conversation",title:"Prepare an Effective Vendor Support Request"},{id:"avoid-bypass-requests",title:"Why Bypassing a Lock Is the Wrong Fix"},{id:"conclusion",title:"Conclusion: Diagnose, Document, Then Authorize"}],content:`
1660<p>An Expert Advisor can load normally, show a smiley face, and still decline to trade because its authorization check has failed. The trader may see a panel that says locked account, invalid licence, unauthorised broker, expired key, or no trading permission. In other cases there is no panel at all. The only clue is a brief journal message, followed by complete silence when the entry conditions appear to be met.</p>
1661
1662<p>Those symptoms are frustrating because several independent systems meet at the same moment: the MT4 terminal, the logged-in trading account, the broker server name, the EA inputs, a vendor activation record, and sometimes an internet request. Changing random settings can turn a supp
1662ortable issue into a confusing one. A better approach is to identify exactly which check is failing and preserve a clean record of the evidence.</p>
1663
1664<img src="${vu}" alt="MT4 account authorization diagnostic checklist beside a locked Expert Advisor panel" style="width:100%;border-radius:8px;margin:24px 0;" />
1665
1666<p>This independent review guide is about diagnosis and authorised resolution. It does not describe how to remove an account lock or alter licence logic. An account or licence restriction may be part of the vendor's agreement and protection of its work. When the user has a valid purchase or written permission, the productive route is normally to provide accurate account and server details to the vendor, follow its activation process, and verify the result in a controlled environment.</p>
1667
1668<h2 id="what-an-account-lock-means">What an MT4 Account Lock Usually Means</h2>
1669
1670<p>An account lock is a rule inside, or alongside, an EA that decides whether the program may perform its intended functions for the current user. The rule can compare the logged-in account number to an approved list. It can also evaluate a broker server string, account type, expiry date, licence key, hardware fingerprint, allowed symbol, or remote activation response. The presentation varies, but the underlying result is simple: the EA has decided that the current context does not satisfy its authorization conditions.</p>
1671
1672<p>That result should not immediately be interpreted as proof of a bad EA, a broker problem, or an invalid purchase. A valid licence can fail after a broker changes a server label. A demo account can have a different number from the live account supplied during purchase. A VPS migration can change a machine-bound activation. An EA that needs to contact a licensing endpoint may fail while the terminal is offline, while WebRequest permission is absent, or while a service is temporarily unavailable. Conversely, an account lock can accurately indicate that the installed copy was never licensed for that account.</p>
1673
1674<p>The first useful distinction is between an authorization refusal and a trading-condition failure. An authorization refusal is usually stable: it appears on every tick, after terminal restart, or immediately at initialization. A strategy condition is variable: the EA is authorized but waits for spread, time, indicator, risk, or signal criteria. The site’s guide to <a href="/blog/forex-ea-troubleshooting-why-automated-trading-robots-fail">why an EA can stop working</a> covers broader operational faults. This article narrows the work to the account and licence layer.</p>
1675
1676<h2 id="separate-the-symptoms">Separate the Visible Symptom From the Actual Check</h2>
1677
1678<p>A message on the chart is a symptom, not necessarily the exact reason. “Invalid account” may mean the number is absent from an approved list, but it can also be a generic label used after a remote lookup failed. “Wrong broker” may refer to the server name rather than the broker brand. “Key error” may mean the key was copied with a space, was assigned to another account, or has not been activated. Treat the text as a lead to investigate rather than a complete diagnosis.</p>
1679
1680<table>
1681  <thead><tr><th>Visible symptom</th><th>Common underlying check</th><th>First safe verification</th></tr></thead>
1682  <tbody>
1683    <tr><td>Locked account message on chart</td><td>Account number not approved</td><td>Compare the current MT4 account number with the order and activation record.</td></tr>
1684    <tr><td>Broker not supported</td><td>Server name or account group mismatch</td><td>Copy the exact server displayed by MT4, including punctuation and suffixes.</td></tr>
1685    <tr><td>Licence key invalid</td><td>Key typo, wrong product, expired entitlement, or unactivated key</td><td>Enter the original key carefully and check the vendor account page or purchase email.</td></tr>
1686    <tr><td>EA attaches but never trades</td><td>Silent authorization return or ordinary strategy filter</td><td>Read Experts and Journal messages immediately after attachment.</td></tr>
1687    <tr><td>Works on one terminal but not a VPS</td><td>Machine binding, missing files, network access, or different login</td><td>Compare account, server, terminal build, inputs, and permissions side by side.</td></tr>
1688  </tbody>
1689</table>
1690
1691<p>It is important not to confuse the account number displayed in a client portal with the account currently logged into MT4. A trader may have several live and demo logins, or a broker may issue a new number after a migration. The authoritative value for diagnosis is the active terminal session at the time of failure. Likewise, a broker’s marketing name is less useful than its server identifier. Two servers with a similar brand name can represent different account groups and may be deliberately treated differently by a licence policy.</p>
1692
1693<h2 id="capture-evidence">Capture Evidence Before Changing Anything</h2>
1694
1695<p>Evidence collection takes a few minutes and prevents hours of contradictory testing. Before re-entering a key, changing inputs, or reinstalling MT4, take a screenshot of the entire chart. Include the EA name, the symbol and timeframe, any on-chart message, and the terminal time. Then record the account number and server shown in the terminal. Save the exact EX4 file name and the folder in which it is installed. If practical, calculate a file checksum so the vendor can tell whether it is examining the same build that the user is running.</p>
1696
1697<p>Next, open the Experts and Journal tabs. Capture entries from when the EA was attached, when the terminal connected, and when the lock appeared. Log wording can distinguish initialization failure from a rejected order. Do not redact the useful technical context before saving a private original. For a support ticket, redact passwords, investor credentials, account balances, personal contact details, and any licence secret that the vendor does not need to see in full.</p>
1698
1699<p>A simple case record should include the following:</p>
1700
1701<ul>
1702  <li>Date, time, and terminal time zone of the failure.</li>
1703  <li>Exact EA file name, version displayed on the chart if available, and source of the download.</li>
1704  <li>MT4 account number, account type, and exact broker server name.</li>
1705  <li>Whether the account is demo, live, funded, migrated, read-only, or newly created.</li>
1706  <li>Whether the EA previously worked on this same account and server.</li>
1707  <li>All EA input values related to keys, account lists, mode selection, and remote validation.</li>
1708  <li>A screenshot and the relevant Experts and Journal lines.</li>
1709</ul>
1710
1711<p>Keep the original record unchanged. Each later experiment should be noted separately, with its result. This matters because reinstalling a terminal or changing an input can remove the very clue needed to explain a failure. It also makes an authorised vendor request much easier to process.</p>
1712
1713<h2 id="diagnostic-checklist">Account Lock Diagnostic Checklist</h2>
1714
1715<p>Work from the least disruptive check to the more involved one. There is no need to reinstall software before confirming that the terminal is simply logged into a different account. The checklist below assumes the user is entitled to run the EA and is seeking a normal authorization outcome.</p>
1716
1717<ol>
1718  <li><strong>Confirm the active login.</strong> Record the account number currently connected in MT4. Do not rely on a remembered number or a broker email.</li>
1719  <li><strong>Copy the exact server name.</strong> Record it character for character. A server suffix, regional label, or account-group word can be relevant.</li>
1720  <li><strong>Confirm the product identity.</strong> Match the EA file and displayed version against the purchase receipt. Similar product names can have separate licences.</li>
1721  <li><strong>Review licence inputs.</strong> Check for pasted spaces, omitted characters, wrong capitalization where the vendor specifies it, or a key placed in the wrong input field.</li>
1722  <li><strong>Check the entitlement scope.</strong> Determine whether the purchase covers demo use, live use, a named account, a named broker, a limited number of activations, or an expiry period.</li>
1723  <li><strong>Read startup logs.</strong> Remove and reattach the EA once, then read the newest Experts and Journal entries. Preserve the exact wording.</li>
1724  <li><strong>Verify terminal permissions.</strong> Confirm that automated trading is enabled and that any vendor-documented DLL or WebRequest setting has been approved only when appropriate.</li>
1725  <li><strong>Test one controlled alternative.</strong> If the vendor authorises a demo or replacement account, test that exact case without changing unrelated strategy settings.</li>
1726  <li><strong>Escalate with evidence.</strong> Send the vendor the factual record and request an account, server, or activation review.</li>
1727</ol>
1728
1729<p>Readers looking for a broader understanding of compiled files and what configuration can realistically change may find the <a href="/">ex4 to mq4 decompiler</a> review useful. A compiled EX4 is not an editable settings file, and a licence issue should not be approached as a request to alter its internal rules. Configuration, authorization, and source recovery are different questions with different rights and risks.<
1729/p>
1730
1731<h2 id="account-and-server">Account Number, Server, and Broker Variables</h2>
1732
1733<p>Account number checks are direct when a vendor stores one approved number, but account authorization frequently uses more than that number. An EA may allow a specified broker server, or may distinguish between demo and live accounts. It may expect a server name supplied during ordering. It may be configured for a particular prop-firm environment. When a broker moves customers to a new server, the account number might stay the same while the server identifier changes. From the EA’s viewpoint, that can be a new environment.</p>
1734
1735<p>Copy the server value from the terminal instead of typing a broker name from memory. For example, a vendor may have approved “ExampleMarkets-Live 2” while the terminal is now connected to “ExampleMarkets-Live 2 EU.” Those strings may look interchangeable to a human but not to a software comparison. The correct response is not to edit the EA. It is to ask whether the vendor can add the current server or issue an updated authorised build.</p>
1736
1737<p>Also check whether a broker account was replaced following identity verification, an account-type change, or a platform migration. A user might legitimately own both the old and new accounts, yet the licence can still be recorded against only the old number. Provide the vendor with the old and new details, proof of the purchase, and any broker notice that explains the transition. Avoid sending login passwords. Support normally needs the account number and server, not control of the account.</p>
1738
1739<h3>A comparison table for two terminals</h3>
1740
1741<p>If the EA works on one terminal and not another, create a side-by-side comparison. It turns vague claims into testable differences.</p>
1742
1743<table>
1744  <thead><tr><th>Item to compare</th><th>Working terminal</th><th>Failing terminal</th><th>Why it matters</th></tr></thead>
1745  <tbody>
1746    <tr><td>Account number and server</td><td>Record exact values</td><td>Record exact values</td><td>Reveals an account or server lock.</td></tr>
1747    <tr><td>EA file and version</td><td>Record file name and date</td><td>Record file name and date</td><td>Shows whether the same authorised build is installed.</td></tr>
1748    <tr><td>EA inputs</td><td>Export or screenshot</td><td>Export or screenshot</td><td>Finds a missing key or changed mode.</td></tr>
1749    <tr><td>Terminal permissions</td><td>Check settings</td><td>Check settings</td><td>Identifies blocked automated trading or documented network access.</td></tr>
1750    <tr><td>Experts log at startup</td><td>Save lines</td><td>Save lines</td><td>May state the failed condition directly.</td></tr>
1751  </tbody>
1752</table>
1753
1754<h2 id="licence-key-and-activation">Licence Key and Activation State</h2>
1755
1756<p>A licence key is an identifier, not proof that every terminal and account has been approved. Vendors use different models. One key may unlock a named account. Another may permit a limited number of machines. A subscription may be valid only through a date. A customer portal may require an activation step after the key is entered. The purchase terms and vendor instructions should define the model, so start there rather than assuming how the key works.</p>
1757
1758<p>Enter a key from the original purchase record, preferably by careful copy and paste into the documented input. Then inspect for leading or trailing spaces. Do not post a full key in a public forum, screenshot, or chat. If support needs to identify it, follow the vendor’s secure process and provide only the portion they request. A replacement key issued by a reseller might belong to a different product version, so verify the product name and date before declaring the EA broken.</p>
1759
1760<p>Activation issues often follow an ordinary change: moving to a VPS, reinstalling Windows, changing terminal data folders, or replacing hardware. If the vendor binds the licence to a device fingerprint, a new machine can consume an activation or require a reset. Describe the change accurately. A request such as “please review the activation after a VPS migration” gives support something actionable. Repeatedly activating on many machines, however, may be restricted by the licence and can complicate the review.</p>
1761
1762<p>Where a key is checked remotely, distinguish a licence response from a general network problem. C
1762onfirm that MT4 itself is connected, that system time is sensible, and that only the vendor-documented URL has been added to WebRequest permissions when the vendor requires it. Never add unknown URLs because an internet post suggested it. A remote check can also fail on the vendor side. A timestamped log and screenshot help support identify that possibility without guessing.</p>
1763
1764<h2 id="terminal-permissions">Terminal Permissions and Environment Checks</h2>
1765
1766<p>Not every “authorization” message is a commercial licence decision. MT4 has its own controls that can stop an EA from trading. The toolbar AutoTrading state, the EA’s Common tab, account trade permissions, market hours, and connection status are separate from vendor licensing. A user should confirm them, but should not mistake their presence for confirmation that the vendor licence is valid.</p>
1767
1768<p>Start with the simple terminal state. Is AutoTrading enabled globally? Is “Allow live trading” selected for this EA where appropriate? Is the account connected rather than showing no connection? Is the account read-only? Is the symbol available for trading at that time? These checks do not involve bypassing anything. They establish whether the terminal is capable of submitting an order after the EA has authorised itself.</p>
1769
1770<p>Some EAs use DLL imports, common files, or WebRequest as documented dependencies. Those options deserve caution. Enable only a dependency that appears in the vendor’s official instructions and only for an EA obtained from a trusted, authorised source. A request to enable a DLL or URL that arrives from an unknown chat account is a security warning, not a troubleshooting step. The guide on a <a href="/blog/purchased-forex-ea-security-audit-checklist">purchased EA security audit</a> offers a wider framework for checking files, permissions, and vendor claims before deployment.</p>
1771
1772<h2 id="logs-and-test-cases">Read Logs and Run Controlled Test Cases</h2>
1773
1774<p>Logs are most valuable when they are gathered immediately after a simple, repeatable action. Remove the EA, attach it to a clean chart, wait for initialization, and capture the relevant Experts and Journal lines. Do this once before changing inputs. Then, if there is a vendor-approved alternative account or corrected key, repeat the same procedure and compare only the changed variable.</p>
1775
1776<p>A controlled test answers one question at a time. If the user changes account, server, key, strategy settings, and terminal build together, a successful result reveals little and a failure reveals even less. A disciplined example looks like this: the EA is attached to the purchaser’s approved demo account and records “authorised”; the same file with identical inputs is attached to a new live account and records “account not registered.” The evidence points toward registration of the live account, not a strategy defect.</p>
1777
1778<p>Do not treat a lack of log text as evidence that no check occurred. Some compiled EAs use limited messages. Record the absence, the attachment time, and observable behavior. If possible, test only in a demo environment approved by the vendor. There is no reason to use a live account as a diagnostic laboratory, especially when a robot’s trading logic and risk controls are not yet confirmed.</p>
1779
1780<h2 id="decision-tree">A Practical Escalation Decision Tree</h2>
1781
1782<p>The following decision path keeps the work focused on an authorised remedy.</p>
1783
1784<ol>
1785  <li><strong>Is the message clearly about account, key, broker, expiry, or activation?</strong> If yes, gather evidence and continue. If no, first investigate ordinary terminal and strategy conditions.</li>
1786  <li><strong>Does the active account and exact server match the purchase or activation record?</strong> If no, request an authorised update or clarify the licence scope with the vendor.</li>
1787  <li><strong>Does the file and licence key match the purchased product?</strong> If no, obtain the correct file or key through the seller’s official channel.</li>
1788  <li><strong>Did the problem follow a VPS, hardware, broker, or account change?</strong> If yes, ask for an activation reset or account migration review, subject to the licence terms.</li>
1789  <li><strong>Do logs indicate a documented terminal dependency?</strong> If yes, apply only the vendor-documented setting and retest once.</li>
1790  <li><strong>Is the entitlement uncertain, expired, or disputed?</strong> Pause deployment. Resolve the commercial or contractual question with the vendor rather than seeking a technical workaround.</li>
1791</ol>
1792
1793<p>This sequence also protects against a common mistake: assuming that paid access means unlimited transfer rights. A licence may be valid, yet still restricted to an account or environment. That is a matter for the vendor’s authorization process, not an inference the user should make from a receipt alone.</p>
1794
1795<h2 id="vendor-conversation">Prepare an Effective Vendor Support Request</h2>
1796
1797<p>Support requests are resolved faster when they state facts, not theories. Begin with the product name, purchase reference, current account number, exact server name, and a concise description of the change that preceded the failure. Attach the relevant screenshot and log excerpt. State whether the request is for account registration, a server update, a key review, or an activation reset. Ask what documentation is required for the next step.</p>
1798
1799<p>For example: “The EA worked on account 12345 at BrokerName-Demo. After the broker opened replacement account 67890 at BrokerName-Live 3, the chart shows ‘account not authorised.’ The attached Experts entry was captured at 14:05 terminal time. Please confirm whether the licence covers the replacement account and whether you need proof of the broker migration.” This wording is specific, respectful, and avoids asking support to guess.</p>
1800
1801<p>Use the official vendor contact route listed in the purchase documentation or its verified website. Be cautious of third parties offering instant unlocks, replacement EX4 files, or copied keys. Such offers can lead to malware, loss of a legitimate licence, or a breach of the vendor agreement. The site reviews the service at ForexMQ5 as a professional option for legitimate EX4 recovery needs, but recovery is not a remedy for an account-authorization restriction on a licensed third-party EA.</p>
1802
1803<h2 id="avoid-bypass-requests">Why Bypassing a Lock Is the Wrong Fix</h2>
1804
1805<p>An account, broker, or licence lock can be inconvenient, particularly after an unexpected broker migration or a vendor delay. That inconvenience does not justify removing the control. Attempts to bypass licence logic may breach the licence terms, undermine a vendor’s intellectual property protections, and create legal or security risks that depend on the jurisdiction and facts. They can also make a later authorised support request harder because the original file or environment has been altered.</p>
1806
1807<p>There is a practical reason as well. A modified or unofficial build may no longer receive vendor updates, may behave differently from the purchased product, and may introduce hidden security problems. If the EA is important to an operation, a clean documented activation path is more sustainable than an untrusted workaround. Where the user owns the underlying project and has lost source, rights and recovery should be assessed separately from a licence dispute over someone else’s product.</p>
1808
1809<p>For readers who need to understand the distinction between legitimate source recovery and restricted software, the homepage’s <a href="/">decompile ex4</a> resources explain the review site’s rights-first approach. The focus is on authorised maintenance and informed evaluation, not on defeating controls placed on a vendor’s software.</p>
1810
1811<h2 id="conclusion">Conclusion: Diagnose, Document, Then Authorize</h2>
1812
1813<p>A locked MT4 EA is best treated as an authorization question with several possible inputs. The account number, exact broker server, product version, licence key, activation record, terminal permissions, and remote validation state can all matter. The fastest route is rarely a reinstall or a change to unrelated strategy settings. It is a clean record of the active environment, a careful reading of the logs and purchase terms, and one controlled test at a time.</p>
1814
1815<p>When the evidence points to a new account, changed server, expired entitlement, or VPS move, the appropriate next step is an official vendor review. When it points to ordinary MT4 permissions, correct only the documented setting and retest safely. When the user cannot establish a right to use the EA on the account in question, stopping is the sensible decision. Clear documentation, precise communication, and authorised activation protect both the trader’s setup and the rights attached to the softw
1815are.</p>
1816`},{slug:"expert-advisor-source-code-contract-clauses",title:"Expert Advisor Source Code Contract Clauses Every Buyer Should Request",metaTitle:"Expert Advisor Source Code Contract Clauses Every Buyer Should Request",metaDescription:"A practical buyer checklist for Expert Advisor development contracts, source-code folders, ownership clauses, acceptance tests, escrow, and clean project handover.",keywords:"Expert Advisor source code contract, EA development agreement, MQL4 source code ownership, trading robot handover, source code delivery checklist",excerpt:"A custom Expert Advisor is not fully bought until the agreement defines who owns it, what arrives in the source folder, and how the final handover is verified. This guide gives buyers practical contract clauses and acceptance steps to discuss with qualified advisers.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:yu,imageAlt:"buyer and developer reviewing an Expert Advisor source code handover contract",tableOfContents:[{id:"why-contract",title:"Why the Contract Matters Before Development Starts"},{id:"ownership-shield",title:"Build an Ownership Shield, Not a Vague Promise"},{id:"source-folder",title:"Define the Source Code Folder Precisely"},{id:"scope-clauses",title:"Clauses That Keep Scope and Payment Clear"},{id:"acceptance",title:"Acceptance Testing and the Delivery Handshake"},{id:"dependencies",title:"Libraries, Licences, and Third-Party Dependencies"},{id:"continuity",title:"Continuity if the Developer Becomes Unavailable"},{id:"buyer-workflow",title:"A Buyer Workflow From Brief to Handover"},{id:"red-flags",title:"Contract Red Flags and Practical Questions"},{id:"conclusion",title:"Conclusion: Buy a Maintainable Project"}],content:`
1817<p>Buying a custom Expert Advisor can feel straightforward: describe an idea, agree a price, receive a file, and attach it to MetaTrader. That sequence is incomplete. A compiled EX4 or EX5 may run today while leaving the buyer unable to correct a bug, change a broker symbol, move to another platform, or understand what was actually delivered. The protection is not a dramatic legal document full of obscure phrases. It is a clear development agreement that joins business expectations to a verifiable source-code handover.</p>
1818
1819<p>This article is an educational review-site guide, not legal advice. Contract rules, copyright defaults, employment rules, consumer rights, and enforceability vary by jurisdiction. Buyers with a valuable system, a cross-border developer relationship, investor obligations, or a dispute should take the proposed wording and facts to a qualified lawyer. The goal here is narrower: help a buyer ask better questions before funds and access are exchanged.</p>
1820
1821<p>That matters especially for trading software. An EA is more than its entry rule. It can contain risk limits, order handling, filters, settings, installation instructions, libraries, indicator files, and assumptions about a broker. A buyer who receives only a binary has a usable product only for as long as its environment stays compatible. A buyer who receives a documented source folder and a defined right to maintain it has options. Readers wanting background on the compiled file can start with this explanation of <a href="/">ex4 to mq4</a> and why the two forms serve different purposes.</p>
1822
1823<img src="${yu}" alt="buyer and developer reviewing an Expert Advisor source code handover contract" style="width:100%;border-radius:8px;margin:24px 0;" />
1824
1825<h2 id="why-contract">Why the Contract Matters Before Development Starts</h2>
1826
1827<p>A contract is most useful when it removes assumptions before coding begins. “You will own the EA” sounds reassuring but leaves major questions unanswered. Does ownership include the MQ4 or MQ5 source? Does it cover custom indicators? Can the buyer hire another programmer later? Are reusable developer libraries excluded? Will the developer deliver build instructions, presets, and testing evidence? What happens if a milestone is paid but the project stops?</p>
1828
1829<p>Neither party benefits from hiding these decisions until final delivery. The developer needs a stable specification and a definition of acceptance. The buyer needs to know what is being purchased rather than assuming that a screenshot, backtest report, or compiled file proves completion. Clear clauses make conversations more professional because they convert memories into checkable deliverables.</p>
1830
1831<table>
1832<thead><tr><th>
1832Weak expectation</th><th>Useful contract question</th><th>Evidence at handover</th></tr></thead>
1833<tbody>
1834<tr><td>“Make my strategy.”</td><td>Which instruments, timeframes, entry conditions, exits, and risk rules are included?</td><td>Signed functional specification and test cases</td></tr>
1835<tr><td>“I own the robot.”</td><td>Which rights transfer, and which pre-existing components are licensed?</td><td>Ownership or licence clause plus component list</td></tr>
1836<tr><td>“Send the files.”</td><td>Which source, binaries, presets, libraries, and instructions must be delivered?</td><td>Folder inventory and delivery archive</td></tr>
1837<tr><td>“It works.”</td><td>How will both parties test the agreed behavior?</td><td>Acceptance checklist and issue log</td></tr>
1838<tr><td>“Support later.”</td><td>For how long, at what rate, and for which changes?</td><td>Support and change-control terms</td></tr>
1839</tbody>
1840</table>
1841
1842<p>A good agreement also separates an engineering result from a trading promise. Code can be required to follow stated logic, compile in a named environment, and pass agreed tests. No responsible contract should quietly turn a programmer into a guarantor of profit, a particular drawdown, or future market behavior. Historical results depend on data, settings, execution conditions, and assumptions. Buyers should specify software behavior and risk controls, then evaluate trading suitability independently.</p>
1843
1844<h2 id="ownership-shield">Build an Ownership Shield, Not a Vague Promise</h2>
1845
1846<p>An ownership shield is a practical collection of clauses and records that make future control easier to establish. It is not about treating a developer unfairly. It identifies what the buyer is paying for, protects confidential strategy information, and respects the developer's legitimate reusable tools. The central distinction is between custom work created for the project and background materials the developer already owned.</p>
1847
1848<h3>State the intended rights in plain language</h3>
1849
1850<p>Where a buyer expects to control custom source, the agreement should say whether the developer assigns intellectual-property rights in the custom deliverables upon full payment, or grants a perpetual, transferable right to use, modify, and have others modify them. The appropriate approach depends on the deal and local law. The important point is that “full source code” and “exclusive ownership” are not interchangeable phrases.</p>
1851
1852<p>The clause should identify the deliverables by name. For example: the custom EA source, bespoke indicators written under the project, configuration files, documentation, and tests. It should state whether the buyer may retain another programmer, use the code with a successor business, create derivative versions, or operate it on multiple accounts. If the buyer only needs a broad maintenance licence rather than a full assignment, that limitation should be explicit.</p>
1853
1854<h3>Protect the buyer's strategy materials</h3>
1855
1856<p>Many buyers reveal non-public rules, spreadsheets, account observations, or prototype logic. A confidentiality clause should define those materials, limit their use to the project, identify permitted recipients, and require reasonable protection. It should also address whether the developer can reuse general skills and know-how without reusing the buyer's confidential expression. This is a more realistic boundary than pretending a programmer can erase all experience gained while working.</p>
1857
1858<h3>Record exclusions instead of discovering them later</h3>
1859
1860<p>A developer may reasonably retain ownership of a generic logging framework, a standard trade wrapper, or an independently developed library. If such items are used, list them in a schedule and state the buyer's licence. The buyer needs to know whether the component is included, whether updates require a fee, and whether a replacement programmer can use it. Hidden exclusions can turn a supposed source handover into a folder that will not compile outside the original developer's machine.</p>
1861
1862<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;">
1863<h3 style="margin-top:0;">Ownership clause discussion checklist</h3>
1864<ul>
1865<li>Identify custom deliverables and any excluded background tools.</li>
1866<li>State when rights transfer or when the maintenance licence begins.</li>
1867<li>Confirm whether the buyer may modify, hire others, and create successor versions.</li>
1868<li>Set confidentiality duties for strategy materials and credentials.</li>
1869<li>Require the developer to disclose third-party code before inclusion.</li>
1870</ul>
1871</div>
1872
1873<p>The existing article on <a href="/blog/legal-rules-for-ex4-source-code-recovery">source recovery rights and licence terms</a> adds useful context here. A buyer who merely possesses an EX4 may have permission to run it without permission to reconstruct or alter it. A written project agreement can prevent that uncertainty, but it must be tailored to the actual work and reviewed under relevant law.</p>
1874
1875<h2 id="source-folder">Define the Source Code Folder Precisely</h2>
1876
1877<p>“Source folder” should be a contract term, not a casual description. The buyer should receive a clean, organized archive that another competent developer can open and understand. A pile of unnamed files, an EX4 alone, or source that depends on a private path does not meet that standard. Ask for a folder map before work begins, then use the same map at delivery.</p>
1878
1879<table>
1880<thead><tr><th>
1880Folder item</th><th>Why it matters</th><th>Buyer check</th></tr></thead>
1881<tbody>
1882<tr><td>Main EA source file</td><td>Contains the program entry points and trading logic.</td><td>It opens and compiles in the named MetaEditor version.</td></tr>
1883<tr><td>Include files and libraries</td><td>Missing dependencies can prevent a future build.</td><td>Every referenced local file is present and identified.</td></tr>
1884<tr><td>Custom indicators</td><td>An EA may call indicators not bundled with MetaTrader.</td><td>Source, binary where relevant, and installation path are supplied.</td></tr>
1885<tr><td>Preset files</td><td>Inputs can materially change behavior.</td><td>Each preset has a purpose, instrument, and timeframe label.</td></tr>
1886<tr><td>Build instructions</td><td>Allows another person to reproduce the compiled output.</td><td>Instructions state platform, build, paths, and compile steps.</td></tr>
1887<tr><td>Test materials</td><td>Make acceptance repeatable rather than subjective.</td><td>Tests name settings, data assumptions, and expected events.</td></tr>
1888<tr><td>Change log</td><td>Explains what was completed and what remains excluded.</td><td>Final version is dated and linked to the accepted scope.</td></tr>
1889</tbody>
1890</table>
1891
1892<p>A folder convention can be simple. One top-level project directory might contain Source, Include, Indicators, Presets, Documentation, Tests, and Releases. The value is not the exact names. The value is that paths are explained, dependencies are present, and the delivery can survive a laptop replacement. If a developer uses version control, request an exported repository or a transfer of access only if the agreement defines the method and includes confidential material safeguards.</p>
1893
1894<p>Buyers should also ask for a build manifest. This short file records the MetaTrader version, compiler warnings accepted by the parties, external dependencies, input defaults, and the checksum or version label of the accepted binary. It prevents a common disagreement: one party tests a binary made from different source than the folder that arrived later.</p>
1895
1896<h2 id="scope-clauses">Clauses That Keep Scope and Payment Clear</h2>
1897
1898<p>Ownership is ineffective if nobody agrees on what is being built. A functional specification should describe observable behavior without forcing the buyer to write code. It can cover symbols, timeframes, entries, exits, position sizing choices, max-spread behavior, trading hours, error handling, notifications, and inputs. It should identify items that are intentionally outside scope, such as portfolio allocation, VPS setup, broker account management, or performance optimization after launch.</p>
1899
1900<p>Use milestones tied to useful evidence, not just calendar dates. An early milestone might produce a written specification. A middle milestone can deliver a demo build and a test report. Final payment should be tied to the agreed handover package and acceptance process. This does not mean a buyer should withhold payment for a new idea introduced at the last minute. It means both sides should know which result unlocks each payment.</p>
1901
1902<ol>
1903<li><strong>Discovery milestone:</strong> strategy brief, assumptions, excluded requirements, and acceptance plan are approved.</li>
1904<li><strong>Prototype milestone:</strong> the developer demonstrates core behavior using agreed scenarios.</li>
1905<li><strong>Review milestone:</strong> buyer tests a release candidate and logs defects against the specification.</li>
1906<li><strong>Handover milestone:</strong> source folder, documentation, binaries, and agreed fixes are delivered for acceptance.</li>
1907</ol>
1908
1909<p>The agreement should include change control. If the buyer changes an entry rule after the prototype, the developer should document the cost, timing, and effect on prior testing before work starts. If the developer discovers an ambiguity, they should seek clarification instead of selecting behavior silently. A short written change note is usually enough. It protects the budget and makes the final source easier to explain.</p>
1910
1911<h2 id="acceptance">Acceptance Testing and the Delivery Handshake</h2>
1912
1913<p>The delivery handshake is the moment where the buyer confirms receipt, tests the agreed package, records issues, and either accepts the work or requests corrections within an agreed period. It should not be a vague request to “try it live for a month.” Live trading can introduce variables far beyond code quality. Instead, acceptance should focus on the written behavior that both sides can reproduce in a controlled environment.</p>
1914
1915<p>For each important requirement, create a test case with setup, action, and expected result. Example: attach the EA to EURUSD M15 with a named preset, provide a test c
1915ondition that meets the defined entry rule, and confirm that it creates the expected order request or log entry subject to platform permissions. Another test can verify that the maximum spread guard blocks a trade above the chosen input. Tests should make clear which conditions need historical data or a demo account.</p>
1916
1917<h3>A practical acceptance clause structure</h3>
1918
1919<ul>
1920<li>Define the delivery channel and require a dated archive or repository tag.</li>
1921<li>List the documents, files, and source folders that constitute delivery.</li>
1922<li>Set a reasonable review period and a method for reporting reproducible defects.</li>
1923<li>Distinguish a defect from a new feature or an unlisted environmental issue.</li>
1924<li>Require correction of verified scope defects, then a retest.</li>
1925<li>State what acceptance means for final payment and rights transfer.</li>
1926</ul>
1927
1928<p>The buyer should compile the delivered source independently where possible. That one action reveals missing includes, hidden local dependencies, and instructions that only work on the developer's system. It also creates a useful record that the source folder matched the handover. The site's guide to <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating an EA before live deployment</a> offers a sensible testing mindset: begin with compilation and controlled checks, then use demo or limited observation rather than assuming a historical report answers every question.</p>
1929
1930<p>An acceptance process should leave room for good faith. A minor formatting warning may not matter, while an undocumented dependency that prevents compilation probably does. A surprise broker restriction might require a paid change if it was not in scope. The contract cannot eliminate judgement, but an issue log with expected and actual behavior gives both parties a shared basis for resolving it.</p>
1931
1932<h2 id="dependencies">Libraries, Licences, and Third-Party Dependencies</h2>
1933
1934<p>Third-party components are where a promising source handover can fail quietly. An EA may use an included library, a DLL, a paid indicator, a web API, font files, or copied snippets. Each has a different licence and deployment requirement. The buyer should require disclosure before delivery, not discover a paid dependency while moving the EA to a new computer.</p>
1935
1936<p>A dependency schedule can name each component, its version, provider, licence type, installation method, cost, renewal requirement, and whether credentials are needed. It should also state whether the developer is allowed to include it and whether the buyer can legally distribute the source folder to a future maintenance programmer. If a component cannot be transferred, the agreement should identify a replacement plan or limit the buyer's expectations plainly.</p>
1937
1938<p>Credentials need special handling. API keys, trading passwords, and personal tokens should not be hard-coded into source or placed in a normal delivery archive. The documentation can explain where configuration belongs, while the buyer creates production credentials independently. A code review should search for secrets, account identifiers, and remote endpoints before handover. This is an engineering safeguard, not a claim that any one review catches every security problem.</p>
1939
1940<h2 id="continuity">Continuity if the Developer Becomes Unavailable</h2>
1941
1942<p>Continuity planning is what turns source ownership into practical resilience. Developers become busy, businesses close, priorities change, and platforms update. A buyer does not need to assume bad faith to prepare for ordinary change. The contract can require regular source delivery at milestones, a current repository snapshot, and enough documentation for a successor to take over.</p>
1943
1944<p>For a larger project, parties may discuss source-code escrow, where a neutral arrangement holds defined materials and releases them on specified events. Escrow has administration cost and needs precise release conditions, so it may be disproportionate for a small EA. A simpler approach is often better: milestone archives, buyer-controlled access to the project repository, and a final handover that has been independently compiled.</p>
1945
1946<p>Support terms deserve similar clarity. A brief warranty period for defects against the agreed specification is different from an open-ended promise to adapt the EA to every broker, build, or market condition. State the support channel, response target if any, hourly or fixed rates for new w
1946ork, and whether the developer must make a reasonable effort to transfer knowledge to a replacement provider. This gives the buyer a practical exit path without asking for an impossible lifetime guarantee.</p>
1947
1948<h2 id="buyer-workflow">A Buyer Workflow From Brief to Handover</h2>
1949
1950<p>Buyers can keep the process manageable with a small project file. It should hold the agreement, approved specification, change notes, milestone receipts, delivery archives, test records, and contact details. Do not rely on chat history as the only record. Important decisions should be copied into a dated summary that both parties can confirm.</p>
1951
1952<ol>
1953<li><strong>Write the behavior brief.</strong> Describe the strategy in observable terms and name what is excluded.</li>
1954<li><strong>Choose the rights model.</strong> Decide whether the buyer needs an assignment or a durable maintenance licence, then seek appropriate legal review.</li>
1955<li><strong>List the source folder.</strong> Attach the folder inventory, dependency schedule, and documentation requirements to the agreement.</li>
1956<li><strong>Agree on acceptance.</strong> Turn material rules into test cases before the code is written.</li>
1957<li><strong>Collect milestone snapshots.</strong> Store each delivered source archive and change note in a buyer-controlled location.</li>
1958<li><strong>Perform the final handshake.</strong> Check inventory, compile source, run acceptance tests, document defects, and confirm resolution.</li>
1959<li><strong>Secure the finished project.</strong> Keep encrypted backups, restrict credentials, and record where the authoritative version lives.</li>
1960</ol>
1961
1962<p>For buyers comparing how much technical detail to request, an <a href="/">ea decompiler</a> is a poor substitute for a planned handover. Recovery can be technically uncertain and may raise rights questions, while an agreed folder is direct evidence of the project the parties intended to transfer. It is more efficient to negotiate maintainability before development than to reconstruct it after a relationship ends.</p>
1963
1964<h2 id="red-flags">Contract Red Flags and Practical Questions</h2>
1965
1966<p>Some warning signs are not automatic proof of a problem, but they call for a slower conversation. A developer who refuses to identify dependencies may be protecting reusable tools, or may be unable to reproduce the build. A buyer who demands every generic library may be overreaching. The solution is not suspicion. It is a specific schedule that respects both custom work and pre-existing assets.</p>
1967
1968<ul>
1969<li><strong>Red flag:</strong> source is promised only after “everything is finished.” <strong>Ask:</strong> Can milestone snapshots be delivered so continuity does not depend on one final event?</li>
1970<li><strong>Red flag:</strong> the contract says “buyer owns all code” but lists no deliverables. <strong>Ask:</strong> Does that include indicators, include files, presets, tests, and build notes?</li>
1971<li><strong>Red flag:</strong> acceptance means profitable results. <strong>Ask:</strong> Can acceptance instead test stated software behavior and safety controls?</li>
1972<li><strong>Red flag:</strong> required DLLs or services are mentioned late. <strong>Ask:</strong> What are their licences, operating costs, and replacement options?</li>
1973<li><strong>Red flag:</strong> all changes are called bugs. <strong>Ask:</strong> What is the written method for approving out-of-scope work?</li>
1974<li><strong>Red flag:</strong> the developer keeps exclusive access to the repository. <strong>Ask:</strong> What backup or transfer mechanism activates if the engagement ends?</li>
1975</ul>
1976
1977<p>Buyers should avoid copying a generic online clause without understanding it. A clause that appears strong may conflict with local law, the payment arrangement, or a third-party licence. The better approach is to use this checklist as a discussion outline, disclose the commercial reality, and obtain advice where the consequences justify it. A respectful developer should be able to explain their standard terms and distinguish reasonable protection of prior tools from withholding the custom deliverables being purchased.</p>
1978
1979<h2 id="conclusion">Conclusion: Buy a Maintainable Project</h2>
1980
1981<p>The best source-code contract does not try to predict every future disagreement. It makes the essentials visible: what the EA must do, what files will arrive, who can maintain them, which components are excluded, how testing works, and what happens if either side cannot continue. That is the ownership shield. The final compile, inventory check, and acceptance record are the handshake that proves the shield connects to a real delivery.</p>
1982
1983<p>For a buyer, the practical standard is simple. Do not measure completion solely by whether a compiled robot opens on a chart today. Measure it by whether the agreed source folder can be located, compiled, understood, tested, and maintained within the rights the agreement actually grants. That standard protects a legitimate custom project while giving the developer a fair and defined scope of work.</p>
1984`},{slug:"mt4-strategy-tester-model-quality-guide",title:"MT4 Strategy Tester Model Quality: Read Backtest Reports Without False Confidence",metaTitle:"MT4 Strategy Tester Model Quality: Read Reports Honestly",metaDescription:"Learn how to read MT4 Strategy Tester model quality, tick coverage, report metrics, and testing limits without giving a backtest more confidence than its data deserves.",keywords:"MT4 Strategy Tester model quality, MT4 backtest report, forex EA data quality, tick modelling, honest backtest analysis",excerpt:"A high-looking MT4 Strategy Tester result can describe the past test more clearly than it predicts the next trade. This guide puts the report, modelling assumptions, and missing evidence under a practical magnifying glass.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:bu,imageAlt:"MT4 Strategy Tester report examined with a magnifying glass beside a data quality meter",tableOfContents:[{id:"report-is-not-verdict",title:"A Strategy Tester Report Is Evidence, Not a Verdict"},{id:"model-quality",title:"What the Model Quality Field Actually Describes"},{id:"data-chain",title:"Trace the Data Chain Before Reading Profit"},{id:"report-reading",title:"Read the Core Report Fields Together"},{id:"bar-path",title:"Why Bar Paths and Timeframes Change Results"},{id:"costs",title:"Put Trading Costs Back Into the Test"},{id:"example",title:"A Worked Report Review"},{id:"stress-tests",title:"Stress Tests That Expose Fragile Logic"},{id:"code-and-settings",title:"Check the EA and Settings Behind the Report"},{id:"decision-process",title:"A Decision Process for Honest Use"},{id:"conclusion",title:"Conclusion: Confidence Must Be Earned"}],content:`
1985<p>MT4 Strategy Tester can turn a set of historical prices into a neat report in minutes. It will calculate profit, drawdown, trade count, modelling quality, and a graph that appears to tell a complete story. The danger is not that these fields are useless. The danger is treating a report as if it measured certainty. It measures what a particular Expert Advisor did against a particular reconstruction of past market conditions under selected settings.</p>
1986
1987<p>That distinction is especially important when a report is used to judge a purchased EA, a recovered legacy robot, or a strategy that is about to receive real money. A persuasive equity curve may be compatible with a weak data source, unrealistic fills, one favorable symbol, or an optimization that quietly memorized the sample. This guide takes an independent review approach: it helps a reader ask what the report supports, what it leaves unresolved, and what evidence should come next. It does not promise that a historical result will recur.</p>
1988
1989<img src="${bu}" alt="MT4 Strategy Tester report examined with a magnifying glass beside a data quality meter" style="width:100%;border-radius:8px;margin:24px 0;" />
1990
1991<h2 id="report-is-not-verdict">A Strategy Tester Report Is Evidence, Not a Verdict</h2>
1992
1993<p>A backtest is a controlled historical experiment. Its value comes from making an idea inspectable. It can reveal whether entry rules actually trigger, whether position sizing has an obvious flaw, how long drawdowns lasted in the selected period, and whether a change improved only a chart or also the trade record. It cannot recreate every quote, liquidity condition, rejected order, server delay, or future market regime.</p>
1994
1995<p>Start with a narrow claim. A report may support: “With these inputs, this EA produced these simulated trades on this data.” It does not support: “The EA is safe,” “the vendor’s return is assured,” or “the next year will resemble this one.” This language discipline prevents a good-looking number from taking on authority it did not earn.</p>
1996
1997<p>Readers evaluating opaque MT4 software should also separate performance evidence from code evidence. A report cannot show whether a robot has hidden restrictions, an account dependency, or logic that changes outside the tested window. The site’s <a href="/blog/how-to-ver
1997ify-forex-ea-backtest-results">guide to verifying Forex EA backtest results</a> covers the wider due-diligence questions. Strategy Tester analysis is one layer of that work, not a substitute for it.</p>
1998
1999<h3>A five-part report identity card</h3>
2000<p>Before judging any metric, write down the following facts beside the saved HTML report:</p>
2001<ol>
2002<li><strong>EA identity:</strong> file name, version, input preset, and any license or account conditions.</li>
2003<li><strong>Market setup:</strong> symbol, broker feed, digits, timeframe, and tested dates.</li>
2004<li><strong>Modelling setup:</strong> testing model, quality reading, spread setting, and whether data gaps were visible.</li>
2005<li><strong>Execution assumptions:</strong> deposit, leverage, lot rules, commission treatment, and slippage assumption.</li>
2006<li><strong>Scope:</strong> one untouched test, an in-sample optimization, or an out-of-sample confirmation.</li>
2007</ol>
2008<p>Without this identity card, two reports with the same title are not necessarily comparable. A reader can reproduce neither the result nor the limitations.</p>
2009
2010<h2 id="model-quality">What the Model Quality Field Actually Describes</h2>
2011
2012<p>In classic MT4 testing, the model quality percentage is commonly read as a badge of truth. It is better understood as a diagnostic about the historical data and the tester’s ability to model price movement for the selected run. The displayed percentage does not independently validate the strategy. It does not prove that ticks matched the broker’s historical sequence, that spreads were realistic, or that future execution will be similar.</p>
2013
2014<p>The tester may use different modelling approaches. “Every tick” aims to simulate price movement inside bars using available information. “Control points” is a faster approximation. “Open prices only” evaluates logic at bar openings and can be appropriate only when the EA genuinely makes decisions at that point and does not rely on intrabar stops, trailing actions, or tick conditions. A fast test is not automatically a bad test, but it must fit the strategy being examined.</p>
2015
2016<table>
2017<thead><tr><th>Report observation</th><th>Reasonable interpretation</th><th>What it does not establish</th></tr></thead>
2018<tbody>
2019<tr><td>High model quality</td><td>The tester had relatively complete data for its selected modelling process.</td><td>That fills, spread, and future prices are realistic.</td></tr>
2020<tr><td>Low model quality or gaps</td><td>Intrabar reconstruction may be less dependable, especially for tick-sensitive rules.</td><td>That every conclusion is false. It does mean confidence should be reduced.</td></tr>
2021<tr><td>Open-prices model</td><td>A useful quick check for strictly bar-open systems.</td><td>That scalping, stop management, or intrabar entries were tested faithfully.</td></tr>
2022<tr><td>Every-tick model</td><td>More suitable for logic that reacts within bars.</td><td>That the generated path equals the market’s original tick sequence.</td></tr>
2023</tbody>
2024</table>
2025
2026<p>Inspect the report’s modelling quality and mismatch messages rather than copying only the summary numbers. If quality is absent, unusually low, or accompanied by warnings, retain that fact in the conclusion. Do not crop it out when sharing a report. Honest analytics includes inconvenient metadata.</p>
2027
2028<h2 id="data-chain">Trace the Data Chain Before Reading Profit</h2>
2029
2030<p>Price history is not a neutral backdrop. It is an input with its own origin, time zone, missing periods, symbol specification, and broker-specific behavior. An EA tested on EURUSD at one broker may see different symbol suffixes, session boundaries, quotes, contract settings, and costs at another. A result can be mechanically accurate for the local history file yet poorly representative of the intended live environment.</p>
2031
2032<h3>Questions for the history file</h3>
2033<ul>
2034<li>Which broker or source supplied the data, and does it resemble the intended trading venue?</li>
2035<li>What dates are included, and do they contain quiet, volatile, trending, and range-bound conditions?</li>
2036<li>Are weekends, market closures, obvious spikes, duplicate bars, or missing intervals explained?</li>
2037<li>Does the symbol match the live symbol’s digits, suffix, contract size, and trading session?</li>
2038<li>Was the data downloaded once and left undocumented, or can another reviewer obtain the same input?</li>
2039</ul>
2040
2041<p>Data quality is contextual. A daily trend system may be less sensitive to an isolated missing minute than a short-horizon EA that moves a stop several times within a bar. A news-sensitive robot may be more exposed to spread and quote behaviour than a system that trades infrequently. The right question is not “is the percentage high enough?” It is “could this data limitation change the logic or fill sequence that creates the result?”</p>
2042
2043<p>
2043When analyzing a compiled EA that must be maintained, record its broker assumptions before changing anything. The related article on <a href="/blog/mt4-ea-broker-symbol-name-mismatch-fix">MT4 broker symbol name mismatches</a> is useful when an otherwise working robot cannot find a live instrument. A symbol mismatch is not merely an installation annoyance. It can make a backtest and live comparison meaningless.</p>
2044
2045<h2 id="report-reading">Read the Core Report Fields Together</h2>
2046
2047<p>The report’s summary is a set of relationships, not a leaderboard. Net profit alone hides the path taken. Profit factor alone can hide a small sample. Maximum drawdown alone can hide a position-sizing rule whose risk grows after losses. Read the report in groups and then inspect the trade list.</p>
2048
2049<table>
2050<thead><tr><th>Field or area</th><th>Useful question</th><th>Common false confidence</th></tr></thead>
2051<tbody>
2052<tr><td>Total net profit</td><td>How much depended on a few trades or one market phase?</td><td>Profit means the method is durable.</td></tr>
2053<tr><td>Profit factor</td><td>Is it supported by enough trades and stable across periods?</td><td>A ratio alone describes risk or reliability.</td></tr>
2054<tr><td>Expected payoff</td><td>Is the average result meaningful after costs and sample size?</td><td>A positive average guarantees a positive future.</td></tr>
2055<tr><td>Maximum drawdown</td><td>Was it measured on balance, equity, or both, and what caused it?</td><td>The historic worst loss is a known ceiling.</td></tr>
2056<tr><td>Consecutive losses</td><td>Could the account and sizing plan tolerate a longer losing sequence?</td><td>The next losing run cannot exceed the test.</td></tr>
2057<tr><td>Trade count</td><td>Does the sample contain enough independent opportunities across conditions?</td><td>Many trades automatically remove bias.</td></tr>
2058</tbody>
2059</table>
2060
2061<p>Balance and equity deserve separate attention. Balance changes when trades close. Equity includes the floating value of open positions. A strategy that postpones losses can display a calm balance curve while carrying substantial floating exposure. Inspect the graph, the duration of open baskets, and the largest floating drawdown if the report makes it visible. Grid, averaging, and martingale-like sizing need this scrutiny because the closing record may conceal the route to a final result.</p>
2062
2063<p>Also scan the order list, not just the graph. Look for clusters of trades around a specific time, unusually large lots, positions held through weekends, entries at improbable prices, or a single event that dominates profit. A report becomes more credible when its mechanics can be described plainly.</p>
2064
2065<h2 id="bar-path">Why Bar Paths and Timeframes Change Results</h2>
2066
2067<p>An OHLC bar gives four values: open, high, low, and close. It does not disclose the exact order in which the high and low occurred. If a strategy has both a stop and target inside the same bar, the order of those events can decide the simulated result. This is the core bar-path problem. Lower-quality modelling may choose a plausible path, but plausible is not identical to observed.</p>
2068
2069<p>Test sensitivity by changing the timeframe and modelling method where the strategy permits it. A bar-close system should remain intelligible when its entry logic is reviewed at the same decision point. A tick-sensitive system should be challenged with data and settings appropriate to ticks. If a result changes radically simply because a bar is reconstructed differently, report that fragility rather than selecting the prettier run.</p>
2070
2071<h3>Intrabar sensitivity checklist</h3>
2072<ol>
2073<li>Identify every rule involving stop loss, take profit, trailing stop, break-even, pending orders, or multiple entries.</li>
2074<li>Ask whether two of those events can occur inside one bar.</li>
2075<li>Compare a representative period under a more detailed model where possible.</li>
2076<li>Review trades near bar highs and lows rather than assuming the tester resolved them exactly.</li>
2077<li>Mark the conclusion as provisional if the edge depends on an uncertain intrabar order.</li>
2078</ol>
2079
2080<h2 id="costs">Put Trading Costs Back Into the Test</h2>
2081
2082<p>Many weak reports benefit from costs that were fixed, omitted, or too kind to the strategy. Spread is only one part of the problem. C
2082ommission, swap, slippage, requotes, partial fills, stop-level rules, and latency can matter, particularly when the average trade is small or the EA trades frequently. A test that clears costs by a narrow margin deserves caution, not celebration.</p>
2083
2084<p>Use a range rather than one convenient setting. Run a base case that reflects known account conditions, then a less favorable spread and a modest adverse fill assumption appropriate to the strategy. The purpose is not to invent catastrophe. It is to learn whether the logic survives ordinary uncertainty. Record every change in a test log so a reader can distinguish the baseline report from a stress run.</p>
2085
2086<table>
2087<thead><tr><th>Strategy trait</th><th>Cost most likely to matter</th><th>Useful test</th></tr></thead>
2088<tbody>
2089<tr><td>Very short targets</td><td>Spread and slippage</td><td>Increase effective entry and exit cost.</td></tr>
2090<tr><td>Frequent trading</td><td>Commission and spread</td><td>Calculate results under the actual account schedule.</td></tr>
2091<tr><td>Overnight baskets</td><td>Swap and widening conditions</td><td>Check holding time and overnight financing assumptions.</td></tr>
2092<tr><td>News-time entries</td><td>Spread expansion and delayed execution</td><td>Exclude the event window and test a conservative fill case.</td></tr>
2093</tbody>
2094</table>
2095
2096<p>A negative stress result does not automatically disprove a strategy. It tells the reviewer which assumption the claimed edge relies on. That is valuable information for sizing, venue selection, and the decision not to deploy.</p>
2097
2098<h2 id="example">A Worked Report Review</h2>
2099
2100<p>Consider a hypothetical EA report with a smooth rising balance curve, a high-looking modelling-quality reading, and a profitable two-year test. The vendor presentation highlights net profit and a small closed-trade drawdown. A careful reviewer does not call it false on sight. Instead, the reviewer asks a sequence of questions.</p>
2101
2102<ol>
2103<li><strong>Identify the model.</strong> If the EA uses a trailing stop and several pending orders, an open-prices run cannot answer the important intrabar questions.</li>
2104<li><strong>Locate the data.</strong> If the report gives no broker, dates, or symbol details, it cannot be reproduced and should be treated as marketing evidence rather than a technical validation.</li>
2105<li><strong>Read equity behavior.</strong> If positions stay open for long periods and lots increase after losses, a quiet balance curve may not represent the worst floating exposure.</li>
2106<li><strong>Inspect concentration.</strong> If a small number of trades produce a large share of profit, remove or isolate that period to see how dependent the result is on it.</li>
2107<li><strong>Reprice costs.</strong> If average profit per trade is close to likely spread and commission variation, the reported edge may be too thin to rely on.</li>
2108<li><strong>Separate samples.</strong> If settings were tuned on the same two years that produced the graph, reserve a later untouched period for confirmation.</li>
2109</ol>
2110
2111<p>The honest conclusion might be: “The report shows a potentially interesting historical pattern, but missing data provenance, intrabar sensitivity, and floating-risk analysis prevent a deployment conclusion.” That is more useful than either blind praise or blanket dismissal. It names the next evidence needed.</p>
2112
2113<h2 id="stress-tests">Stress Tests That Expose Fragile Logic</h2>
2114
2115<p>Stress testing is not a search for a single worst number. It is a structured way to ask whether a conclusion depends on a narrow historical accident. Change one meaningful assumption at a time, save the report, and compare both the summary and the trade behavior. If every test is altered at once, the cause of a change becomes hard to interpret.</p>
2116
2117<h3>Practical test menu</h3>
2118<ul>
2119<li><strong>Time split:</strong> optimize or develop on one period, then lock inputs and run a later untouched period.</li>
2120<li><strong>Market split:</strong> include conditions that differ in volatility and direction, not only the most favorable stretch.</li>
2121<li><strong>Cost sensitivity:</strong> use realistic and slightly adverse trading costs.</li>
2122<li><strong>Parameter neighborhood:</strong> test nearby values. A strategy that works only at one exact setting may be overfit.</li>
2123<li><strong>Symbol comparison:</strong> where the logic is intended to generalize, test a comparable instrument without claiming equivalence.</li>
2124<li><strong>Start-date variation:</strong> move the beginning and end dates modestly to see whether one interval drives the story.</li>
2125</ul>
2126
2127<p>Keep an evidence folder containing reports, presets, history-source notes, and a short change log. This simple discipline is more useful than a stack of screenshots because it preserves failed tests as well as favorable ones. A reviewer should be able to see what changed and why confidence rose or fell.</p>
2128
2129<h2 id="code-and-settings">Check the EA and Settings Behind the Report</h2>
2130
2131<p>A Strategy Tester report describes a run, not necessarily the softw
2131are a buyer will receive. Confirm the EA file version, preset file, symbol, and account settings. An input such as a time filter, maximum spread, magic number, risk percentage, or news setting can alter behavior materially. If a report omits inputs, it has omitted part of the experiment.</p>
2132
2133<p>For an authorized owner working with a recovered EA, code review can clarify what the report cannot. It can reveal fixed lot sizing, external dependencies, symbol assumptions, or rules that activate only under certain conditions. The purpose is maintenance and verification, not copying another party’s protected strategy. Readers exploring legitimate source recovery options can begin at the independent <a href="/">ex4 to mq4 decompiler</a> review hub, while keeping ownership and permission questions central.</p>
2134
2135<p>When source is unavailable, behavior can still be documented. Save the inputs, journal messages, report, and test configuration. Repeat the same run before altering settings. If a claimed result cannot be repeated on the stated setup, pause instead of trying settings until a similar graph appears.</p>
2136
2137<h2 id="decision-process">A Decision Process for Honest Use</h2>
2138
2139<p>The following decision steps turn a report from a sales artifact into a bounded research item. They apply whether the EA is free, purchased, custom-built, or recovered with authorization.</p>
2140
2141<ol>
2142<li><strong>Can the run be identified?</strong> If date range, symbol, model, inputs, and EA version are missing, request them. Do not rate the report as reproducible.</li>
2143<li><strong>Does the model fit the logic?</strong> If stops or entries depend on intrabar movement, avoid relying on open-prices results.</li>
2144<li><strong>Are data limitations disclosed?</strong> Note gaps, quality messages, source uncertainty, and broker differences in plain language.</li>
2145<li><strong>Do costs challenge the edge?</strong> Run a reasonable adverse case before drawing a performance conclusion.</li>
2146<li><strong>Is the result stable?</strong> Compare untouched periods and nearby settings. Instability calls for lower confidence.</li>
2147<li><strong>Is risk visible in equity?</strong> Review open exposure, position growth, and loss sequences, not only closed profit.</li>
2148<li><strong>What decision is justified?</strong> Possible answers include reject, investigate further, demo observe, or test at minimal risk. A report alone rarely justifies a large commitment.</li>
2149</ol>
2150
2151<p>This is educational analysis, not financial advice. Each trader’s objectives, capital constraints, venue, and tolerance for loss differ. Historical testing can improve a question, but it cannot remove trading risk.</p>
2152
2153<h2 id="conclusion">Conclusion: Confidence Must Be Earned</h2>
2154
2155<p>MT4 Strategy Tester model quality belongs in the report, but it should not sit above the rest of the evidence. A high reading can be helpful while still leaving questions about the source data, bar path, broker conditions, spread, execution, inputs, and future regimes. A visually attractive report deserves a clearer explanation, not a larger leap of faith.</p>
2156
2157<p>The strongest review habit is simple: preserve the full setup, read the trade mechanics, challenge the assumptions, and state the conclusion at the same level of certainty as the evidence. Readers who need to assess an EA before relying on it can use the site’s <a href="/">mt4 ea decompiler</a> resources alongside careful permissions, code, and report checks. In honest analytics, uncertainty is not a defect to hide. It is information needed for a better decision.</p>
2158`},{slug:"forward-test-recovered-mql4-ea",title:"How to Forward Test a Recovered MQL4 Expert Advisor Safely",metaTitle:"How to Forward Test a Recovered MQL4 Expert Advisor Safely",metaDescription:"Use a controlled demo testing lane, dashboard, and practical shield to forward test recovered MQL4 Expert Advisors before any live deployment decision.",keywords:"forward test recovered MQL4 EA, demo trading dashboard, MQL4 expert advisor checklist, controlled EA testing lane, recovered EX4 robot validation",excerpt:"A recovered MQL4 E
2158xpert Advisor is a hypothesis until it runs safely under current market conditions. This guide shows how to build a demo trading dashboard, a controlled testing lane, and a protective shield around the robot.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"19 min read",featuredImage:wu,imageAlt:"demo trading dashboard monitoring a recovered MQL4 Expert Advisor in a controlled testing lane",tableOfContents:[{id:"why-forward-testing",title:"Why a Recovered EA Needs a Forward Test"},{id:"define-lane",title:"Define the Controlled Testing Lane"},{id:"build-dashboard",title:"Build a Demo Trading Dashboard"},{id:"shield",title:"Put a Protective Shield Around the Robot"},{id:"baseline",title:"Create a Baseline Before Enabling Trades"},{id:"daily-routine",title:"Run a Disciplined Daily Test Routine"},{id:"review-trades",title:"Review Trades as Evidence, Not Stories"},{id:"decision-gates",title:"Use Decision Gates Instead of a Finish Date"},{id:"common-failures",title:"Common Forward-Test Failures"},{id:"handover",title:"Document the Result and Next Step"},{id:"conclusion",title:"The Practical Conclusion"}],content:`
2159<p>A recovered MQL4 Expert Advisor should not move directly from a repaired source file to a live chart. Even when it compiles cleanly and looks familiar, recovery can change names, reveal missing assumptions, or leave small behavior differences that are invisible in a historical test. A forward test answers a narrower and more useful question: how does this exact build behave now, at this broker, with current quotes, spreads, execution rules, and platform events?</p>
2160
2161<p>The safest setting is a deliberately limited demo trading lane. It is not a performance contest and it is not a rehearsal for increasing risk. It is an observation environment with a small number of instruments, fixed settings, recorded expectations, and an operator who can stop the robot. Readers considering an <a href="/" >ex4 to mq4 decompiler</a> should treat recovered code as an engineering artifact first. Its trading claims remain unproven until the behavior is checked in conditions that resemble the intended environment.</p>
2162
2163<img src="${wu}" alt="operator reviewing a demo trading dashboard for a recovered MQL4 Expert Advisor" style="width:100%;border-radius:8px;margin:24px 0;" />
2164
2165<p>This independent review guide explains how to create that lane, build a plain dashboard, and place a practical shield around the robot. ForexMQ5 is discussed here as a third party whose recovery service may provide a starting codebase for users with appropriate rights. This review site does not provide recovery or trading services. Forward testing also cannot prove that an EA will be profitable or safe in every future market. It can, however, expose mismatches early and produce a record for a more measured decision.</p>
2166
2167<h2 id="why-forward-testing">Why a Recovered EA Needs a Forward Test</h2>
2168
2169<p>Backtesting and forward testing answer different questions. A backtest replays selected historical data through the available logic. It is useful for confirming broad mechanics, discovering obvious errors, and comparing an intended rule with an observed result. A forward test watches the EA receive live demo ticks and respond to the platform in real time. The latter includes practical details that historical modelling may simplify or omit: delayed ticks, changing spreads, requotes or rejected orders, server time, symbol suffixes, market closures, and terminal restarts.</p>
2170
2171<p>Recovery adds further reasons to be cautious. Decompiled or reconstructed code may contain generic variable names, substituted structures, or logic that requires review before it accurately represents the original. An omitted custom indicator, a changed default input, or an incorrectly understood pip conversion can alter behavior without producing a compiler error. The compilation result only says that MetaEditor accepts the syntax. It does not certify the strategy, the risk logic, or the broker compatibility.</p>
2172
2173<p>A forward test should therefore test operational fidelity before anyone focuses on returns. Does the EA attach to the intended chart? Does it recognise the broker symbol? Does it calculate position size as expected? Does it avoid duplicate orders after a restart? Does it honour a time filter? Can it close or modify an order under a changing quote? These are observable questions. A dashboard makes them easier to answer without relying on memory or an exciting equity curve.</p>
2174
2175<table>
2176  <thead><tr><th>
2176Question</th><th>Backtest can help</th><th>Forward demo can help</th></tr></thead>
2177  <tbody>
2178    <tr><td>Does the recovered file compile?</td><td>Yes</td><td>Yes</td></tr>
2179    <tr><td>Are entry rules broadly plausible?</td><td>Yes</td><td>Sometimes, over time</td></tr>
2180    <tr><td>Does the broker accept the requested order?</td><td>Limited</td><td>Yes</td></tr>
2181    <tr><td>How does it react to spread changes and disconnects?</td><td>Usually limited</td><td>Yes</td></tr>
2182    <tr><td>Will future results meet an objective?</td><td>No certainty</td><td>No certainty</td></tr>
2183  </tbody>
2184</table>
2185
2186<p>The goal is not to recreate every possible market condition. That would be impossible. The goal is to make avoidable surprises visible while the account is demonstrative and the operator has full control.</p>
2187
2188<h2 id="define-lane">Define the Controlled Testing Lane</h2>
2189
2190<p>A controlled lane is a written boundary around what the robot may do during the test. Start with one broker demo account that resembles the likely production broker. Use one terminal installation dedicated to the test when possible. Keep the account credentials, chart template, EA file version, and input file under version control or at least in a dated folder. Do not add discretionary trades to that account. Manual activity makes the order history harder to interpret.</p>
2191
2192<p>Limit the initial scope. One symbol and one timeframe are easier to monitor than a basket of correlated pairs. If the EA is designed for several symbols, test them in separate lanes or add them one at a time after the prior lane has produced understandable evidence. Use a clearly labelled magic number, such as 37001, and record it in the test sheet. The label is not a risk control by itself, but it distinguishes this EA’s orders from other terminal activity.</p>
2193
2194<h3>Write a lane charter before attaching the EA</h3>
2195
2196<ul>
2197  <li><strong>Purpose:</strong> Verify recovered build R37 behaves as documented on EURUSD H1 demo.</li>
2198  <li><strong>Owner:</strong> Name the person permitted to change settings or stop the test.</li>
2199  <li><strong>Build identity:</strong> File name, compile date, source checksum if available, and input-set version.</li>
2200  <li><strong>Broker context:</strong> Demo server name, account type, symbol spelling, digits, leverage display, and server time zone.</li>
2201  <li><strong>Allowed scope:</strong> One chart, one magic number, one fixed input set, and no manual intervention except documented emergency actions.</li>
2202  <li><strong>Stop conditions:</strong> The specific events that require disabling AutoTrading and investigating.</li>
2203</ul>
2204
2205<p>Set a fixed test hypothesis in ordinary language. For example: “On EURUSD H1, the EA should evaluate once per completed bar, open no more than one position for magic 37001, place a protective stop when it opens, and remain inactive outside its configured session.” The hypothesis is more valuable than a vague expectation of profit because it can be checked trade by trade.</p>
2206
2207<p>Readers who have not yet completed the earlier technical checks should first use the site’s guide to <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validate a recovered MQL4 Expert Advisor before live deployment</a>. That work covers compilation, code review, and initial validation. The forward lane begins after those foundations, not instead of them.</p>
2208
2209<h2 id="build-dashboard">Build a Demo Trading Dashboard</h2>
2210
2211<p>The dashboard does not need specialised software. A spreadsheet, a terminal screenshot folder, and the MT4 Account History and Experts tabs can be sufficient. What matters is that it converts scattered observations into a record that another person can inspect. Update it at the same time each day, preferably after the test session closes. Avoid changing the dashboard columns halfway through unless the reason is documented.</p>
2212
2213<h3>Recommended dashboard panels</h3>
2214
2215<table>
2216  <thead><tr><th>Panel</th><th>Record</th><th>Why it matters</th></tr></thead>
2217  <tbody>
2218    <tr><td>Build panel</td><td>
2218EA version, inputs, magic number, chart, terminal build</td><td>Connects every observation to the exact configuration</td></tr>
2219    <tr><td>Account panel</td><td>Balance, equity, open orders, margin level, daily closed result</td><td>Shows account state without treating a single result as proof</td></tr>
2220    <tr><td>Execution panel</td><td>Requested price, fill price, spread, stop level, error code</td><td>Reveals broker and execution mismatches</td></tr>
2221    <tr><td>Behavior panel</td><td>Signal time, expected action, actual action, explanation</td><td>Tests the written hypothesis</td></tr>
2222    <tr><td>Incident panel</td><td>Restart, disconnect, edit, abnormal order, response</td><td>Preserves events that can distort conclusions</td></tr>
2223  </tbody>
2224</table>
2225
2226<p>For each trade, capture the minimum evidence before interpreting the result: ticket number, open and close times in server time, symbol, direction, volume, entry, stop loss, take profit, commission or swap if shown, and the relevant Experts or Journal message. Include the spread displayed around the decision when it is relevant to the strategy. If the robot calculates lots dynamically, record the inputs and account values used at the moment of calculation.</p>
2227
2228<p>A simple expected-versus-actual log is especially effective. Suppose the code review suggests that a new bar at 10:00 server time should trigger a long order only when two conditions agree. Record whether those conditions were visible, whether the order appeared, and whether its stop was attached. If no order occurred, label it “not yet explained” rather than immediately calling it a bug. The absence might be correct because of a spread filter, a maximum-order rule, or an unseen dependency. Investigation should precede adjustment.</p>
2229
2230<h2 id="shield">Put a Protective Shield Around the Robot</h2>
2231
2232<p>The shield is a set of independent limits that reduces the impact of a coding or configuration error. It is not a promise of protection, and it should not be used to justify a larger test. A recovered EA may include its own safeguards, but an operator should not assume those controls survived recovery or are configured correctly. The most reliable shield combines platform settings, account separation, written stop rules, and human review.</p>
2233
2234<h3>Practical shield checklist</h3>
2235
2236<ol>
2237  <li><strong>Use demo credentials only.</strong> Confirm the terminal shows the intended demo server before enabling AutoTrading.</li>
2238  <li><strong>Keep the account dedicated.</strong> Do not mix another EA, copied signals, or discretionary positions into the lane.</li>
2239  <li><strong>Set conservative EA inputs.</strong> Use the smallest available fixed volume or the least aggressive documented setting while behavior is being observed.</li>
2240  <li><strong>Restrict symbols and charts.</strong> Attach only to the chartered chart. Remove duplicate copies from other charts and profiles.</li>
2241  <li><strong>Disable optional scaling features.</strong> If the EA offers grids, multipliers, recovery modes, or multiple entries, leave them off unless that exact feature is the test subject.</li>
2242  <li><strong>Use a clear emergency action.</strong> Write down who will disable AutoTrading, close demo positions if needed, save logs, and note the time.</li>
2243  <li><strong>Protect the configuration.</strong> Save the approved set file and make changes only through a dated change log.</li>
2244</ol>
2245
2246<p>Some safeguards require careful interpretation. A terminal-level “maximum loss” setting may not exist in the desired form, and a broker demo account may not reproduce every production rule. The operator should not assume that a stop loss guarantees a particular exit price under all conditions. The value of the shield lies in layers and discipline, not in one setting.</p>
2247
2248<p>For a recovery job with a documented right to proceed, the service at ForexMQ5 may be a professional option to evaluate before this testing stage. Its role, as reviewed by this site, is code recovery rather than a claim that the recovered robot is fit for trading. Any testing, configuration, and deployment decision remains with the user.</p>
2249
2250<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
2251  <h3 style="margin-top:0;">Need a Documented Recovery Starting Point?</h3>
2252  <p>This review site identifies ForexMQ5 as a professional option for eligible EX4 to MQ4 recovery requests. Review ownership, permissions, and the planned testing scope before contacting a provider.</p>
2253  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
2254</div>
2255
2256<h2 id="baseline">Create a Baseline Before Enabling Trades</h2>
2257
2258<p>Before the first live demo tick is allowed to trigger an order, take a baseline snapshot. Export or save the input set. Screenshot the chart with the symbol and timeframe visible. Record the terminal and EA version, broker server time, account currency, symbol properties, and the exact place where the EA was installed. Check that any custom indicators, DLL settings, or data files have been deliberately reviewed. Do not enable external dependencies merely to silence an error without understanding why the EA needs them.</p>
2259
2260<p>Then run a no-trade observation period if the EA permits it. Many EAs offer a trading switch, a fixed time window, or an alert mode. If no such setting exists, attach it during a period when its entry conditions are unlikely to be met, while watching the Experts and Journal tabs. The purpose is to confirm initialization, bar detection, symbol recognition, and logging. A silent terminal is not necessarily healthy, but unexplained repeated messages or initialization failures are reasons to stop.</p>
2261
2262<p>Create a configuration comparison table between the backtest and demo environment. Different digits, point values, spread units, and server time are frequent sources of error. A robot that was designed around a five digit EURUSD quote may calculate a stop incorrectly if its recovered point conversion is wrong. Likewise, a session filter based on broker time can activate at a different real-world hour after a server-time change.</p>
2263
2264<h2 id="daily-routine">Run a Disciplined Daily Test Routine</h2>
2265
2266<p>Forward testing becomes unreliable when the operator checks only after an unusual result. Use a repeatable routine. At the start of the relevant session, verify the correct demo account, chart, smiley or enabled status, connection state, and input version. During the session, do not alter settings in response to an open position. At the end, save the day’s observations even if no trade occurred. “No eligible signal observed” is useful evidence when it is attached to the configured window and market context.</p>
2267
2268<h3>Daily operator checklist</h3>
2269
2270<ul>
2271  <li>Confirm the account number and demo server match the lane charter.</li>
2272  <li>Confirm the chart symbol, timeframe, magic number, and EA version.</li>
2273  <li>Review the Experts tab for initialization messages and repeated errors.</li>
2274  <li>Note scheduled platform maintenance, terminal restarts, or connection interruptions.</li>
2275  <li>Log each order, modification, closure, and skipped expected action.</li>
2276  <li>Save a screenshot or export when an incident occurs before attempting a fix.</li>
2277  <li>Record any settings change as a new test phase, not as an invisible correction.</li>
2278</ul>
2279
2280<p>Use phases to prevent accidental curve fitting. Phase A might test order placement with fixed volume and one symbol. Phase B might test session filters after Phase A produces understandable logs. A new input, code edit, broker server, or chart symbol ends the phase. Reset the hypothesis and label the records. Combining results from materially different configurations produces a neat looking but misleading report.</p>
2281
2282<h2 id="review-trades">Review Trades as Evidence, Not Stories</h2>
2283
2284<p>Every trade should be read from trigger to exit. Start with the market and chart state at the decision, then compare the EA’s action with the documented rule. Next inspect execution: requested volume, accepted volume, fill, stop, target, modification messages, and closing reason. Finally classify the event. Useful classifications include expected behavior, expected behavior with execution variance, unexplained behavior, configuration issue, platform issue, and code issue requiring review.</p>
2285
2286<p>Do not let a winning trade end the review. A favorable result can still hide a missing stop loss, an incorrect lot calculation, or an order opened outside the stated session. Similarly, a losing trade is not automatically evidence of a broken EA. It may be a correctly executed trade from a rule that has no assurance of a favorable outcome. The question is whether the system did what the build and test plan said it would do.</p>
2287
2288<p>Broker naming is a frequent source of apparently mysterious behavior. A recovered EA may search for EURUSD while the broker offers EURUSD.a, or it may use a hard-coded suffix in a way that breaks on the selected account. The site’s article on the <a href="/blog/mt4-ea-broker-symbol-name-mismatch-fix">MT4 EA broker symbol name mismatch</a> provides a focused troubleshooting path. Fix the root configuration or code issue, document the revision, and begin a new phase rather than quietly continuing the old one.</p>
2289
2290<h2 id="decision-gates">Use Decision Gates Instead of a Finish Date</h2>
2291
2292<p>Calendar time alone is a weak completion rule. A robot might make no trades during a quiet period, or it might encounter only one type of market condition. Use decision gates that evaluate evidence quality. The first gate is operational: did the EA initialize, remain attached, and handle expected platform events without unexplained errors? The second is behavioral: did each observed action match a documented rule or receive a credible explanation? The third is risk-control: were volume, order 
2292count, protective exits, and session limits observed as intended?</p>
2293
2294<table>
2295  <thead><tr><th>Gate</th><th>Pass evidence</th><th>Hold or stop signal</th></tr></thead>
2296  <tbody>
2297    <tr><td>Operational</td><td>Stable initialization and understandable logs</td><td>Repeated errors, duplicate attachment, unexplained restarts</td></tr>
2298    <tr><td>Behavioral</td><td>Trade decisions reconcile with the test hypothesis</td><td>Unexplained entries, missed exits, or repeated rule mismatch</td></tr>
2299    <tr><td>Control</td><td>Volume and order limits remain within the charter</td><td>Missing protection, unexpected scaling, or excess positions</td></tr>
2300    <tr><td>Evidence</td><td>Records identify the build and all material changes</td><td>Missing logs, mixed manual trades, or undocumented edits</td></tr>
2301  </tbody>
2302</table>
2303
2304<p>A passed gate supports only the next cautious decision, such as continuing the demo phase or arranging an independent code review. It does not establish a recommendation to trade real money. A failed gate is useful too. Disable the EA, preserve the evidence, identify whether the cause is code, configuration, broker environment, or an assumption in the test plan, then retest only after the change is isolated.</p>
2305
2306<p>The review process is easier to manage when the original purpose remains visible. Readers can return to the broader <a href="/">mql4 decompiler</a> review resources for recovery context, but recovery is not the finish line. The responsible next action depends on the quality of the test record and the owner’s stated use case.</p>
2307
2308<h2 id="common-failures">Common Forward-Test Failures</h2>
2309
2310<p>The most damaging errors are usually procedural. One is changing three inputs after a bad trade and then claiming the next trade validates the repair. Another is running the robot on several charts by accident, which can create duplicate positions that look like aggressive strategy logic. A third is relying on balance alone while ignoring open exposure, margin, and missing stops. Each failure makes the evidence harder to interpret.</p>
2311
2312<p>Other problems are technical but still manageable. An EA may rely on a custom indicator that is present in a backtest but absent from the terminal. It may calculate once per tick rather than once per bar, creating a different workload in active markets. It may use OrderSend error handling that retries too broadly, or it may assume a minimum stop distance that differs at the demo broker. None of these findings should be patched blindly. Preserve the message, reproduce the condition where possible, and trace the relevant code path.</p>
2313
2314<p>A useful rule is one change, one reason, one new phase. Record the changed file or input, the reason, the expected effect, and the date. Keep the prior build available for comparison. This small discipline prevents a recovered project from becoming an untraceable sequence of edits.</p>
2315
2316<h2 id="handover">Document the Result and Next Step</h2>
2317
2318<p>At the end of a phase, create a short handover note. State the exact build and configuration tested, broker demo context, start and end dates, number of observed decision events, known limitations, incidents, and unresolved questions. Attach the order export, selected screenshots, relevant logs, and a change list. Avoid replacing evidence with a single return percentage. The record should allow a developer or owner to understand what happened without reopening the entire terminal history.</p>
2319
2320<p>The final decision can be modest. Continue demo observation, request a code correction, obtain an independent review, retire the recovered build, or hold it for non-trading maintenance. If a user later considers a live deployment, that is a separate risk decision requiring their own judgment and appropriate professional input. A demo result does not remove market, operational, or software risk.</p>
2321
2322<h2 id="conclusion">The Practical Conclusion</h2>
2323
2324<p>Forward testing a recovered MQL4 EA safely means building a small laboratory around it: a dedicated demo account, a narrow testing lane, an evidence dashboard, and a shield that limits avoidable mistakes. The operator records expected behavior before watching outcomes, treats anomalies as investigation prompts, and separates every meaningful change into a 
2324new phase.</p>
2325
2326<p>This approach respects what recovery can and cannot deliver. A recovered source file may restore maintainability for an eligible owner, but it does not automatically restore confidence in every trading behavior. Careful demo observation turns assumptions into specific evidence. That is a more useful outcome than a rushed promise, and it leaves the owner with a clear basis for the next decision.</p>
2327`},{slug:"fix-mql4-compiler-warnings-recovered-code",title:"MQL4 Compiler Warnings After Source Recovery: What to Fix First",metaTitle:"Fix MQL4 Compiler Warnings After Source Recovery | MT4 Guide",metaDescription:"A practical priority guide to reading and fixing MetaEditor compiler warnings after MQL4 source recovery, from clean build setup to safe validation.",keywords:"MQL4 compiler warnings, recovered MQL4 code, MetaEditor warnings, fix MQL4 compile warnings, EX4 source recovery validation, clean MT4 compile",excerpt:"Recovered MQL4 source can compile with warnings that range from harmless cleanup items to signs of a changed assumption. This guide shows how to sort MetaEditor messages, repair the right issues first, and treat a clean compile as one checkpoint in a careful validation process.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:xu,imageAlt:"MetaEditor code panel showing MQL4 warning markers and a clean compile result",tableOfContents:[{id:"why-warnings-matter",title:"Why Recovered Code Produces Warnings"},{id:"prepare-workspace",title:"Prepare a Safe MetaEditor Workspace"},{id:"read-results",title:"Read the Compiler Results Panel Correctly"},{id:"priority-order",title:"A Practical Warning Priority Order"},{id:"repair-patterns",title:"Repair Patterns Worth Checking First"},{id:"examples",title:"Examples: Diagnose Before Editing"},{id:"tools",title:"Use MetaEditor Tools Without Losing Evidence"},{id:"clean-compile",title:"What a Clean Compile Does and Does Not Prove"},{id:"validation",title:"Validate Behavior After the Warnings Are Gone"},{id:"handover",title:"Document the Repaired Source"},{id:"conclusion",title:"The Sensible Finish Line"}],content:`
2328<p>Opening recovered MQL4 source in MetaEditor can be both encouraging and unsettling. The familiar structure is back: input declarations, event functions, order logic, indicator calls, and utility routines. Then the Results panel fills with yellow warning markers. A recovered file that compiles with several warnings is not automatically unusable, and a person should not silence messages merely to make the panel look tidy. Each warning is a prompt to compare the compiler's expectation with the reconstructed program.</p>
2329
2330<p>This distinction is especially important after source recovery. A compiler sees types, expressions, and declared functions. It cannot confirm that a recovered condition represents the author's original strategy, that a trade rule suits a particular broker, or that an unused variable is truly irrelevant. Recovery may restore readable code while leaving ambiguous names, simplified expressions, missing comments, or compatibility decisions for a developer to inspect. The first task is therefore triage, not wholesale rewriting.</p>
2331
2332<img src="${xu}" alt="MetaEditor warning markers beside recovered MQL4 code and a successful compile indicator" style="width:100%;border-radius:8px;margin:24px 0;" />
2333
2334<p>This independent review guide explains a cautious workflow for owners and authorised maintainers. It does not claim that a review site performs recovery or code repair. For readers assessing the wider recovery path, the site's explanation of <a href="/">decompile ex4 to mql4</a> options provides useful context on why output should be treated as a starting point for validation rather than as a finished trading system.</p>
2335
2336<h2 id="why-warnings-matter">Why Recovered Code Produces Warnings</h2>
2337
2338<p>Warnings arise when code is syntactically valid enough to generate an EX4 but includes something MetaEditor considers suspicious, outdated, unused, implicit, or potentially unsafe. In ordinary development, warnings can accumulate because a programmer changes direction and leaves an old variable behind. In recovered source, they can also reflect translation choices made while reconstructing compiled instructions into MQL4-like statements. Neither explanation makes a warning safe to ignore.</p>
2339
2340<p>A useful mental model is that messages belong to three layers. The first is build hygiene: unused variables, old event-handler forms, and declarations that can be made clearer. The second is behavior risk: narrowing conversions, unchecked return values, array boun
2340ds assumptions, and string or date conversions. The third is recovery confidence: a warning near lot sizing, price normalization, order placement, or a custom indicator call may identify the exact place where a reconstructed expression deserves human review.</p>
2341
2342<p>The location matters more than the number. Ten unused local variables in a dormant drawing routine may be less urgent than one warning beside a calculated stop loss. Likewise, no warnings do not mean no defect exists. The right outcome is not a cosmetic zero-warning screenshot. It is a documented build where each prior message was removed for a reason, retained deliberately where appropriate, or escalated for deeper investigation.</p>
2343
2344<h2 id="prepare-workspace">Prepare a Safe MetaEditor Workspace</h2>
2345
2346<p>Do not begin by compiling the only copy of a recovered file in a live MT4 data folder. Create a separate working directory, preserve the delivered source unchanged, and give the working copy a meaningful revision name. If the original EX4 is available, retain it too. This separation makes it possible to return to the initial artifact when an edit changes behavior or a later reviewer needs to understand the repair history.</p>
2347
2348<h3>Pre-compile checklist</h3>
2349<ul>
2350  <li>Keep an untouched source-recovery delivery and the associated EX4 in read-only storage.</li>
2351  <li>Record the MT4 terminal build and MetaEditor build used for the compile.</li>
2352  <li>Open the file in the correct folder type: Experts, Indicators, or Scripts.</li>
2353  <li>Identify every included MQH file, custom indicator, DLL reference, and external data dependency.</li>
2354  <li>Use a test terminal profile without a funded account attached.</li>
2355  <li>Save the initial compiler output before changing any line.</li>
2356</ul>
2357
2358<p>The includes deserve special attention. A file can compile cleanly because MetaEditor found an old include on one machine, while another terminal uses a different version or cannot find it at all. Note full paths and versions where possible. If an include was also recovered, label it as such. Replacing a missing dependency with a random file from the internet may remove a compile error while introducing a different strategy or security problem.</p>
2359
2360<p>It is also wise to enable line numbers, inspect the file encoding, and use consistent indentation before attempting repairs. Formatting does not alter behavior, but it exposes unmatched braces, nested conditions, and duplicated blocks. Make a copy before an automatic format or bulk replace. Recovered code may contain generic names such as g_var_12; a carefully chosen rename can help understanding, while a sweeping rename can accidentally alter a symbol in a string, comment, or included file.</p>
2361
2362<h2 id="read-results">Read the Compiler Results Panel Correctly</h2>
2363
2364<p>Compile once without edits and read the Results panel from top to bottom. MetaEditor usually reports the file, line, column, and a message. Double-clicking a row takes the reviewer to the relevant statement, but the line is a starting point, not necessarily the cause. An implicit conversion warning on a function call may originate in the value passed several expressions earlier.</p>
2365
2366<table>
2367  <thead><tr><th>Message category</th><th>Question to ask</th><th>Typical first action</th></tr></thead>
2368  <tbody>
2369    <tr><td>Error</td><td>Can the program be built at all?</td><td>Resolve before judging warnings.</td></tr>
2370    <tr><td>Conversion or type warning</td><td>Can this change a price, volume, ticket, time, or comparison?</td><td>Trace source type and make intent explicit.</td></tr>
2371    <tr><td>Unchecked result warning</td><td>What happens when the call fails?</td><td>Capture the result and define a failure branch.</td></tr>
2372    <tr><td>Unused declaration warning</td><td>Is this a remnant, a missing use, or a planned interface?</td><td>Search references before removal.</td></tr>
2373    <tr><td>Obsolete construct warning</td><td>Does the current terminal still execute this as expected?</td><td>Review event model and documentation.</td></tr>
2374  </tbody>
2375</table>
2376
2377<p>Make a warning register rather than fixing messages directly from memory. A simple table with message text, line, code area, likely impact, action, and retest result turns compiler output into a controlled maintenance task. Group warnings by root cause only after recording their original positions. One global variable declared with the wrong type can trigger many later conversions; changing it once may remove several rows, and that is evidence worth preserving.</p>
2378
2379<p>Be wary of a fast sequence in which a warning is hidden with a cast, the build turns green, and the logic is assumed repaired. An explicit cast tells the compiler to accept a conversion. It does not prove that truncating 0.09 to 0, converting a ticket-sized number to a color, or comparing a datetime to a numeric constant was intended. Casts should state a decision that the reviewer already understands.</p>
2380
2381<h2 id="priority-order">A Practical Warning Priority Order</h2>
2382
2383<p>Prioritize by potential behavioral impact rather than by visual annoyance. Start with the code that can open, alter, or close orders; calculate lots, price, stops, or take profit; select orders; handle times; and consume indicator buffers. Then examine control flow, state variables, and initialization. Cosmetic cleanup belongs at the end.</p>
2384
2385<ol>
2386  <li><strong>Fix build errors and missing dependencies.</strong> A warning review is unreliable while functions, constants, or includes are unresolved.</li>
2387  <li><strong>Inspect trade and risk paths.</strong> Any warning touching OrderSend, OrderModify, OrderClose, volume, price, or StopLoss requires a deliberate review.</li>
2388  <li><strong>Inspect data conversions and array access.</strong> A wrong type or index can create quiet but material differences in signals and calculations.</li>
2389  <li><strong>Inspect return values and error handling.</strong> A failed trading operation or indicator call should not be mistaken for success.</li>
2390  <li><strong>Update event handlers and compatibility constructs.</strong> Ensure initialization and tick processing follow the expected program type.</li>
2391  <li><strong>Clean unused code only after behavior is understood.</strong> Remove dead declarations in small, testable commits.</li>
2392</ol>
2393
2394<p>This ordering prevents a common mistake: spending an hour deleting unused colors and labels while an unchecked order modification is still present. It also separates an engineering decision from a trading decision. A compiler warning can show that an operation was not checked. It cannot decide what retry limit, risk threshold, or trade policy is appropriate. Those choices need an authorised owner who understands the system's intended behavior.</p>
2395
2396<h2 id="repair-patterns">Repair Patterns Worth Checking First</h2>
2397
2398<h3>Implicit numeric conversions</h3>
2399<p>Recovered code may assign a double calculation to an int, or compare values after MQL4 performs a conversion. Inspect the value's role before choosing a type. Price
2399s and lots often need decimal precision. Ticket identifiers and array indexes are integer-like. Time values use datetime. If a calculation produces a broker-facing price, confirm whether normalization to Digits is needed and whether the source expression already accounts for point size. Do not add NormalizeDouble everywhere as a ritual; apply it where the API boundary and price precision make it meaningful.</p>
2400
2401<h3>Unchecked trading and file-operation returns</h3>
2402<p>Functions such as OrderSend, OrderModify, OrderClose, FileOpen, and indicator calls can fail. A recovered routine might issue a call and continue as if it succeeded. Store the return value, test it, retrieve relevant error information promptly, and decide what the calling code should do next. That might be a controlled retry, a logged failure, a state reset, or simply no further action on that tick. The correct branch depends on the original design, so a reviewer should not invent aggressive retries to eliminate a warning.</p>
2403
2404<h3>Arrays, buffers, and loop limits</h3>
2405<p>Warnings around arrays deserve scrutiny when source recovery has made dimensions or indexes unclear. Check whether an array is configured as a series, whether its valid range matches the loop, and whether a custom indicator buffer is read after enough bars exist. A loop that starts at Bars and reads index Bars can be one position beyond the last valid element. Compiling will not prove that a buffer contains a meaningful signal at the requested shift.</p>
2406
2407<h3>Event signatures and initialization</h3>
2408<p>Older MQL4 code may use legacy init, start, and deinit functions, while current code often uses OnInit, OnTick, and OnDeinit forms. A warning about an event function should be treated as a compatibility investigation. Determine whether the file is an Expert Advisor, custom indicator, or script and whether its properties define the expected event model. Renaming handlers without checking parameters and return types can stop core logic from running even though compilation succeeds.</p>
2409
2410<h3>Shadowed and unused variables</h3>
2411<p>An unused variable can be harmless, but it can also reveal that recovery connected a condition to the wrong name or omitted a later use. Search the entire project, including includes. If a variable is only assigned, inspect the nearby code for a likely missing comparison, output, or function argument. If it is genuinely unused, delete it in a single change and compile again. Shadowed variables are more dangerous: an inner declaration with the same name can cause later code to use a local value rather than the intended global state.</p>
2412
2413<h2 id="examples">Examples: Diagnose Before Editing</h2>
2414
2415<p>Consider a warning produced by code resembling the following recovered fragment:</p>
2416<pre><code>int lots = AccountBalance() * RiskFactor;
2417int ticket = OrderSend(Symbol(), OP_BUY, lots, Ask, Slippage, 0, 0, "recovered", Magic, 0, clrBlue);</code></pre>
2418
2419<p>Changing lots to a double may remove the conversion warning, but that is only the first question. Is RiskFactor a direct lot multiplier, a percentage, or an ambiguous recovered constant? Does the broker accept the resulting volume? Is the volume constrained by minimum, maximum, and step? Does the program check whether OrderSend returned a valid ticket? The warning points to a review of intent, units, and failure handling. It is not a license to select a risk formula.</p>
2420
2421<p>A second pattern involves a boolean-like condition represented numerically:</p>
2422<pre><code>if(signalValue = 1)
2423  ClosePositions();</code></pre>
2424
2425<p>This might be a compile error in a given context or it may be visibly suspicious during inspection. The recovery reviewer should not assume the intended comparison was exactly 1. Examine surrounding branches, indicator outputs, and any documentation. If the strategy uses signals of 1, 0, and -1, an equality comparison may be plausible. If signalValue is a price or buffer value, the entire condition may need re-evaluation. The safest repair is supported by evidence, not by the expression that looks most conventional.</p>
2426
2427<p>A third example is an ignored result:</p>
2428<pre><code>OrderModify(OrderTicket(), OrderOpenPrice(), newStop, OrderTakeProfit(), 0, clrNONE);
2429trailActive = true;</code></pre>
2430
2431<p>
2431Setting trailActive to true immediately can leave the EA believing protection exists when modification failed because of a freeze level, invalid stops, or a transient terminal condition. A cautious repair captures the result and only updates state when the operation succeeds. The failure path should retain enough information for testing. This is a high-priority pattern because it connects compiler feedback to live order management.</p>
2432
2433<h2 id="tools">Use MetaEditor Tools Without Losing Evidence</h2>
2434
2435<p>MetaEditor's navigation and search tools can make warning work faster, but each tool should support review rather than replace it. Use Find in Files to locate every call to a risky function or every occurrence of a recovered global. Use Go to Definition to distinguish a local wrapper from a built-in call. Use the compiler's line links to create a focused review list. Where available, compare the edited working copy with the preserved delivery using a diff tool.</p>
2436
2437<p>Repair in small batches. Change one root cause, compile, then inspect the changed warning list. A batch might consist of correcting one declaration and all conversions directly caused by it, or adding result checks to one self-contained trade routine. Avoid a large cleanup that changes types, handler names, formatting, and logic in the same pass. When a later tester finds a difference, small commits make the source of that difference traceable.</p>
2438
2439<h3>Useful repair log fields</h3>
2440<ul>
2441  <li>Original warning text and MetaEditor line number.</li>
2442  <li>Function name and operational area, such as trailing stop or signal calculation.</li>
2443  <li>Evidence used to infer intent, such as a specification, older source fragment, or test observation.</li>
2444  <li>Exact edit and the compiler result after that edit.</li>
2445  <li>Test case needed to exercise the changed path.</li>
2446</ul>
2447
2448<p>For code that cannot be confidently interpreted, add a concise comment identifying the uncertainty rather than pretending the reconstruction is certain. A comment such as “Recovered expression reviewed against available test behavior; original variable meaning unavailable” is more useful to the next maintainer than a polished but invented explanation. Comments should describe observed facts and decisions, not promise profitability or faultless operation.</p>
2449
2450<h2 id="clean-compile">What a Clean Compile Does and Does Not Prove</h2>
2451
2452<p>The clean compile indicator is a meaningful milestone. It shows that the current source, dependencies, and compiler can produce a binary without reported errors or warnings. It improves maintainability, makes future messages easier to see, and demonstrates that obvious static issues received attention. A clean build is also a sensible handover requirement for a repaired source package.</p>
2453
2454<p>It does not prove equivalence to the original EX4, correctness of recovery, safety on a particular broker, or suitability for live trading. Compilers do not know whether an order should have been placed, whether an external indicator is configured correctly, or whether market conditions will expose a branch that the test never reached. A clean compile should therefore be treated as a gate between source repair and functional validation, not as the final sign-off.</p>
2455
2456<p>Readers who are still learning to distinguish declarations, functions, variables, and trade calls can pair this workflow with the site's guide to <a href="/blog/how-to-read-recovered-mql4-expert-advisor-code">reading recovered MQL4 Expert Advisor code</a>. A basic ability to follow data from an input through a calculation and into an order call makes compiler warnings far less mysterious.</p>
2457
2458<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
2459  <h3 style="margin-top:0;">Need an Authorised Recovery Route?</h3>
2460  <p>This review site identifies ForexMQ5 as a professional option for owners and authorised users who need an EX4 recovery process. Any recovered output still needs independent compilation, review, and testing before operational use.</p>
2461  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
2462</div>
2463
2464<h2 id="validation">Validate Behavior After the Warnings Are Gone</h2>
2465
2466<p>After the final compile, test the repaired file in stages. First attach it to a disconnected or demonstration environment and confirm initialization, inputs, chart objects, logs, and expected indicator loading. Next use controlled historical scenarios to exercise entry, exit, error, and no-trade branches. Finally, compare observable behavior against any legitimate reference: documentation, screenshots, prior reports, a known test account, or the original EX4 operating in an isolated environment where permission permits.</p>
2467
2468<table>
2469  <thead><tr><th>Validation stage</th><th>What to observe</th><th>Question it answers</th></tr></thead>
2470  <tbody>
2471    <tr><td>Load test</td><td>Initialization result, missing includes, logged errors</td><td>Can the program start predictably?</td></tr>
2472    <tr><td>Input test</td><td>Changed settings and displayed state</td><td>Are values received in the expected units?</td></tr>
2473    <tr><td>Signal test</td><td>Indicator values and branch selection</td><td>Does the recovered logic reach expected paths?</td></tr>
2474    <tr><td>Trade simulation</td><td>Requested prices, volumes, stops, and return handling</td><td>Are broker-facing calls controlled?</td></tr>
2475    <tr><td>Regression test</td><td>Results before and after each repair batch</td><td>Did a warning fix alter unrelated behavior?</td></tr>
2476  </tbody>
2477</table>
2478
2479<p>Keep the scope modest. A recovered EA may require a qualified MQL4 developer to interpret complex logic, especially around money management, custom DLLs, encryption remnants, or partial output. Testing can reveal a discrepancy, but it may not identify the original author's exact intention. Where rights are unclear, obtain permission before comparing or extracting behavior from a third-party product. Where financial exposure is meaningful, use independent technical and risk review rather than relying on a compiler result.</p>
2480
2481<p>The related guide on <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating recovered MQL4 before live deployment</a> expands the final test discipline. It is particularly useful after warning repairs because it separates build success from order behavior, platform configuration, and cautious observation.</p>
2482
2483<h2 id="handover">Document the Repaired Source</h2>
2484
2485<p>A repair is easier to trust when the next person can reproduce it. Deliver or retain the unchanged recovery output, repaired MQ4 and MQH files, compiler version, final build summary, warning register, dependency list, and test notes. Include a short change log that distinguishes mechanical edits from inferred logic decisions. If a warning was resolved by removing an unused variable, say so. If a condition was rewritten after reviewing available evidence, say what evidence supported that decision.</p>
2486
2487<p>Use descriptive version names and avoid overwriting the original EX4. A practical set might include recovered-original, repaired-build-01, repaired-build-02, and validated-candidate. This simple discipline protects future maintenance. It also prevents a team from mistaking a cleaned-up recovered source for verified original source code.</p>
2488
2489<p>For a general overview of assessing a specialist option rather than experimenting with unverified utilities, readers can review the site's <a href="/">mql4 decompiler</a> information. The review site's position remains clear: ForexMQ5 is a service being reviewed, not a service operated by this site, and technical recovery should be requested only by people with the necessary rights.</p>
2490
2491<h2 id="conclusion">The Sensible Finish Line</h2>
2492
2493<p>Compiler warnings after source recovery should be handled as evidence, not clutter. Begin with a preserved original and a safe workspace. Read each message in context, prioritize trade paths and data conversions, make small evidence-based edits, and retain a log of what changed. A clean MetaEditor compile is 
2493worth achieving because it creates a clearer, more maintainable foundation. It is not proof that the reconstructed system matches the original or that it is ready for real-world use.</p>
2494
2495<p>The best finish line is therefore a clean build plus transparent documentation and controlled validation. That approach respects the limits of recovered code, gives an authorised owner a defensible maintenance record, and makes the next technical decision easier to review.</p>
2496`},{slug:"refactor-recovered-mql4-code-safely",title:"How to Refactor Recovered MQL4 Code Without Changing Trading Behavior",metaTitle:"How to Refactor Recovered MQL4 Code Safely Without Changing Behavior",metaDescription:"A practical MQL4 refactoring workflow for recovered code: create a behavior baseline, make small transformations, and use a test shield before live use.",keywords:"refactor recovered MQL4 code, safe MQL4 refactoring, recovered EA testing, decompiled MQ4 cleanup, preserve EA trading behavior",excerpt:"Recovered MQL4 can be made readable without turning a cleanup into a strategy rewrite. This guide shows how to build a behavior baseline, refactor in small verified steps, and use a test shield to protect trading logic.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"19 min read",featuredImage:ku,imageAlt:"before and after panels showing carefully refactored recovered MQL4 code",tableOfContents:[{id:"why-refactor",title:"Why Recovered Code Needs a Different Refactoring Mindset"},{id:"rights-and-scope",title:"Set the Scope Before Touching a Line"},{id:"behavior-baseline",title:"Build a Behavior Baseline"},{id:"test-shield",title:"Create a Test Shield Around the EA"},{id:"transformation-path",title:"The Careful Transformation Path"},{id:"before-after",title:"Before and After: A Controlled Cleanup"},{id:"high-risk",title:"Changes That Are Not Mere Refactoring"},{id:"validation-matrix",title:"Validate Every Stage"},{id:"handover",title:"Document the Refactored Handover"},{id:"conclusion",title:"Conclusion: Readability Earned by Evidence"}],content:`
2497<p>Recovered MQL4 rarely arrives in the condition a developer would choose for long-term work. Names may be generic, branches may be deeply nested, repeated calculations may be scattered through event handlers, and a simple trading rule may be buried under compiler-shaped temporary variables. Those problems invite a cleanup. The danger is that an apparently cosmetic cleanup can alter when an Expert Advisor evaluates a signal, how it rounds a price, or whether it submits an order at all.</p>
2498
2499<p>This is a guide to refactoring recovered code while treating existing trading behavior as a protected artifact. It is written for owners and authorized maintainers who have a legitimate reason to inspect the code. Readers still need to establish rights before recovery or modification. The site's <a href="/">mql4 decompiler</a> review material explains the recovery context, while this article addresses the engineering work that starts after a readable file exists.</p>
2500
2501<img src="${ku}" alt="before and after panels showing a protected MQL4 refactoring workflow" style="width:100%;border-radius:8px;margin:24px 0;" />
2502
2503<p>The central idea is simple: do not begin by making the program better. Begin by making its observable behavior measurable. Then make one small transformation at a time and compare the result against that baseline. The baseline, comparison procedure, and stop rules form a test shield. They do not prove that a strategy is profitable or suitable for any account. They provide evidence that a maintenance edit did n
2503ot knowingly substitute a different strategy.</p>
2504
2505<h2 id="why-refactor">Why Recovered Code Needs a Different Refactoring Mindset</h2>
2506
2507<p>Normal refactoring begins with source that has some history. A team may know which inputs are public, which routine owns order placement, and why a peculiar condition was added. Recovered code often lacks that context. It may compile after manual repairs, but its original identifiers, comments, include files, build settings, and design decisions may be unavailable. A maintainer is therefore interpreting a program and preserving it at the same time.</p>
2508
2509<p>In this setting, “refactor” should have a narrow meaning: change structure while preserving externally observable behavior for a defined set of conditions. Observable behavior includes more than the final profit figure. It includes initialization results, indicator values, signal timing, attempted order requests, order parameters, modification decisions, log messages relied on by operations, and handling of errors. A change that keeps net profit similar but shifts an entry by one bar is not automatically behavior-preserving.</p>
2510
2511<p>MQL4 makes small differences consequential. Prices have digits and point sizes. Indicators can depend on the current, incomplete bar or a closed bar. Order selection depends on pool and position. A loop can encounter a changing order list. Integer division, implicit conversion, and normalization can affect lot size or stop levels. Moving a call outside an if statement can change the time at which data is read. These are reasons to make the transformation path deliberately boring.</p>
2512
2513<p>Recovered output also deserves humility. It can be a useful reconstruction, yet it may contain guessed names, simplified expressions, missing comments, or source shapes that do not reveal the original author’s intent. A clean-looking version is not proof that the interpretation is correct. The goal is a documented, compilable, testable maintenance version, not a claim that the original source has been perfectly recreated.</p>
2514
2515<h2 id="rights-and-scope">Set the Scope Before Touching a Line</h2>
2516
2517<p>First, define why the code is being changed and what changes are out of bounds. A maintenance ticket such as “rename variables and isolate order submission so an authorized owner can review it” is workable. “Clean it up and improve entries” mixes refactoring with strategy development. Those are separate projects, with separate acceptance criteria and separate test results.</p>
2518
2519<p>Make an immutable working package before editing. It should contain the received MQ4, the original EX4 if available, every required include or preset file, the terminal build information, the symbol and period used for testing, and a checksum for the source files. Put the package under version control or in another system that records every change. A copied folder called final_new is not an adequate audit trail.</p>
2520
2521<table>
2522<thead><tr><th>Question</th><th>Safe answer before refactoring</th><th>Reason</th></tr></thead>
2523<tbody>
2524<tr><td>Who authorized the work?</td><td>Named owner or maintainer with recorded permission</td><td>Recovered code can remain protected software.</td></tr>
2525<tr><td>What is the allowed outcome?</td><td>
2525Readability, maintainability, or a specified defect repair</td><td>It prevents unplanned strategy changes.</td></tr>
2526<tr><td>What must remain stable?</td><td>Inputs, signals, order behavior, and selected logs</td><td>These become comparison targets.</td></tr>
2527<tr><td>What environment is the reference?</td><td>Terminal build, broker settings, data set, symbol, period</td><td>Results without context cannot be reproduced.</td></tr>
2528<tr><td>Who may receive the result?</td><td>Only people with a documented need</td><td>Maintenance access is not permission to redistribute code.</td></tr>
2529</tbody>
2530</table>
2531
2532<p>Write a one-page change charter. List prohibited changes explicitly: no altered default inputs, no new entries or exits, no changed risk formula, no removal of licence or account controls, no performance optimization, and no live deployment during the cleanup. If a discovered defect seems important, log it as a separate issue. The person approving maintenance can then decide whether a behavior-changing repair should be designed and tested independently.</p>
2533
2534<h2 id="behavior-baseline">Build a Behavior Baseline</h2>
2535
2536<p>A baseline is a record of what the starting program does under repeatable conditions. It is not just a Strategy Tester report. A report summary can conceal different trades that happen to produce a similar total. Save enough detail to identify where the two versions diverge.</p>
2537
2538<p>Start with compilation. Record compiler warnings, the terminal build, strict-mode status if used, and all dependencies. Then run a small set of controlled tests before changing anything. One test should be short enough to inspect manually. Another should cover a longer period with different volatility, spreads, and trading sessions. If the EA supports multiple symbols or modes, choose cases that reach each important branch rather than assuming a single backtest covers them all.</p>
2539
2540<h3>Baseline capture checklist</h3>
2541<ul>
2542<li>Export the complete input set, including hidden assumptions such as magic number and slippage.</li>
2543<li>Record symbol spelling, digits, point, tick size if relevant, period, model, date range, spread treatment, and starting deposit.</li>
2544<li>Save detailed tester logs and the full trade list, not merely balance and drawdown summaries.</li>
2545<li>Capture initialization and deinitialization messages, error codes, and any file or global-variable interaction.</li>
2546<li>Record indicator snapshots at selected timestamps, especially immediately before known entries.</li>
2547<li>Note no-trade periods. A missing trade can be as meaningful as a visible one.</li>
2548<li>Hash or archive the exact data and configuration package where practical.</li>
2549</ul>
2550
2551<p>A useful baseline has layers. The first layer is compile parity: the old and new source both build in the intended environment. The second is decision parity: at selected timestamps, the same conditions evaluate the same way. The third is transaction parity: attempted orders and modifications have the same direction, volume, price basis, stop loss, take profit, and magic number. The fourth is outcome parity over a controlled run. Later layers are helpful, but they should not replace earlier ones.</p>
2552
2553<p>When a recovered EA cannot be run because a dependency is unavailable, do not invent a baseline. Mark the limit. Static inspection and isolated test harnesses can still help, but they answer narrower questions. A professional recovery provider may supply code that needs cleanup; it is the maintainer’s responsibility to state what can and cannot be validated in the available environment. For a broader review of safe pre-deployment checks, see <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">this recovered MQL4 validation guide</a>.</p>
2554
2555<h2 id="test-shield">Create a Test Shield Around the EA</h2>
2556
2557<p>The test shield is a set of checks that blocks a structural edit from quietly becoming a trading change. It should run after every small commit, not only when the file looks finished. Its purpose is practical: catch the first divergence close to the edit that caused it.</p>
2558
2559<p>For a modest EA, the shield can be a disciplined manual process. For a larger one, use scripts to compare exported CSV files, logs, and order sequences. The comparison should tolerate only differences that are known to be nondeterministic, such as timestamps in a generated report. Do not broadly ignore differences just to make a comparison pass.</p>
2560
2561<table>
2562<thead><tr><th>
2562Shield layer</th><th>What it compares</th><th>Failure response</th></tr></thead>
2563<tbody>
2564<tr><td>Build gate</td><td>Compile result and warnings</td><td>Stop and fix the structural issue.</td></tr>
2565<tr><td>Input gate</td><td>Public inputs, defaults, types, and ranges</td><td>Revert accidental interface changes.</td></tr>
2566<tr><td>Trace gate</td><td>Selected values and branch decisions at fixed bars</td><td>Locate the first changed decision.</td></tr>
2567<tr><td>Trade gate</td><td>Order attempts, modifications, closes, and errors</td><td>Inspect order-selection and price logic.</td></tr>
2568<tr><td>Regression gate</td><td>Detailed trade list across the reference tests</td><td>Keep the prior commit until explained.</td></tr>
2569</tbody>
2570</table>
2571
2572<p>Instrumentation must itself be handled carefully. Adding Print calls usually should not change logic, but excessive output can obscure logs or affect timing in unusual integrations. Put diagnostic calls behind a compile-time or input-controlled switch, leave that switch off for parity runs, and remove or retain it according to the approved maintenance plan. Never “fix” a mismatch by changing the baseline after the fact without documenting why the old baseline was wrong.</p>
2573
2574<p>Define stop rules. Stop immediately when trade count differs, an order parameter differs, a branch result differs at a checkpoint, a new warning appears, or a calculation changes type unexpectedly. A mismatch is information, not a nuisance. The correct next action is to revert the latest transformation and reduce its size, not to pile more edits onto an uncertain version.</p>
2575
2576<h2 id="transformation-path">The Careful Transformation Path</h2>
2577
2578<p>The safest order is from low semantic risk to high semantic risk. Each stage produces a commit and a shield run. If an earlier stage reveals that the output is not understood, pause there. Readability is valuable only when it is supported by evidence.</p>
2579
2580<ol>
2581<li><strong>Format without changing tokens.</strong> Apply indentation and line breaks. Do not reorder expressions, simplify parentheses, or merge declarations in this pass. Formatting makes control flow visible without claiming an interpretation.</li>
2582<li><strong>Map the program.</strong> Identify event handlers, input declarations, global state, indicator calls, order functions, file access, and error paths. Create a plain-language map outside the code. At this point, generic variables may remain generic.</li>
2583<li><strong>Rename one proven concept at a time.</strong> Rename a variable only after tracing every write and read. Prefer names based on observed role, such as selectedTicket or previousBarTime, rather than assumptions such as trendDirection.</li>
2584<li><strong>Extract a pure calculation.</strong> Move a calculation into a function only when inputs and output are clear and it has no hidden dependence on globals, orders, time, or indicator state. Compare output at several checkpoints.</li>
2585<li><strong>Extract side-effect boundaries.</strong> Isolate order send, modify, close, and logging routines while preserving argument evaluation order, error handling, retries, and return checks.</li>
2586<li><strong>Remove duplication only after proof.</strong> Two blocks that look alike may differ in shift, symbol, normalization, or error handling. Consolidate them only after a side-by-side equivalence review.</li>
2587<li><strong>Add comments and assertions.</strong> Describe observed behavior and uncertainty. Do not write invented history. Assertions should be disabled or carefully controlled in parity runs if they can alter flow.</li>
2588</ol>
2589
2590<p>Keep transformations atomic. A commit titled “rename v17 to selectedOrderTicket” should not also alter a loop condition. Small commits make review possible and make reversion cheap. A reviewer should be able to answer: what changed, why is it believed equivalent, and which shield results support that conclusion?</p>
2591
2592<h2 id="before-after">Before and After: A Controlled Cleanup</h2>
2593
2594<p>Consider a representative fragment from recovered code. It is unattractive, but unattractive code is not permission to simplify it by intuition.</p>
2595
2596<pre><code>double v12 = iMA(NULL, 0, g_period, 0, MODE_EMA, PRICE_CLOSE, 1);
2597double v13 = iMA(NULL, 0, g_period, 0, MODE_EMA, PRICE_CLOSE, 2);
2598if(v12 &gt; v13 &amp;&amp; iClose(NULL, 0, 1) &gt; v12)
2599{
2600  if(OrdersTotal() == 0)
2601    OrderSend(Symbol(), OP_BUY, g_lots, Ask, g_slip, 0, 0, "a", g_magic, 0, clrBlue);
2602}</code></pre>
2603
2604<p>A reckless rewrite might replace it with a fashionable signal helper, cache a moving average, use Bid because it seems more familiar, or add stop loss logic. Every one of those is a behavior change. The controlled first pass only names values whose role has been verified and preserves call order, shifts, prices, and arguments.</p>
2605
2606<pre><code>
2606double currentClosedBarEma = iMA(NULL, 0, movingAveragePeriod, 0, MODE_EMA, PRICE_CLOSE, 1);
2607double priorClosedBarEma = iMA(NULL, 0, movingAveragePeriod, 0, MODE_EMA, PRICE_CLOSE, 2);
2608
2609if(currentClosedBarEma &gt; priorClosedBarEma &amp;&amp; iClose(NULL, 0, 1) &gt; currentClosedBarEma)
2610{
2611  if(OrdersTotal() == 0)
2612    OrderSend(Symbol(), OP_BUY, tradeLots, Ask, allowedSlippage, 0, 0, "a", magicNumber, 0, clrBlue);
2613}</code></pre>
2614
2615<p>This after panel is not automatically correct because names are plausible. The maintainer must trace g_period, g_lots, g_slip, and g_magic to confirm their roles and types. The names should be revised if later evidence contradicts them. More importantly, the test shield should show the same indicator values and order attempts for the reference runs. Only then is the rename defensible.</p>
2616
2617<p>The next commit could extract the condition, but only if the function preserves evaluation timing. For example, calling a helper once per tick may differ from calling it only after an order-count check. In MQL4, order state and market data are not abstract mathematical constants. Preserve the original guard order unless a separate change request explicitly approves a redesign.</p>
2618
2619<h2 id="high-risk">Changes That Are Not Mere Refactoring</h2>
2620
2621<p>Some edits are often described as cleanup but deserve a separate branch, written specification, and fresh acceptance criteria. They may be sensible future improvements, yet calling them refactoring hides their risk.</p>
2622
2623<ul>
2624<li>Changing current-bar shift 0 to closed-bar shift 1, or the reverse.</li>
2625<li>Replacing Ask, Bid, or an unnormalized price with a preferred price convention.</li>
2626<li>Changing OrdersTotal to filtered order selection by symbol or magic number.</li>
2627<li>Adding stop loss, take profit, trailing stops, spread filters, retries, or session filters.</li>
2628<li>Replacing integer or double expressions to “fix” rounding without recorded examples.</li>
2629<li>Changing loop direction where orders can be closed inside the loop.</li>
2630<li>Upgrading indicator calls, time functions, terminal build assumptions, or library behavior.</li>
2631<li>Removing activation, account, expiry, or other controls without clear authorization.</li>
2632</ul>
2633
2634<p>Even a bug fix changes behavior by definition. That does not mean it should never be made. It means the team should identify the old behavior, describe the intended new behavior, build tests that fail before the fix and pass after it, and obtain the appropriate approval. Keeping maintenance refactoring separate from strategy or risk changes gives later reviewers an honest history.</p>
2635
2636<h2 id="validation-matrix">Validate Every Stage</h2>
2637
2638<p>After the final cleanup pass, run a validation matrix rather than a single favorable test. Select cases to exercise boundaries: a flat market, a fast market, a period around a known signal, a time near session transition, a case with open orders, and a case with no orders. If the EA has inputs that materially alter flow, include at least one case for each mode. The objective is coverage of decisions, not a prediction of future performance.</p>
2639
2640<p>Review results in this order: compilation, inputs, initialization, diagnostic checkpoints, attempted transactions, completed transactions, and aggregate report. This order finds causes before symptoms. If a trade summary differs, go back to the earliest differing checkpoint. A late balance difference may originate in a single condition many bars earlier.</p>
2641
2642<p>A second reviewer adds real value. Give that reviewer the change charter, before and after source, commit list, baseline package, comparison output, and unresolved assumptions. Ask them to challenge names and equivalence claims. An independent review site can recommend that users consider specialists for authorized recovery work, but it should not imply that the review site itself performs that work. The service at ForexMQ5 may be a relevant professional option where the requester has rights and needs a recovery path; validation and approval remain the owner’s responsibility.</p>
2643
2644<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
2645  <h3 style="margin-top:0;">Need an Authorized Recovery Starting Point?</h3>
2646  <p>ForexMQ5 is reviewed as a professional recovery option for owners and authorized maintainers. Confirm rights, preserve the original file, and plan validation before requesting any work.</p>
2647  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
2648</div>
2649
2650<h2 id="handover">Document the Refactored Handover</h2>
2651
2652<p>A readable source file is not the whole handover. Future maintainers need to know what was observed, what was changed, and what remains uncertain. Include a change log that links each commit to its shield result. Retain the original recovered version, but restrict access according to the applicable rights and agreements.</p>
2653
2654<p>The handover package should name the required terminal build, dependencies, compiler settings, inputs, tested symbols and periods, data limitations, and known unresolved behavior. It should also distinguish verified facts from hypotheses. “Variable renamed after tracing all writes and reads” is a fact supported by review. “This block was probably intended as a news filter” is a hypothesis and should be labeled as such.</p>
2655
2656<p>Use the same discipline for operational instructions. Explain how to reproduce the reference tests, where to find outputs, and which differences should stop deployment. Do not turn a passing historical test into a promise about future trading results. Market conditions, execution, data quality, broker rules, and platform changes can all affect live behavior. A test shield protects a specific comparison, not every future outcome.</p>
2657
2658<p>For readers organizing a larger maintenance transfer, the site’s guide to <a href="/blog/mql4-recovery-handover-documentation-plan">MQL4 recovery handover documentation</a> provides a complementary checklist. The right documentation makes it less likely that a later editor will repeat the same archaeology.</p>
2659
2660<h2 id="conclusion">Conclusion: Readability Earned by Evidence</h2>
2661
2662<p>Recovered MQL4 should not be treated as a blank canvas. It is a working artifact whose behavior may matter even when its structure is awkward. The safe path is to establish authorized scope, freeze the starting point, capture a detailed baseline, construct a test shield, and make tiny transformations that can be explained and reversed.</p>
2663
2664<p>Formatting and verified renames are usually a reasonable beginning. Extracting calculations and isolating order functions can follow when evidence supports equivalence. Changes to signal timing, prices, risk, order filtering, or controls belong in a different project because they change what the EA does. This distinction protects both the code and the people responsible for it.</p>
2665
2666<p>Ultimately, good refactoring is not judged by how elegant the after panel looks. It is judged by whether each improvement has a clear reason, a narrow diff, and test evidence that the intended trading behavior remained intact. That standard may feel slower, but it is the practical route from recovered code to maintainable code.</p>
2667
2668<p>Before undertaking recovery or cleanup, readers can also review the site's <a href="/">ex4 to mq4</a> resources to understand the wider process and its limitations.</p>
2669`},{slug:"document-mt4-ea-input-parameters",title:"How to Document MT4 EA Input Parameters for Safer Operation",metaTitle:"How to Document MT4 EA Input Parameters for Safer Operation",metaDescription:"Turn an MT4 Expert Advisor settings panel into clear technical documentation with parameter definitions, safe ranges, dependencies, change control, and verification steps.",keywords:"MT4 EA input parameters, Expert Advisor settings documentation, MQL4 parameter guide, MT4 EA risk settings, document EA inputs",excerpt:"An MT4 settings panel is not operational documentation. This practical guide shows how an EA owner can record each input, its meaning, safe operating context, dependencies, and verification evidence before changing a live chart.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:Au,imageAlt:"organized technical documentation created from an MT4 Expert Advisor input settings panel",tableOfContents:[{id:"why-document",title:"Why the Inputs Tab Is N
2669ot Documentation"},{id:"capture-baseline",title:"Capture an Accurate Baseline"},{id:"parameter-record",title:"Build a Useful Parameter Record"},{id:"classification",title:"Classify Inputs by Operational Effect"},{id:"dependencies",title:"Map Dependencies and Hidden Assumptions"},{id:"risk-controls",title:"Document Risk Controls Carefully"},{id:"examples",title:"Worked Documentation Examples"},{id:"change-process",title:"Use a Controlled Change Process"},{id:"handover",title:"Prepare the Record for Handover"},{id:"conclusion",title:"Conclusion"}],content:`
2670<p>An MT4 Expert Advisor can expose dozens of inputs in one small dialog. A label such as Lots, MagicNumber, UseFilter, or GMTOffset may look self-explanatory until somebody has to move the EA to a new chart, explain a past trade, or change one setting after the original developer is unavailable. The Inputs tab is a list of values, not a technical record. It rarely explains what a value controls, which other values it relies on, what conditions make it unsuitable, or who approved it.</p>
2671
2672<p>Converting that panel into organized documentation is a practical safety task. It helps an owner distinguish harmless display preferences from settings that can change order size, duplicate activity, session timing, or exit behavior. It also makes a future review more efficient because the person reading the record can see what is known, what was tested, and what remains an assumption. This guide discusses documentation for EAs a reader owns or is authorized to operate. It does not suggest bypassing a vendor licence, altering protected software, or treating a settings explanation as financial advice.</p>
2673
2674<img src="${Au}" alt="MT4 Expert Advisor settings panel organized into a technical parameter document" style="width:100%;border-radius:8px;margin:24px 0;" />
2675
2676<h2 id="why-document">Why the Inputs Tab Is Not Documentation</h2>
2677
2678<p>MT4 displays an input name, a current value, and sometimes a short comment supplied by the author. That is useful at the point of attachment, but it omits operational context. Consider an input called MaxSpread. Is it measured in points, pips, or a broker-specific price increment? Does zero disable the check, mean an impossible threshold, or invoke an internal default? Does the EA read it only on a new trade or also while managing an existing position? A screenshot cannot answer these questions.</p>
2679
2680<p>Good documentation replaces guesswork with an explicit statement of evidence. It separates a confirmed fact, such as a value visible in the live chart properties, from an interpretation inferred from a name. It also records the terminal build, broker server, symbol spelling, timeframe, EA file name, and date. Those details matter because a set file copied between brokers or symbols can retain values while changing their practical meaning.</p>
2681
2682<p>This effort is especially important when several people touch an account. An operator may believe a setting is “the normal setup” while a developer assumes the operator knows that a news filter needs a local file. A VPS administrator may restore a terminal without its custom indicator. In each case, a concise parameter register makes the missing assumption visible. For a broader explanation of how compiled robots and readable source differ, the site’s <a href="/blog/mql4-to-ex4-compilation-explained">MQL4 to EX4 compilation guide</a> gives helpful background.</p>
2683
2684<p>Documentation does not make an unknown EA safe, profitable, or suitable for a particular account. Its job is narrower and valuable: make configuration decisions traceable, reduce accidental changes, and create a reliable starting point for testing. Where an authorized maintenance project later requires readable code, the review site’s overview of <a href="/">ex4 to mq4</a> recovery options can help frame the technical choices.</p>
2685
2686<h2 id="capture-baseline">Capture an Accurate Baseline</h2>
2687
2688<p>Start by documenting an instance, not an EA name in the abstract. The same EX4 can run differently on EURUSD M15 and XAUUSD H1, or on two accounts with different leverage, suffixes, and contract specifications. Give each installed instance an identifier such as London-EURUSD-M15-01. Do not use an identifier that reveals account credentials.</p>
2689
2690<p>Before changing anything, collect a baseline from the terminal that is known to be operating. Open the chart properties, record every input exactly as displayed, and save the settings as a set file where authorization permits. Record the file name and a checksum for the EX4 if the team has a normal process for doing so. Keep the raw screenshot or exported set file as evidence, then create a human-readable register from it. The raw capture protects against transcription mistakes; the register explains the configuration.</p>
2691
2692<table>
2693<thead><tr><th>
2693Baseline item</th><th>Why it belongs in the record</th><th>Example</th></tr></thead>
2694<tbody>
2695<tr><td>Instance ID</td><td>Separates one chart installation from another</td><td>EU-M15-LDN-01</td></tr>
2696<tr><td>EA file and version</td><td>Prevents a newer file being confused with an old setup</td><td>RangeGuard_v3.2.ex4</td></tr>
2697<tr><td>Terminal and broker context</td><td>Captures environment-sensitive behavior</td><td>MT4 build, server, symbol, digits</td></tr>
2698<tr><td>Chart context</td><td>Records where the EA is attached</td><td>EURUSD, M15, one chart</td></tr>
2699<tr><td>Input snapshot</td><td>Preserves exact starting values</td><td>Set file plus dated screenshot</td></tr>
2700<tr><td>Observed state</td><td>Distinguishes a working baseline from an untested import</td><td>Initialized, no repeated errors observed</td></tr>
2701</tbody>
2702</table>
2703
2704<p>Capture only information that is useful and safe to store. Passwords, investor credentials, licence keys, and personal account data should not be placed in a shared parameter document. Instead, note that a credential or activation prerequisite exists and identify the approved custodian or secure location under the organization’s normal access rules.</p>
2705
2706<h3>A baseline capture checklist</h3>
2707<ul>
2708<li>Confirm the chart symbol, timeframe, and broker server before opening Inputs.</li>
2709<li>Copy labels and values exactly, including capitalization and decimal places.</li>
2710<li>Record whether AutoTrading is enabled and whether the chart shows normal initialization.</li>
2711<li>Note custom indicators, files, DLL permission, web requests, or external data that the EA is known to require.</li>
2712<li>Review the Experts and Journal tabs for meaningful initialization messages, without assuming a quiet log proves correct behavior.</li>
2713<li>Store the source capture with a date and the name of the person who made it.</li>
2714</ul>
2715
2716<h2 id="parameter-record">Build a Useful Parameter Record</h2>
2717
2718<p>A register works best when each row answers the question an operator will ask under pressure: what is this, what can it affect, and how should a change be handled? Avoid a vague description such as “trade setting.” State the observable function, the value type, the current approved value, units, source of understanding, and any uncertainty.</p>
2719
2720<table>
2721<thead><tr><th>Field</th><th>Purpose</th></tr></thead>
2722<tbody>
2723<tr><td>Exact input name</td><td>Matches the MT4 panel and avoids ambiguity.</td></tr>
2724<tr><td>Plain-language purpose</td><td>Explains the behavior it appears to control without overstating certainty.</td></tr>
2725<tr><td>Current value and type</td><td>Shows the approved value and whether it is a number, Boolean, text, or enumeration.</td></tr>
2726<tr><td>Unit and scope</td><td>States points, lots, minutes, percent, currency, or another unit, plus when the EA reads it.</td></tr>
2727<tr><td>Allowed or tested values</td><td>Records vendor guidance or values tested in the documented environment, not invented universal limits.</td></tr>
2728<tr><td>Dependencies</td><td>Lists linked inputs, symbol properties, files, permissions, and platform assumptions.</td></tr>
2729<tr><td>Operational effect</td><td>Flags whether it can affect entries, exposure, exits, identification, or display only.</td></tr>
2730<tr><td>Evidence and owner</td><td>Names the manual, test, authorized developer statement, or observed behavior behind the entry.</td></tr>
2731</tbody>
2732</table>
2733
2734<p>Use careful language. If a manual confirms that StartHour is server time, document it as confirmed. If the name suggests server time but no source confirms it, write “time basis not confirmed; do not change until tested or clarified.” That small distinction can prevent a confident but harmful assumption. Do not reverse-engineer a third-party EA merely to fill gaps. Ask the vendor, consult authorized documentation, or retain the uncertainty as an action item.</p>
2735
2736<p>Descriptions should be concrete enough for a second person to operate the system. “Enables filter” is poor documentation. “When true, the EA appears to reject new entries when the current spread exceeds MaxSpread; behavior on existing orders has not been verified” is more useful because it gives both a likely function and a boun
2736dary on the claim.</p>
2737
2738<h2 id="classification">Classify Inputs by Operational Effect</h2>
2739
2740<p>Not every setting deserves the same approval path. Classification brings focus to values that can create real operational changes. A four-level model is usually enough for an individual trader or small team.</p>
2741
2742<ol>
2743<li><strong>Informational or cosmetic:</strong> panel colors, labels, logging verbosity, and display switches. These can still matter for diagnosis, but normally do not alter orders.</li>
2744<li><strong>Environment and identity:</strong> magic numbers, symbols, time zones, order comments, account filters, file paths, and session settings. A mistake can make an otherwise sound configuration operate in the wrong place or fail to recognize its own trades.</li>
2745<li><strong>Entry and exit logic:</strong> indicator periods, thresholds, trading windows, stop-loss settings, take-profit settings, trailing rules, and filters. These can materially change the strategy’s behavior.</li>
2746<li><strong>Exposure and protection:</strong> fixed lots, risk formulas, maximum orders, drawdown limits, spread limits, and recovery switches. These require the strongest review because they may affect account exposure.</li>
2747</ol>
2748
2749<p>Add a simple change class to each row: view-only, routine, review-required, or do-not-change-without-authorized-guidance. The labels are internal process controls, not claims about regulatory safety. For example, changing a panel color might be routine, while changing a magic number on an account where another EA is active should be review-required. A setting labelled RecoveryMode or Multiplier should never be assumed benign because its exact behavior can vary by author.</p>
2750
2751<p>When documenting an unfamiliar robot, classify by potential effect rather than by confidence in the label. A value called UseSafeMode might sound protective, yet it could disable entries, close positions, or simply change logging. Mark it as unverified until an authorized source or controlled test establishes what it does.</p>
2752
2753<h2 id="dependencies">Map Dependencies and Hidden Assumptions</h2>
2754
2755<p>The most costly configuration errors often occur between fields. A session start time depends on a time reference. A spread ceiling depends on price digits. A risk percentage may depend on the EA’s definition of balance, equity, stop distance, and tick value. A magic number only works as intended if no other installation shares it. A parameter register should therefore include a dependency column and a short configuration note for every high-impact value.</p>
2756
2757<h3>Questions that expose dependencies</h3>
2758<ul>
2759<li>Does this input only apply when another Boolean is enabled?</li>
2760<li>What is the unit, and does broker digit formatting change it?</li>
2761<li>Is the time based on broker server, local computer, UTC, or a manually entered offset?</li>
2762<li>Does the EA use this setting at initialization, at each tick, only before entry, or during order management?</li>
2763<li>Must a custom indicator, data file, URL permission, or DLL permission be present?</li>
2764<li>Does a zero, blank value, or false setting disable a feature or select an internal default?</li>
2765<li>Can another EA, manual trade, or copied chart conflict with this identifier?</li>
2766</ul>
2767
2768<p>Put dependencies in a form an operator can act on. Instead of writing “requires broker conditions,” write “MaxSpread unit is not confirmed for five-digit quotes. Do not transfer this value to another broker until the unit is verified in a controlled environment.” Instead of “uses indicator,” record the indicator’s exact file name, expected folder, and whether its buffers or settings must match the documented chart.</p>
2769
2770<p>Symbol translation deserves special attention. A set file created for EURUSD may be attached to EURUSD.a, EURUSDm, or a CFD symbol with different spread and tick conventions. The site’s guide to an <a href="/blog/mt4-ea-broker-symbol-name-mismatch-fix">MT4 EA broker symbol-name mismatch</a> explains why an EA can appear inactive after a broker change. Include the intended symbol spelling in the register, not merely the currency pair name.</p>
2771
2772<h2 id="risk-controls">Document Risk Controls Carefully</h2>
2773
2774<p>Risk-related inputs need more context than any other category. A lot value is not a complete description of exposure. Its practical effect can depend on instrument contract size, account currency, leverage, open positions, and whether the EA can add orders. Similarly, a stop-loss label does not establish that every order will have a stop, that the stop is broker-side, or that it will limit loss under all market conditions.</p>
2775
2776<p>Document what the setting is intended or observed to do, the evidence for that statement, and what it does not establish. “FixedLot = 0.10, confirmed in approved set file. Entry volume observed in a demo test on EURUSD only. Does not confirm behavior after partial fills, error recovery, or other symbols” is responsible. “0.10 is safe” is not. Suitability depends on circumstances and should be assessed by the account owner or an appropriately qualified adviser where needed.</p>
2777
2778<table>
2779<thead><tr><th>
2779Input family</th><th>Documentation questions</th><th>Common caution</th></tr></thead>
2780<tbody>
2781<tr><td>Lot or risk sizing</td><td>Fixed or calculated? What balance or equity input is used? Is there a minimum lot rule?</td><td>A percentage label may not use the formula the operator expects.</td></tr>
2782<tr><td>Maximum trades</td><td>Per symbol, direction, chart, magic number, or account?</td><td>A cap may ignore manually opened or differently tagged orders.</td></tr>
2783<tr><td>Stop and target</td><td>Points, pips, price, or volatility multiple? Placed with order or managed later?</td><td>Broker minimum distances and fast markets can affect execution.</td></tr>
2784<tr><td>Recovery features</td><td>Can it average, multiply, hedge, or reopen? What enables it?</td><td>Do not enable an unclear recovery feature on the basis of its name.</td></tr>
2785<tr><td>Daily limits</td><td>Server-day or local-day boundary? Realized loss only or floating loss too?</td><td>A restart or time offset can change how a boundary is observed.</td></tr>
2786</tbody>
2787</table>
2788
2789<p>For every exposure-related row, add a decision note: retain because it is the approved baseline, test in a non-live environment, seek clarification, or do not alter. This turns documentation into an operational guardrail without pretending it can predict trading outcomes.</p>
2790
2791<h2 id="examples">Worked Documentation Examples</h2>
2792
2793<p>The examples below are templates, not descriptions of any particular EA. They illustrate the level of precision that is useful when a label alone is inadequate.</p>
2794
2795<h3>Example 1: MaxSpread</h3>
2796<p><strong>Current value:</strong> 25. <strong>Classification:</strong> exposure and protection. <strong>Purpose:</strong> likely prevents new entries above a configured spread threshold. <strong>Unit:</strong> not confirmed. <strong>Dependencies:</strong> quote digits and broker spread convention. <strong>Evidence:</strong> value captured from approved instance; no vendor manual available. <strong>Change rule:</strong> review-required. <strong>Verification:</strong> use a controlled observation with recorded bid, ask, and spread display before concluding whether 25 means points or another unit.</p>
2797
2798<h3>Example 2: MagicNumber</h3>
2799<p><strong>Current value:</strong> 24015. <strong>Classification:</strong> environment and identity. <strong>Purpose:</strong> likely identifies orders managed by this instance. <strong>Dependencies:</strong> must be unique among EAs that may trade or manage orders on the same account. <strong>Operational note:</strong> changing it while orders are open may affect recognition, depending on the EA design. <strong>Change rule:</strong> do not change during active order management without an authorized plan and a rollback note.</p>
2800
2801<h3>Example 3: TradeStart and TradeEnd</h3>
2802<p><strong>Current values:</strong> 08:00 and 16:00. <strong>Classification:</strong> entry and exit logic. <strong>Purpose:</strong> likely restricts new trades to a session window. <strong>Time basis:</strong> unconfirmed. <strong>Dependencies:</strong> broker server offset, daylight-saving changes, and any separate GMTOffset input. <strong>Verification:</strong> compare terminal server time with the documented schedule before a session change. <strong>Limit:</strong> no claim should be made that existing positions will close at TradeEnd unless documentation or testing confirms it.</p>
2803
2804<h3>Example 4: UseNewsFilter</h3>
2805<p><strong>Current value:</strong> true. <strong>Classification:</strong> entry and exit logic. <strong>Purpose:</strong> likely suppresses entries around selected events. <strong>Dependencies:</strong> an external calendar source, local file, web permission, or built-in schedule may be required. <strong>Evidence:</strong> initialization message should be captured if available. <strong>Failure behavior:</strong> unknown until tested or confirmed. <strong>Change rule:</strong> review-required, because a true value is not evidence that event data is actually arriving.</p>
2806
2807<h2 id="change-process">Use a Controlled Change Process</h2>
2808
2809<p>Documentation has little value if changes occur only in memory. A small change record 
2809is enough for most setups. Before modifying an input, state the reason, the exact old and proposed value, the instance affected, expected behavior, dependency check, approver where relevant, test method, and rollback value. Save a new set file instead of overwriting the only known-working one.</p>
2810
2811<ol>
2812<li><strong>Define the reason.</strong> Tie the change to a specific issue, such as a broker symbol migration or a confirmed schedule update. “Trying settings” is not a sufficient operational reason.</li>
2813<li><strong>Assess the category.</strong> Cosmetic, environment, logic, and exposure changes should not receive identical treatment.</li>
2814<li><strong>Check dependencies.</strong> Confirm symbol, timeframe, terminal, permissions, files, time reference, and overlapping EAs.</li>
2815<li><strong>Make one related change set.</strong> If two inputs must change together, document the relationship. Avoid changing a dozen unrelated values at once.</li>
2816<li><strong>Test and observe.</strong> Use an appropriate controlled environment where possible. Record initialization, expected prerequisites, and unexpected messages.</li>
2817<li><strong>Approve or roll back.</strong> Promote the new baseline only after the stated checks. Otherwise restore the saved value and record why.</li>
2818</ol>
2819
2820<p>Never use a short test as proof that a strategy will perform as expected. Testing can confirm configuration facts such as whether the EA initializes, recognizes a symbol, or reads an input. It cannot remove market, execution, software, or model risk. Readers evaluating a recovered or modified EA should also consult the site’s <a href="/">MT4 EA decompiler</a> review material for the distinction between obtaining editable code and validating operational behavior.</p>
2821
2822<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
2823  <h3 style="margin-top:0;">When Documentation Reveals a Source-Code Gap</h3>
2824  <p>If an authorized owner needs maintainable source for a documented repair, migration, or audit, ForexMQ5 is reviewed as a professional EX4-to-MQ4 recovery option. The owner should preserve entitlement records and define the permitted scope before requesting work.</p>
2825  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
2826</div>
2827
2828<h2 id="handover">Prepare the Record for Handover</h2>
2829
2830<p>A parameter register should let a new operator understand the installed configuration without discovering it through live trial and error. Put a one-page overview before the detailed table. Name the EA instance, purpose, approved environment, known prerequisites, owner, emergency contact route, last review date, and locations of the original set file and screenshots. Keep access details outside the document.</p>
2831
2832<p>Then include an exceptions section. This is where the document becomes trustworthy. List inputs whose meaning is uncertain, vendor guidance that has not been verified in the current environment, unresolved warnings, and features intentionally disabled. A blank exceptions section can be correct, but only after a real review. Do not erase uncertainty to make a handover look cleaner.</p>
2833
2834<p>Set a review trigger rather than relying only on a calendar. Update the document when the EA file changes, the broker changes, a VPS is moved, a symbol suffix changes, a custom dependency is replaced, or an operator changes an input. A periodic review is still sensible for confirming that the live chart matches the approved baseline. Compare the current Inputs tab against the register line by line and record differences, including justified temporary ones.</p>
2835
2836<h3>Handover package checklist</h3>
2837<ul>
2838<li>Instance overview and current approved parameter register.</li>
2839<li>Dated source capture and permitted set-file archive.</li>
2840<li>Environment record for broker, symbol, timeframe, terminal, and dependencies.</li>
2841<li>Change log with evidence, test notes, and rollback values.</li>
2842<li>Open questions and the person or vendor authorized to answer them.</li>
2843<li>Access-controlled location for sensitive credentials, separate from the general document.</li>
2844</ul>
2845
2846<p>If the documentation exercise exposes a need to inspect source, start with rights rather than tools. An owner should confirm authorship, assignment, or written authorization and keep the goal limited to maintenance, authorized audit, or recovery. ForexMQ5 is presented on this independent review site as a professional option for legitimate EX4 recovery needs, not as a substitute for permission, technical validation, or a vendor-supported update.</p>
2847
2848<h2 id="conclusion">Conclusion</h2>
2849
2850<p>A well-run MT4 EA should not depend on one person remembering that “25 is the right number.” Turn each settings panel into a documented baseline: capture exact values, explain only what the evidence supports, identify dependencies, classify operational impact, and record every meaningful change. Give exposure-related settings the strongest review, preserve unknowns openly, and test configuration behavior before accepting a new baseline.</p>
2851
2852<p>The result is not a promise of trading performance. It is a safer operational record that helps prevent configuration drift, supports a controlled handover, and g
2852ives an authorized owner a clearer foundation for maintenance decisions. That is the useful transformation: an opaque list of inputs becomes technical documentation that people can review, question, and use responsibly.</p>
2853  `},{slug:"verify-ex4-file-integrity-hash",title:"How to Verify EX4 File Integrity With Hashes and Controlled Copies",metaTitle:"How to Verify EX4 File Integrity With Hashes | MT4 Guide",metaDescription:"Learn a practical, rights-conscious method for fingerprinting EX4 files with hashes, controlling duplicates, documenting handoffs, and investigating unexpected changes.",keywords:"verify EX4 file integrity, EX4 hash check, EX4 file fingerprint, MT4 EA duplicate file control, cryptographic hash EX4, EX4 controlled copy",excerpt:"An EX4 name and timestamp do not prove that a file is the one originally received. This guide explains how MT4 users can use cryptographic hashes, controlled copies, and simple records to identify the exact binary under review.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:Tu,imageAlt:"cryptographic hash verification workflow for an EX4 Expert Advisor file",tableOfContents:[{id:"why-integrity",title:"Why an EX4 Needs an Integrity Record"},{id:"hash-basics",title:"What a Cryptographic Hash Actually Proves"},{id:"baseline",title:"Build a Baseline Before Moving Anything"},{id:"controlled-copies",title:"Create Controlled Copies Without Confusion"},{id:"commands",title:"Calculate and Compare Hashes"},{id:"interpret-results",title:"Interpret Matches and Mismatches"},{id:"duplicate-investigation",title:"Investigate Duplicate EX4 Files"},{id:"handoffs",title:"Use an Integrity Shield During Handoffs"},{id:"recovery-context",title:"Hashing a File for Recovery or Review"},{id:"checklist",title:"Practical Integrity Checklist"},{id:"conclusion",title:"Conclusion"}],content:`
2854<p>An EX4 file can look familiar while being a different binary. A filename such as GoldRobot.ex4 may be copied from a download folder to several MetaTrader 4 terminals, renamed by Windows, sent through chat, and replaced by a vendor update. Months later, a user may be unable to tell which exact build produced a result, which file was examined, or whether a transfer changed anything. File names, modified dates, and screenshots help, but they are not fingerprints.</p>
2855
2856<p>A cryptographic hash is a short calculated value that identifies the byte content of a file. When two independently calculated hashes match using the same algorithm, the files are overwhelmingly likely to be byte-for-byte identical. When the hashes differ, something in the bytes differs, even if both files have the same name, size, or visible behavior. This makes a hash a practical foundation for an EX4 integrity shield: a simple process that preserves an original, labels working copies, and records what moved between people or machines.</p>
2857
2858<img src="${Tu}" alt="cryptographic hash verification workflow for an EX4 Expert Advisor file" style="width:100%;border-radius:8px;margin:24px 0;" />
2859
2860<p>This is an educational guide from an independent review site. It is not a malware verdict, a promise that an Expert Advisor will trade as expected, or permission to inspect software that belongs to someone else. A matching hash shows identical file content, not safety, ownership, quality, or authorization. Before sharing an EX4 for any analysis, the user should confirm the licence and their right to do so. Readers needing background on file types can start with <a href="/">ex4 decompiler</a> resources, then apply the controls below to the file they are actually entitled to handle.</p>
2861
2862<h2 id="why-integrity">Why an EX4 Needs an Integrity Record</h2>
2863
2864<p>MT4 loads compiled Expert Advisors as EX4 binaries. Unlike a text document, the file cannot be meaningfully inspected by opening it in a normal editor. This makes quiet substitutions hard to spot. A supplier may release a new build under the same product name. An installer may place a copy in one terminal while an older copy remains in another. A colleague may send back a file with an added suffix. A backup application can preserve a different version than the one attached to a chart.</p>
2865
2866<p>Integrity records prevent an ordinary operational problem from becoming a guessing exercise. They answer narrow, useful questions:</p>
2867
2868<ul>
2869<li>Was the file copied to the test terminal exactly the same as the preserved original?</li>
2870<li>Did a vendor update alter the binary, or did only its filename and timestamp change?</li>
2871<li>
2871Which binary was sent for an authorized technical review?</li>
2872<li>Are two files in separate folders truly duplicates, or merely similarly named versions?</li>
2873<li>Can a user reproduce a backtest or troubleshooting observation using the same build?</li>
2874</ul>
2875
2876<p>Those questions matter because MT4 installations often accumulate over time. There may be a primary terminal, a VPS terminal, a local test installation, archived downloads, and a broker-specific installation. The apparent convenience of copying a robot into every Experts folder can leave an operator with five candidate files and no trustworthy baseline. Hashing costs little and does not alter the file. It converts “I think this is the one” into a recorded comparison.</p>
2877
2878<p>Integrity should be kept separate from performance claims. A hash cannot tell an operator whether settings are suitable, whether historical data is reliable, or whether an EA's strategy is appropriate for an account. It only establishes identity at the file level. That limited role is precisely why it is valuable. The record can be accurate without making claims it cannot support.</p>
2879
2880<h2 id="hash-basics">What a Cryptographic Hash Actually Proves</h2>
2881
2882<p>A hash function processes every byte in a file and returns a fixed-length string, often shown as hexadecimal characters. SHA-256 is a sensible current choice for ordinary file identification. A one-byte change normally produces a completely different SHA-256 value. The hash does not reveal the original file or its source code. It is a fingerprint, not a decompiler, password, or security scan.</p>
2883
2884<table>
2885<thead><tr><th>Observation</th><th>What it reasonably supports</th><th>What it does not establish</th></tr></thead>
2886<tbody>
2887<tr><td>Same SHA-256 value</td><td>The files are byte-for-byte identical for practical integrity checking.</td><td>That the file is safe, licensed, profitable, or from the claimed author.</td></tr>
2888<tr><td>Different SHA-256 value</td><td>At least one byte differs. Treat the files as separate versions until explained.</td><td>That either file is malicious or defective.</td></tr>
2889<tr><td>Same file name</td><td>Only that the displayed names match.</td><td>Identical content, origin, or installation state.</td></tr>
2890<tr><td>Same file size</td><td>A useful clue worth checking further.</td><td>Identical bytes. Different content can have the same size.</td></tr>
2891<tr><td>Published vendor hash</td><td>A comparison point, if obtained from a trusted vendor channel.</td><td>Permission to redistribute or modify the file.</td></tr>
2892</tbody>
2893</table>
2894
2895<p>MD5 and SHA-1 still appear in older documentation and utilities. They can detect accidental copying errors in some routine settings, but they have known cryptographic weaknesses and are not a preferred choice where a modern alternative is available. Use SHA-256 consistently for a new record. Consistency matters more than collecting several algorithms without a plan. If a supplier publishes a checksum in another format, record both the supplier's stated value and the locally calculated SHA-256, clearly labeling the algorithms.</p>
2896
2897<p>A hash is also sensitive by design. Opening a file, copying it, and renaming it should not change its hash. Any actual alteration to its bytes will. That includes a genuine new compile, a modified wrapper, file corruption, or an intentional replacement. A mismatch does not identify the cause. The surrounding record, source, date, and controlled copies provide that c
2897ontext.</p>
2898
2899<h2 id="baseline">Build a Baseline Before Moving Anything</h2>
2900
2901<p>The strongest time to create a fingerprint is when an EX4 first arrives from a known source. If that moment has passed, create one now and be honest in the notes: the baseline was calculated on the date of collection from a stated location. Do not describe a later calculation as proof of what was received months earlier.</p>
2902
2903<ol>
2904<li><strong>Locate the candidate original.</strong> Identify the download, archive, email attachment, or terminal folder that appears closest to the received file. Do not overwrite it while investigating.</li>
2905<li><strong>Freeze a preservation copy.</strong> Copy it into a folder with a plain, dated name such as EX4-archive/2026-09-07-received. Do not run it from this location.</li>
2906<li><strong>Record basic context.</strong> Note product name, displayed filename, source channel, date obtained, file size, and the exact source path. Save relevant licence or purchase information separately.</li>
2907<li><strong>Calculate SHA-256.</strong> Store the whole value, not merely the first few characters. Note the tool and date used.</li>
2908<li><strong>Make a verification copy.</strong> Copy the preserved binary into a controlled test folder and calculate the hash again. The two values should match.</li>
2909</ol>
2910
2911<p>The baseline log can be a small text file or spreadsheet. It does not need special software. What matters is that a person other than the original recorder can understand it. Avoid calling a folder “final” or “latest.” Those names lose meaning immediately after another delivery. Prefer labels that state purpose and date, such as “test-copy-2026-09-07” or “vendor-update-2026-09-15.”</p>
2912
2913<h3>A minimal record layout</h3>
2914
2915<table>
2916<thead><tr><th>Field</th><th>Example of a useful entry</th></tr></thead>
2917<tbody>
2918<tr><td>Record ID</td><td>EA-2026-09-07-01</td></tr>
2919<tr><td>Displayed file name</td><td>ExampleEA.ex4</td></tr>
2920<tr><td>Purpose</td><td>Preserved received binary, not for live use</td></tr>
2921<tr><td>Origin</td><td>Vendor portal download, order reference retained privately</td></tr>
2922<tr><td>SHA-256</td><td>Full locally calculated hash value</td></tr>
2923<tr><td>Location</td><td>Offline archive folder or approved storage location</td></tr>
2924<tr><td>Custodian and date</td><td>Person recording it and date of calculation</td></tr>
2925</tbody>
2926</table>
2927
2928<p>Do not put account credentials, licence keys, personal addresses, or confidential commercial terms in a shared hash log. A hash record should identify the binary and its handling, not create a new privacy problem.</p>
2929
2930<h2 id="controlled-copies">Create Controlled Copies Without Confusion</h2>
2931
2932<p>The original should be preserved, while actual work happens on copies. This is the central discipline of controlled copying. A user can duplicate an EX4 many times safely if every copy has a stated role and is verified against the expected hash before use. The mistake is not duplication itself. The mistake is unmanaged duplication.</p>
2933
2934<p>A practical folder arrangement has three zones. The archive zone holds untouched received binaries and should be write-restricted where possible. The test zone holds copies for a demo account, isolated terminal, or permitted analysis. The deployment zone holds only the file approved for a specific installed terminal. Each zone should have an integrity record. A copy moving from one zone to another is a handoff, not just a drag-and-drop action.</p>
2935
2936<p>For example, an operator receives ExampleEA.ex4 and records hash A in the archive. They copy it to a test terminal and calculate hash A again. After a vendor supplies an update, the new download calculates as hash B. That does not mean hash B is wrong. It means the update is a distinct binary. The operator records it as a new version, tests it independently, and never silently replaces the archive entry for hash A. If the result is later questioned, both versions remain identifiable.</p>
2937
2938<p>A controlled copy also guards against accidental live duplication. Installing the same EA in two active terminals that point at one trading account can create operational conflicts depending on its order-management design. The integrity process will not stop duplicate orders by itself, but an explicit deployment record makes it easier to see where a binary is active. For movement between a local computer and hosted terminal, the related <a href="/blog/expert-advisor-vps-transfer-audit-mt4">MT4 VPS transfer audit guide</a> adds environment and configuration checks that sit alongside file identification.</p>
2939
2940<h2 id="commands">Calculate and Compare Hashes</h2>
2941
2942<p>Use a built-in operating system utility where possible and calculate from the exact file path. Close applications that might be installing or replacing the target file, then copy the result into the record without retyping it. The commands below are examples of local file identification, not instructions to alter a binary.</p>
2943
2944<h3>Windows PowerShell</h3>
2945<pre><code>
2945Get-FileHash -Algorithm SHA256 "C:MT4TestMQL4ExpertsExampleEA.ex4"</code></pre>
2946
2947<p>The output includes the algorithm, hash, and path. Run the same command against the archive copy and compare the complete SHA-256 strings. PowerShell is generally case-insensitive for this comparison because hexadecimal case does not change the value, but keeping the copied output unchanged makes records easier to review.</p>
2948
2949<h3>Windows Command Prompt</h3>
2950<pre><code>certutil -hashfile "C:MT4TestMQL4ExpertsExampleEA.ex4" SHA256</code></pre>
2951
2952<h3>macOS or Linux terminal</h3>
2953<pre><code>shasum -a 256 "/path/to/ExampleEA.ex4"</code></pre>
2954
2955<p>On systems that provide it, the equivalent command may be <code>sha256sum "/path/to/ExampleEA.ex4"</code>. The important point is not the brand of utility. It is using the same algorithm and checking the full output against the full expected value. A partial comparison is useful only as a quick visual cue, never as the formal record.</p>
2956
2957<p>For recurring work, a simple manifest file can list a filename and SHA-256 value for each approved binary. Keep the manifest in the archive with its creation date and use a separate change note when it is updated. Do not edit an old manifest to make a mismatch disappear. Preserve the earlier version and explain why a new file was approved.</p>
2958
2959<h2 id="interpret-results">Interpret Matches and Mismatches</h2>
2960
2961<p>A match supports a narrow conclusion: the comparison copy is the same sequence of bytes as the baseline. It is then reasonable to say that the transfer preserved the file content. It is not reasonable to infer that MT4 will load it, that dependencies are present, or that its inputs are identical. An EA's behavior also depends on terminal build, broker symbols, chart settings, permissions, data, and attached files.</p>
2962
2963<p>A mismatch needs a calm workflow. Do not overwrite either candidate. First confirm that the same algorithm was used and that the command pointed to the intended file. Check whether a vendor announced an update or whether Windows created a renamed duplicate such as ExampleEA (1).ex4. Compare the recorded size and source path. If the discrepancy remains unexplained, classify the file as unverified and use neither one as a replacement for the other until the provenance is clarified.</p>
2964
2965<ol>
2966<li>Preserve both files in separate, read-only archive folders if feasible.</li>
2967<li>Calculate SHA-256 again from each preserved copy to rule out a path mistake.</li>
2968<li>Check the delivery message, vendor portal history, or internal handoff note for a stated version change.</li>
2969<li>Record the mismatch with date, locations, and the two full hashes.</li>
2970<li>Obtain clarification from the authorized source if the file is meant to be the same release.</li>
2971<li>Test a confirmed new version separately, rather than replacing the old one in a live folder.</li>
2972</ol>
2973
2974<p>Never treat a mismatch as proof of malicious activity without supporting evidence. Corruption, a legitimate compile, an installer change, or a simple copy of a different release are all possible. Conversely, do not dismiss a mismatch because the filename looks right. The purpose of the integrity shield is to let the evidence guide the next step.</p>
2975
2976<h2 id="duplicate-investigation">Investigate Duplicate EX4 Files</h2>
2977
2978<p>Duplicate file cleanup should begin with inventory, not deletion. Search the relevant archive, downloads, terminal data folders, and VPS transfer folders for the EX4 name. For each hit, record its full path, size, modified time, and SHA-256. Then group the files by hash. Files with the same hash are content duplicates even if their names differ. Files with different hashes are separate binaries even if their names match.</p>
2979
2980<table>
2981<thead><tr><th>Finding</th><th>Recommended next decision</th></tr></thead>
2982<tbody>
2983<tr><td>Several files share hash A</td><td>Retain one preserved archive copy and label other locations by role. Remove only redundant working copies after confirming they are not active.</td></tr>
2984<tr><td>Same name, hashes A and B</td><td>Keep both. Determine source and intended version before using either as a substitute.</td></tr>
2985<tr><td>Different names, same hash A</td><td>Document aliases. Check that the names do not cause confusion in templates or deployment notes.</td></tr>
2986<tr><td>Unknown file in an active Experts folder</td><td>Do not assume it is the approved build. Compare its hash to the deployment record before activation.</td></tr>
2987</tbody>
2988</table>
2989
2990<p>Before deleting anything, verify that an MT4 terminal is not using the file and that no preserved evidence needs to be retained. A cleanup log can say “working duplicate removed after hash match with archive record EA-2026-09-07-01.” That is much more useful later than a missing file and an uncertain memory. This modest discipline becomes especially important when an owner needs to document a legitimate maintenance project or pass materials to a new developer.</p>
2991
2992<h2 id="handoffs">Use an Integrity Shield During Handoffs</h2>
2993
2994<p>A file handoff is a point where identity can be lost. Whether the recipient is an employee, contractor, authorized reviewer, or recovery provider, the sender should retain the hash of what was sent and the recipient should calculate the hash of what arrived. Both parties can then confirm the transfer without circulating the file again merely to settle doubt.</p>
2995
2996<p>A concise handoff note should identify the record ID, displayed filename, SHA-256, date, purpose, and approved recipient. It should say whether the file is an original preservation copy, a test c
2996opy, or a new vendor release. It should not make broad technical or legal claims. If the recipient returns an output or a revised binary, record that returned item separately. It is not a replacement for the original just because the names appear similar.</p>
2997
2998<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
2999  <h3 style="margin-top:0;">Need an Authorized EX4 Recovery Review?</h3>
3000  <p>ForexMQ5 is reviewed as a professional option for owners who can document a legitimate recovery or maintenance purpose. Keep the original hash and scope record before any authorized handoff.</p>
3001  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
3002</div>
3003
3004<p>This review site does not provide the service. The professional option should not be used to bypass licences, remove account restrictions, or duplicate a third party's strategy. The requester remains responsible for confirming their authority and for describing the narrow purpose accurately. A hash record helps document the exact input file; it does not grant rights over that file.</p>
3005
3006<h2 id="recovery-context">Hashing a File for Recovery or Review</h2>
3007
3008<p>When an EX4 is sent for authorized source recovery, code review, or troubleshooting, hashing protects the technical chain of work. The original binary should be fingerprinted before it leaves the owner's controlled storage. The owner can later distinguish it from a similarly named update, a copy made for testing, or any output delivered after analysis. That separation is useful because recovered MQ4 is not a byte-identical form of an EX4. It is a different file type and should be recorded as a separate deliverable with its own hash.</p>
3009
3010<p>Keep the input EX4, recovered output, compiler messages, test notes, and any handover documentation in a structured project folder. The site's <a href="/blog/mql4-recovery-handover-documentation-plan">MQL4 recovery handover documentation plan</a> explains how to organize those materials so a later maintainer can understand what was received and what changed. The aim is traceability, not a claim that recovered output exactly recreates every historical source-level choice.</p>
3011
3012<p>Hashing is also useful before controlled testing after recovery. It confirms that the candidate EX4 under observation is the same build that was approved for the test. It does not validate the strategy or remove the need for isolated testing. A careful user should keep live deployment out of the integrity process until the separate technical, rights, and risk questions have been considered.</p>
3013
3014<h2 id="checklist">Practical Integrity Checklist</h2>
3015
3016<p>Use this checklist when receiving, moving, or reviewing an EX4:</p>
3017
3018<ul>
3019<li>Confirm the user has a legitimate right to possess and share the file for the stated purpose.</li>
3020<li>Preserve the candidate original before opening installers or replacing terminal copies.</li>
3021<li>Record filename, source, collection date, size, path, and full SHA-256 hash.</li>
3022<li>Store the archive copy away from test and deployment folders.</li>
3023<li>Calculate the same SHA-256 hash after each important copy or handoff.</li>
3024<li>Label copies by role and date, not vague words such as final or newest.</li>
3025<li>Group discovered duplicates by hash before deleting or replacing anything.</li>
3026<li>Treat every hash mismatch as a distinct version until a credible explanation is recorded.</li>
3027<li>Record returned outputs separately from the EX4 input.</li>
3028<li>Keep configuration, environment, and testing notes alongside, but separate from, the binary fingerprint.</li>
3029</ul>
3030
3031<p>Readers comparing technical routes may also use the site's <a href="/">decompile ex4</a> overview to understand the difference between file identification, source recovery, and code validation. These are related steps, but none replaces the others. A perfectly recorded hash cannot repair an EA, and a recovered source file does not erase the need for a clean integrity record.</p>
3032
3033<h2 id="conclusion">Conclusion</h2>
3034
3035<p>An EX4 integrity shield is deliberately simple: preserve the original, calculate SHA-256, make controlled copies, and write down each meaningful handoff or version change. Its value comes from reducing ambiguity. Instead of trusting a familiar filename, an MT4 user can identify the binary that was received, tested, transferred, or reviewed.</p>
3036
3037<p>Use the result with appropriate limits. A matching hash proves f
3037ile identity for practical purposes, not safety, ownership, strategy quality, or trading suitability. A mismatch calls for investigation, not accusation. Combined with clear authorization, isolated testing, and careful records, hashes give owners and maintainers a dependable way to handle legitimate EX4 files without losing track of the original binary.</p>
3038`},{slug:"mt4-ea-malware-security-review",title:"MT4 EA Malware Review: Security Warning Signs in Trading Robot Files",metaTitle:"MT4 EA Malware Review: Security Warning Signs | 2026",metaDescription:"Learn how to assess suspicious MT4 Expert Advisor files, network indicators, permissions, and safe testing steps before a trading robot reaches a live terminal.",keywords:"MT4 EA malware review, trading robot security, suspicious EX4 file, Expert Advisor network indicators, MT4 EA security audit, forex robot warning signs",excerpt:"A trading robot can be poorly engineered, aggressively licensed, or genuinely unsafe. This independent review guide separates those possibilities and gives MT4 users a practical process for examining suspicious file and network warning signs.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:Eu,imageAlt:"MT4 trading robot file scanned by a cybersecurity shield with suspicious network warning light",tableOfContents:[{id:"scope",title:"What This Review Can and Cannot Establish"},{id:"first-response",title:"The First Response to a Suspicious EA"},{id:"warning-model",title:"A Practical Warning Sign Model"},{id:"file-provenance",title:"File Provenance and Package Inspection"},{id:"terminal-permissions",title:"Terminal Permissions and Configuration Risks"},{id:"network-indicators",title:"Suspicious Network Indicators"},{id:"controlled-testing",title:"Controlled Testing Without a Live Account"},{id:"code-review",title:"What a Code Review Can Reveal"},{id:"decision-path",title:"Decision Steps After the Review"},{id:"service-perspective",title:"Where a Professional Review Fits"},{id:"conclusion",title:"Conclusion: Treat Uncertainty as a Signal"}],content:`
3039<p>An MT4 Expert Advisor can arrive as a promising shortcut: a seller describes automated entries, a community member shares a file, or a former developer sends a replacement build. The same file can also create a security question. A robot that is merely unprofitable is not malware. A robot that requires a licence check is not automatically malicious either. Yet an unknown executable, unexpected network contact, unusual permissions request, or unexplained change in terminal behavior deserves a measured investigation before it reaches a funded trading environment.</p>
3040
3041<p>This independent review guide is written for traders and managers assessing an EX4 or related trading robot package. It does not diagnose a specific file, promise that a clean scan proves safety, or replace an incident response professional where accounts or devices may be compromised. Its purpose is to make the next step more disciplined. The goal is to distinguish evidence from suspicion, contain avoidable risk, and document what was observed.</p>
3042
3043<img src="${Eu}" alt="MT4 Expert Advisor file inspected by a cybersecurity shield beside a suspicious network warning light" style="width:100%;border-radius:8px;margin:24px 0;" />
3044
3045<p>A useful starting principle is simple: the decision to run a robot is also a decision to trust its author, delivery path, configuration, and behavior. MT4 automation can place orders and read market information within the terminal. Depending on settings and companion components, a package may also request web access, write local files, call DLL functions, or rely on a separate updater. Each capability has legitimate uses. Each also expands the set of questions a reviewer should ask.</p>
3046
3047<p>Readers who are still learning the relationship between compiled robots and their source can begin with this explanation of <a href="/blog/ex4-files-explained-for-mt4-users">what an EX4 file is in MT4</a>. The practical security issue begins after that definition: not every compiled file can be meaningfully understood by looking at its name or a marketplace screenshot.</p>
3048
3049<h2 id="scope">What This Review Can and Cannot Establish</h2>
3050
3051<p>Security language is often used too loosely in trading communities. A missing source file, a protected EX4, a disappointing backtest, and a malware alert are different problems. Treating them as the same problem produces bad decisions. An evidence based review separates at least four possibilities.</p>
3052
3053<table>
3054  <thead><tr><th>
3054Finding</th><th>What it may mean</th><th>Reasonable next action</th></tr></thead>
3055  <tbody>
3056    <tr><td>Robot loses money or trades unexpectedly</td><td>Strategy, settings, symbol mapping, or execution issue</td><td>Stop live use and inspect configuration and trade logs</td></tr>
3057    <tr><td>EX4 is protected or difficult to read</td><td>Normal vendor protection, obfuscation, or a modern compiler format</td><td>Check provenance and request documentation, not accusations</td></tr>
3058    <tr><td>Security software alerts on a file</td><td>Potential threat, heuristic match, or false positive</td><td>Preserve the file, capture the alert details, and obtain a second assessment</td></tr>
3059    <tr><td>Unexpected network or DLL activity appears</td><td>Licence check, telemetry, update mechanism, or unwanted behavior</td><td>Contain it in an isolated environment and investigate the destination and purpose</td></tr>
3060  </tbody>
3061</table>
3062
3063<p>None of these observations alone proves intent. A file can be suspicious without being malicious, and a file can avoid detection without being safe. That uncertainty is why a review should not end with one antivirus result or a vendor assurance. The stronger approach combines provenance, configuration, behavior, and technical evidence.</p>
3064
3065<p>It is also important to keep trading risk separate from device risk. An EA may have no hostile code but still expose an account through excessive lot sizing, repeated order placement, or a hidden recovery grid. Conversely, a technically suspicious component can pose a workstation risk even before a single trade is made. A good review records both categories, because the controls are different.</p>
3066
3067<h2 id="first-response">The First Response to a Suspicious EA</h2>
3068
3069<p>The first minutes after noticing a warning matter. Avoid clicking through prompts, reinstalling the package over the existing copy, or sending the original to several unvetted people. Those actions can erase useful evidence and extend exposure. If the robot is already running on a live terminal, the sensible immediate action is to disable automated trading for that terminal and prevent new orders while the situation is assessed. Account decisions should follow the organization’s own broker, risk, and security procedures.</p>
3070
3071<h3>Contain, preserve, record</h3>
3072
3073<ol>
3074  <li><strong>Disconnect the questionable environment if needed.</strong> If there is a credible sign of compromise, remove the machine or virtual environment from normal network access according to local security practice. Do not assume that simply closing MT4 ends every related process.</li>
3075  <li><strong>Preserve the original package.</strong> Copy the delivered archive and files to a protected location. Record the file names, sizes, delivery date, sender, download URL if applicable, and a cryptographic hash when a qualified person can create one.</li>
3076  <li><strong>Capture the visible evidence.</strong> Save screenshots of antivirus notices, MT4 Journal and Experts entries, permission prompts, terminal settings, and any unexplained files. Include timestamps.</li>
3077  <li><strong>Stop credential reuse.</strong> If the EA arrived with an installer or a suspicious companion application, do not enter broker, email, remote desktop, or payment credentials into that environment.</li>
3078  <li><strong>Tell the right people.</strong> In a managed account, firm, or shared VPS setting, notify the person responsible for security and trading operations. A quiet individual fix can leave others exposed.</li>
3079</ol>
3080
3081<p>Containment is not a declaration that the vendor acted badly. It is an ordinary precaution while facts are incomplete. The reviewer should phrase records carefully: “terminal attempted a connection to this host at this time” is an observation; “the vendor stole credentials” is a conclusion that requires much stronger evidence.</p>
3082
3083<h2 id="warning-model">A Practical Warning Sign Model</h2>
3084
3085<p>Rather than scoring a file with a single red or green label, group findings by severity and context. A single low concern indicator may be routine. Several unrelated indicators, especially a mismatch between what the vendor promised and what the package does, justify escalation.</p>
3086
3087<h3>Low concern indicators that still need explanation</h3>
3088
3089<ul>
3090  <li>The robot checks a known vendor domain to validate a subscription.</li>
3091  <li>The package includes a signed or clearly documented DLL with a stated function.</li>
3092  <li>The EA writes a local log or settings file in an expected MT4 folder.</li>
3093  <li>A vendor update changes the file version and is accompanied by release notes.</li>
3094  <li>The seller explains required WebRequest domains before installation.</li>
3095</ul>
3096
3097<p>These facts are not automatic approval. They become reassuring only when the domain, publisher, documentation, and observed behavior agree. For example, a licence server described 
3097in a contract but hosted on an unrelated, newly presented address still warrants a question.</p>
3098
3099<h3>Elevated concern indicators</h3>
3100
3101<ul>
3102  <li>The download arrives through an expiring file share, private message, or renamed archive rather than the documented vendor channel.</li>
3103  <li>The file name copies a popular EA, broker, or Windows component but the sender cannot explain its origin.</li>
3104  <li>The instructions insist on disabling endpoint protection without a specific, verifiable reason.</li>
3105  <li>The package contains an unexpected installer, script, executable, or DLL alongside the EX4.</li>
3106  <li>WebRequest, DLL imports, or network access are required but omitted from the sales material and setup guide.</li>
3107  <li>Observed destinations differ from the stated licensing or update infrastructure.</li>
3108</ul>
3109
3110<h3>High concern indicators</h3>
3111
3112<ul>
3113  <li>A file tries to collect credentials, browser data, private keys, remote access details, or unrelated documents.</li>
3114  <li>The package persists outside expected MT4 locations, alters security settings, or starts unexplained processes.</li>
3115  <li>It contacts unfamiliar destinations with no credible business function while idle or after removal.</li>
3116  <li>A seller pressures the user to install immediately, bypass warnings, or conceal activity from an administrator.</li>
3117  <li>Multiple independent security tools identify the same threat family or behavior, with evidence that matches the actual file hash.</li>
3118</ul>
3119
3120<p>High concern findings call for trained security support, especially on a computer used for brokerage, banking, or client work. The right response is containment and evidence preservation, not experimentation with a potentially unsafe sample.</p>
3121
3122<h2 id="file-provenance">File Provenance and Package Inspection</h2>
3123
3124<p>File provenance is the story of where a robot came from and how it changed before installation. It is often more useful than a bold marketing claim. A trustworthy chain does not need to be perfect, but it should be coherent. The seller, transaction, download, documentation, version, and support contact should line up.</p>
3125
3126<h3>Questions to ask before opening anything</h3>
3127
3128<table>
3129  <thead><tr><th>Question</th><th>Why it matters</th><th>Evidence to keep</th></tr></thead>
3130  <tbody>
3131    <tr><td>Who supplied the file?</td><td>Identifies the party who can explain behavior and licence terms</td><td>Order receipt, email address, marketplace profile, support ticket</td></tr>
3132    <tr><td>What exact version was promised?</td><td>Helps detect substituted or altered uploads</td><td>Release notes, version screen, original download name</td></tr>
3133    <tr><td>Was a hash published or supplied?</td><td>Can help confirm that a copy matches a known delivery</td><td>Hash value, date, and method used to obtain it</td></tr>
3134    <tr><td>What files should the package contain?</td><td>Unexpected components become easier to identify</td><td>Installation guide and directory listing</td></tr>
3135    <tr><td>What support channel verifies the file?</td><td>Reduces reliance on an impersonator or reseller</td><td>Vendor website and written confirmation</td></tr>
3136  </tbody>
3137</table>
3138
3139<p>A review should compare archive contents with installation instructions before moving files into MT4. An EX4 alone is not unusual. A package that adds a password protected archive, a batch script, a browser extension, or a generic remote support utility deserves a clear explanation. Password protection can be used for ordinary distribution, but it also prevents some scanners from inspecting content. That is a reason to pause, not a basis to accuse.</p>
3140
3141<p>Record file hashes when possible and compare only against a value obtained from a trustworthy vendor source, not from the same unverified chat message that carried the file. A matching hash tells the reviewer two copies are identical. It does not establish that the original publisher or the code is safe. This distinction prevents a common mistake in which an accurate technical check is given more meaning than it has.</p>
3142
3143<p>Vendor transparency matters here. The separate checklist on <a href="/blog/forex-ea-vendor-transparency-checklist">warning signs in Forex EA vendor disclosure</a> is useful for evaluating claims, update policies, support identity, and testing evidence. A vague seller does not prove a malicious robot, but vague accountability makes unusual technical behavior harder to resolve.</p>
3144
3145<h2 id="terminal-permissions">Terminal Permissions and Configuration Risks</h2>
3146
3147<p>MT4 security is partly about the file and partly about the privileges granted to it. Before attaching any EA, inspect the terminal settings and the robot’s Inputs and Common tabs. A least privilege approach means enabling only the capability that is necessary for the stated function, then reassessing when the function changes.</p>
3148
3149<h3>Permission review checklist</h3>
3150
3151<ul>
3152  <li><strong>Live trading:</strong> Is the robot being evaluated, or does it actually need authority to place orders? Do not grant this during a behavior review.</li>
3153  <li><strong>DLL imports:</strong> What library is being called, who published it, and what task cannot be performed within MQL4? A blanket instruction to enable DLLs is insufficient.</li>
3154  <li><strong>WebRequest:</strong> Which exact domains are allowed, what data is sent, how often, and is the destination included in documentation?</li>
3155  <li><strong>File access:</strong> Which folders are used and what files are created? Expected logs and settings differ from broad unrelated collection.</li>
3156  <li><strong>External dependencies:</strong>
3156 Are helper programs, licences, indicators, or installers required? Obtain names, versions, and provenance for each one.</li>
3157  <li><strong>Account scope:</strong> Is the test terminal connected to a dedicated demo account rather than a live account with meaningful funds?</li>
3158</ul>
3159
3160<p>Do not confuse a legitimate function with unlimited permission. A news filter may need access to a defined calendar endpoint. A licence system may need a vendor endpoint. Neither fact explains access to arbitrary domains or an opaque executable helper. A transparent vendor can state the reason, endpoint, and fallback behavior when access is denied.</p>
3161
3162<p>Disable automatic assumptions. An EA that fails safely when a permission is withheld is easier to evaluate than one that prompts the user to lower several safeguards at once. If disabling an unnecessary permission breaks a claimed core function, ask for a technical explanation in writing.</p>
3163
3164<h2 id="network-indicators">Suspicious Network Indicators</h2>
3165
3166<p>A network indicator is a clue about a connection, not a verdict. It can include a domain, IP address, URL path, port, connection timing, data size, or process responsible for traffic. The strongest concern appears when several clues disagree with the declared purpose of the robot.</p>
3167
3168<h3>What to observe in a controlled environment</h3>
3169
3170<ol>
3171  <li>Start with a clean, isolated test environment and a demo terminal that contains no sensitive documents or saved credentials beyond what is essential.</li>
3172  <li>Run the terminal without attaching the EA, then note ordinary MT4 and broker related traffic. This baseline avoids blaming the EA for normal platform activity.</li>
3173  <li>Attach the EA with live trading disabled and observe whether new connections occur. Repeat after changing one setting at a time.</li>
3174  <li>Compare destinations with the vendor’s published licence, update, signal, or news endpoints. Capture the full hostname and timestamp rather than relying on a partial screenshot.</li>
3175  <li>Remove the EA and restart the terminal. Continued unusual traffic may point to another component, but it still requires investigation.</li>
3176</ol>
3177
3178<p>Timing provides context. A single request at startup can be a licence check. Regular traffic during a declared signal copying feature may be expected. Repeated connections while the terminal is idle, contact with unrelated domains, or traffic initiated by a bundled executable are harder to reconcile with a simple trading strategy. Reviewers should ask what information leaves the terminal, whether it is encrypted, and whether the vendor can identify the endpoint. Encryption is generally normal and desirable, so the question is destination and purpose, not encryption alone.</p>
3179
3180<h3>Examples that require different responses</h3>
3181
3182<p><strong>Example one: disclosed licence check.</strong> The vendor guide lists a licensing domain and explains that the EA validates once at startup. In a demo test, the terminal contacts that exact domain after attachment and stops when the EA is removed. This is consistent with the disclosure, though the reviewer may still decide whether the licence terms are acceptable.</p>
3183
3184<p><strong>Example two: unexplained updater.</strong> A robot marketed as an offline trend EA triggers a separate executable that connects to several unrelated hosts. The vendor guide mentions no helper program or updates. The right response is to stop testing, preserve the package and observations, and seek a credible explanation or specialist analysis. It would be premature to label the file malware from this fact alone, but the mismatch is material.</p>
3185
3186<p><strong>Example three: suspicious alert with no observed traffic.</strong> A scanner flags a packed EX4, but the vendor provides a consistent delivery path, the file matches a documented hash, and isolated observation shows no unexpected behavior. This may be a false positive or a detection that needs further review. The reviewer should obtain the detection name, engine, and file hash, then avoid both panic and dismissal.</p>
3187
3188<h2 id="controlled-testing">Controlled Testing Without a Live Account</h2>
3189
3190<p>Testing an unfamiliar robot directly on a personal workstation and funded account combines too many risks. A controlled environment reduces potential harm and makes observations clearer. It is not a guarantee of safety. Sophisticated unwanted behavior can be delayed, conditional, or activated only in particular conditions. Still, basic 
3190isolation is substantially better than blind installation.</p>
3191
3192<h3>Minimum test environment</h3>
3193
3194<ul>
3195  <li>Use a separate virtual machine or dedicated device where permitted by the organization’s policies.</li>
3196  <li>Create a fresh MT4 installation and a dedicated demo account with no relationship to production access.</li>
3197  <li>Do not store personal files, password manager data, browser sessions, API keys, or broker credentials unrelated to the test.</li>
3198  <li>Snapshot or back up the clean environment before installation so differences can be reviewed later.</li>
3199  <li>Limit network access to what is essential and log the allowed destinations.</li>
3200  <li>Keep a simple test journal listing each action, time, setting, observed connection, created file, and trade attempt.</li>
3201</ul>
3202
3203<p>Use staged tests. First inspect the archive without execution. Next open MT4 without the robot to establish a baseline. Then place the EX4 in the appropriate directory without attaching it. After that, attach it with live trading and unnecessary permissions disabled. Only enable a single documented permission when it is required to answer a precise question. This sequence helps assign cause. Changing five settings and adding several indicators at once makes later evidence much less useful.</p>
3204
3205<p>Behavioral review should include trade behavior as well as device behavior. Does the EA attempt orders when live trading is disabled? Does it change chart objects, templates, files, or global variables? Does it produce intelligible Journal entries? Does its stated symbol and timeframe behavior match the documentation? These questions do not establish malware, but undocumented actions diminish trust and can reveal a configuration hazard.</p>
3206
3207<h2 id="code-review">What a Code Review Can Reveal</h2>
3208
3209<p>When the requester has the rights to inspect a robot, source review can clarify what a compiled package is designed to do. It is not a shortcut around intellectual property or licence restrictions. Rights and purpose should be settled first. In appropriate cases, readable code or an authorised technical audit can identify WebRequest calls, DLL imports, file operations, hard coded endpoints, licensing logic, and order management behavior.</p>
3210
3211<p>Even then, code review has limits. Decompiled output may be incomplete, poorly named, or altered by compiler and protection techniques. A reviewer should not claim that a reconstructed source is a perfect representation of every original design decision. Runtime behavior, file provenance, and configuration evidence remain important. For a reader considering the technical side, the site’s overview of <a href="/">MT4 EA decompiler</a> options explains why recovery quality and modern file formats affect what can be inspected.</p>
3212
3213<h3>Review questions for authorised source access</h3>
3214
3215<table>
3216  <thead><tr><th>Area</th><th>Questions to ask</th></tr></thead>
3217  <tbody>
3218    <tr><td>Network</td><td>Which endpoints are called? What data is requested or sent? Is the behavior optional and documented?</td></tr>
3219    <tr><td>Libraries</td><td>Are DLL imports necessary? Are library names, publishers, and functions explained?</td></tr>
3220    <tr><td>Files</td><td>Does the EA read and write only expected terminal locations? Does it create or execute other content?</td></tr>
3221    <tr><td>Trading</td><td>What order types, volume rules, symbols, magic numbers, and emergency limits exist?</td></tr>
3222    <tr><td>Licensing</td><td>Does licence enforcement match the written agreement, or does it impose unexpected restrictions?</td></tr>
3223    <tr><td>Updates</td><td>Can the software change itself or retrieve components, and is that mechanism transparent?</td></tr>
3224  </tbody>
3225</table>
3226
3227<p>Comments, variable names, and a vendor’s explanation can be helpful, but behavior matters more than labels. A function called LicenseCheck could perform more than a licence check. Conversely, an unfamiliar function name may be harmless. The review should trace what occurs, document the evidence, and avoid overclaiming from names alone.</p>
3228
3229<h2 id="decision-path">Decision Steps After the Review</h2>
3230
3231<p>At the end of a review, the question is not always “safe or unsafe.” Often it is “is there enough evidence to allow the next limited step?” The following decision path keeps that judgment proportional.</p>
3232
3233<ol>
3234  <li><strong>Clear and documented:</strong> If provenance is consistent, permissions are narrow, observed behavior matches documentation, and no material alerts remain unresolved, a user may proceed only through their own demo, risk, and deployment c
3234ontrols. Security review does not validate trading performance.</li>
3235  <li><strong>Unclear but not alarming:</strong> If a licence endpoint or component cannot be verified, ask the vendor specific questions. Keep the EA out of live use until responses and testing resolve the gap.</li>
3236  <li><strong>Material mismatch:</strong> If unexplained binaries, destinations, permissions, or persistence appear, discontinue testing and preserve evidence. Do not try to “clean” the file and then deploy it.</li>
3237  <li><strong>Credible compromise concern:</strong> If there are signs of credential access, data collection, security control changes, or confirmed threat detections, seek qualified incident response help and follow relevant broker and organizational procedures.</li>
3238</ol>
3239
3240<p>Documentation turns a difficult judgment into an auditable one. A compact review record should include the file hash, source, test date, terminal build, permissions enabled, network observations, alerts, vendor responses, and final decision. This protects the reviewer from relying on memory and makes a later handover more useful.</p>
3241
3242<h2 id="service-perspective">Where a Professional Review Fits</h2>
3243
3244<p>Some questions are beyond a trader’s practical scope. A business that owns a custom robot but lost its source may need an authorised recovery to examine dependencies. A purchaser may need an independent technical explanation of a file before accepting delivery. A suspicious package may require a qualified cybersecurity professional rather than a trading software specialist. The right provider depends on the question.</p>
3245
3246<p>forexdec reviews the professional recovery option at ForexMQ5 from the perspective of users with a legitimate, documented reason to inspect or maintain their own files. That type of review is not malware removal, incident response, legal advice, or a guarantee that recovered output is safe to run. A responsible requester should be prepared to explain ownership or permission, define the narrow purpose, and keep recovered material confidential where rights require it.</p>
3247
3248<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
3249  <h3 style="margin-top:0;">Need an Authorised File Recovery Review?</h3>
3250  <p>For a documented recovery or maintenance need, readers can assess the professional option described in this review and confirm that their intended use is authorised before requesting any work.</p>
3251  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
3252</div>
3253
3254<h2 id="conclusion">Conclusion: Treat Uncertainty as a Signal</h2>
3255
3256<p>A trading robot should earn access to a terminal rather than receive it by default. A scan result, a protected EX4, or a network connection is only one piece of the picture. The more reliable assessment looks at delivery provenance, disclosed capabilities, terminal permissions, isolated behavior, and the vendor’s willingness to explain discrepancies. This approach catches ordinary setup problems as well as meaningful warning signs.</p>
3257
3258<p>When facts are incomplete, caution is a practical decision rather than an accusation. Keep the file away from live accounts, preserve evidence, and seek specialist help when indicators point beyond normal EA behavior. A carefully documented review cannot eliminate every risk, but it gives traders a defensible basis for deciding whether a robot deserves further testing, a vendor explanation, or complete rejection. Readers assessing an authorised recovery path can also compare the broader <a href="/">ex4 to mq4 decompiler</a> review information before deciding what level of technical help is appropriate.</p>
3259`},{slug:"mt4-vps-logs-ea-diagnostics",title:"Use MT4 VPS Logs to Diagnose Expert Advisor Failures",metaTitle:"Use MT4 VPS Logs to Diagnose Expert Advisor Failures",metaDescription:"Learn a practical MT4 VPS journal log workflow for finding Expert Advisor startup, trading, connection, and timing failures before changing code.",keywords:"MT4 VPS logs, MetaTrader journal logs, Expert Advisor diagnostics, MT4 EA troubleshooting, VPS EA failure",excerpt:"A MetaTrader VPS can hide the moment an Expert Advisor stopped working. This practical diagnostic guide shows how to build a timeline from terminal and EA logs, isolate likely causes, and document the next safe test.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:Mu,imageAlt:"Server rack beside MetaTrader journal logs and a diagnostic magnifying glass",tableOfContents:[{id:"why-logs-matter",title:"Why VPS Logs Are the Best Starting Point"},{id:"preserve-evidence",title:"Preserve Evidence Before Restarting"},{id:"log-map",title:"Know Which MT4 Log Answers Which Question"},{id:"timeline",title:"Build a Failure Timeline"},{id:"read-patterns",title:"Read Common Journal Patterns"},{id:"decision-tree",title:"Use a Controlled Decision Process"},{id:"vps-checklist",title:"VPS and Terminal Checklist"},{id:"ea-checklist",title:"EA and Trade Permission Checklist"},{id:"examples",title:"Three Practical Diagnostic Examples"},{id:"when-source-is-missing",title:"When a Log Points to a Code Problem"},{id:"conclusion",title:"Conclusion: Diagnose Before Repairing"}],content:`
3260<p>An Expert Advisor can appear perfectly normal on an MT4 chart while doing nothing useful on a VPS. The smiling icon may remain in place, the chart may be open, and the terminal may reconnect after a brief interruption. None of those observations proves that initialization completed, ticks reached the program, trade permission was available, or an order request succeeded. The journal is where those separate events become evidence.</p>
3261
3262<p>This guide treats the MetaTrader journal as a timeline rather than a collection of alarming messages. That distinction is important. A single line can be harmless in context, while several ordinary lines in the right order can explain exactly why an EA missed a trade or stopped after a reboot. The goal is not to guess at strategy logic. It is to preserve the relevant records, line up clocks, identify the first abnormal event, and make one controlled change at a time.</p>
3263
3264<img src="${Mu}" alt="server rack beside MetaTrader journal logs and a diagnostic magnifying glass" style="width:100%;border-radius:8px;margin:24px 0;" />
3265
3266<p>A reader does not need to be a programmer to use this process. It starts with files and timestamps. For those learning the file relationships behind a running robot, this site also explains <a href="/blog/ex4-files-explained-for-mt4-users">what an EX4 file means in MT4</a>. A compiled file is only one part of the operating picture. The account, broker symbols, platform settings, VPS session, and incoming prices all affect what happens after the program loads.</p>
3267
3268<h2 id="why-logs-matter">Why VPS Logs Are the Best Starting Point</h2>
3269
3270<p>When an EA fails, the first reaction is often to change inputs, reinstall the robot, or attach a new copy to the chart. Those actions can remove the clues needed to identify the original fault. A VPS adds more moving parts than a desktop installation: Windows updates, remote sessions, storage pressure, terminal restarts, network interruptions, account changes, and a different data directory. The journal does not solve every problem, but it records the platform's view of many of those events.</p>
3271
3272<p>Logs are especially valuable because they separate observation from interpretation. “The EA did not trade” is an observation. “The entry rule failed” is only a theory until the surrounding records are checked. Perhaps the market was closed. Perhaps there was no tick at the expected time. Perhaps the robot rejected its own setup because spread or session filters applied. Perhaps the terminal reported a trade permission issue. A useful diagnosis names the evidence and the remaining uncertainty.</p>
3273
3274<p>There are four practical questions to answer in order:</p>
3275<ol>
3276  <li>Did the terminal and account connect normally?</li>
3277  <li>Did the EA initialize on the intended chart with the intended inputs?</li>
3278  <li>
3278Did the EA receive a tick or timer event during the period in question?</li>
3279  <li>If it attempted a trade, what response did the trade subsystem or broker return?</li>
3280</ol>
3281
3282<p>Answering those questions prevents a common mistake: treating an absent order as proof of an execution problem. An EA may have made no order attempt because its rules were not met. Conversely, an order rejection points toward permissions, pricing, volume, stops, or broker conditions, not necessarily a damaged EX4. Readers comparing recovery options should keep this distinction in mind before reaching for an <a href="/">ex4 to mq4 decompiler</a>. A journal-led diagnosis can often show whether source work is relevant at all.</p>
3283
3284<h2 id="preserve-evidence">Preserve Evidence Before Restarting</h2>
3285
3286<p>The safest first action is deliberately unexciting: record the state before altering it. Do not immediately reboot the VPS, recompile a replacement, clear logs, or remove the EA. Take screenshots of the chart, Experts tab, Journal tab, account number, server name, symbol, timeframe, EA properties, and terminal connection display. Note the local time shown by MT4 and the time zone used by the VPS if known. A broker's server time can differ from both.</p>
3287
3288<p>Next, copy the relevant log files to a dated diagnostic folder outside the platform directory. MT4 installations differ, but terminal logs and Expert Advisor logs are generally accessible from the terminal's data folder. Use the platform's Open Data Folder command rather than assuming a Windows path, especially on a hosted machine. Copy the complete files for the incident date and the previous date if the failure may have begun overnight. Do not edit the originals.</p>
3289
3290<table>
3291  <thead><tr><th>Capture</th><th>Why it matters</th><th>Helpful note</th></tr></thead>
3292  <tbody>
3293    <tr><td>Terminal Journal</td><td>Shows connection, login, chart, and platform events</td><td>Capture the day before and day of the incident</td></tr>
3294    <tr><td>Experts log</td><td>Shows EA messages, initialization, and many trading actions</td><td>Match it to the chart symbol and timeframe</td></tr>
3295    <tr><td>Account history</td><td>Confirms whether an order was sent, filled, modified, or rejected</td><td>Record the selected date range</td></tr>
3296    <tr><td>EA settings</td><td>Explains filters, magic number, risk, and session choices</td><td>Screenshot every tab, not only Inputs</td></tr>
3297    <tr><td>VPS details</td><td>Identifies restart, update, disk, or session context</td><td>Record Windows time and hosting location if available</td></tr>
3298  </tbody>
3299</table>
3300
3301<p>A checksum can be useful for a high-value investigation because it records which EX4 was examined, but it is not required for ordinary troubleshooting. More important is a simple incident note: when the last expected action occurred, when the problem was noticed, whether the terminal was restarted, and who had remote access. Write down facts rather than explanations. This makes later comparison possible after a test.</p>
3302
3303<h2 id="log-map">Know Which MT4 Log Answers Which Question</h2>
3304
3305<p>MT4 presents related records in several places, and they should not be treated as duplicates. The Journal reflects terminal-level activity. The Experts area records messages emitted by Expert Advisors and often includes loading, deinitialization, and trade-related output. A custom indicator may write its own messages, while account history provides a separate record of completed trade activity. The exact wording varies by terminal build, broker, and EA author.</p>
3306
3307<p>Start with the visible Journal and Experts tabs for the suspected minute. Then locate the corresponding daily files in the data folder for a fuller record. Search by the EA name, chart symbol, magic number if printed, and notable phrases such as initialized, deinitialized, trade, error, connect, disconnected, disabled, or timer. Preserve a few minutes on either side of a key line. An isolated message can mislead; the events before it often say why it occurred.</p>
3308
3309<p>A practical map looks like this:</p>
3310<ul>
3311  <li><strong>Connection question:</strong> begin with Journal entries around login, disconnection, reconnection, and server status.</li>
3312  <li><strong>Startup question:</strong> begin with Experts entries when the EA was attached, initialized, removed, or reloaded.</li>
3313  <li><strong>Market-data question:</strong>
3313 compare the chart's symbol and time with visible price activity and any EA tick messages.</li>
3314  <li><strong>Order question:</strong> review Experts output, terminal trade messages, and account history together.</li>
3315  <li><strong>Schedule question:</strong> compare log timestamps with broker server time, VPS time, and the EA's documented session setting.</li>
3316</ul>
3317
3318<p>Do not assume the most dramatic message is the cause. A disconnection after a rejected order may be unrelated. A warning at startup may have been resolved before the next tick. The first deviation from the expected sequence deserves more attention than the loudest phrase.</p>
3319
3320<h2 id="timeline">Build a Failure Timeline</h2>
3321
3322<p>A timeline turns scattered lines into a testable story. Use a spreadsheet, plain text table, or notebook. Choose one time reference and label it clearly. If the terminal displays broker server time, retain it as written and add separate columns for VPS local time only when conversion is certain. Guessing at time zones can create a false diagnosis, especially around daylight-saving changes.</p>
3323
3324<table>
3325  <thead><tr><th>Time shown</th><th>Source</th><th>Observed event</th><th>What it establishes</th><th>Next check</th></tr></thead>
3326  <tbody>
3327    <tr><td>08:55:02</td><td>Journal</td><td>Account connection confirmed</td><td>Terminal could reach the trading server</td><td>Check whether it stayed connected</td></tr>
3328    <tr><td>08:56:11</td><td>Experts</td><td>EA initialization message</td><td>Program loaded at that point</td><td>Verify inputs and chart identity</td></tr>
3329    <tr><td>09:00:00</td><td>Strategy note</td><td>Expected session opens</td><td>This is an expectation, not log proof</td><td>Look for tick or timer activity</td></tr>
3330    <tr><td>09:00:07</td><td>Experts</td><td>Filter reports spread too high</td><td>EA evaluated a condition</td><td>Compare with current spread rule</td></tr>
3331    <tr><td>09:03:20</td><td>Journal</td><td>Connection interruption</td><td>Later absence may be network related</td><td>Find reconnect and any missed window</td></tr>
3332  </tbody>
3333</table>
3334
3335<p>Mark three kinds of entries: expected, confirmed, and unexplained. Expected entries come from the EA's configuration or documented behavior. Confirmed entries are written in a log or account record. Unexplained gaps are where a test should focus. For example, if a robot is expected to check at a scheduled minute but the log contains neither a tick nor a timer message, changing lot size is premature. The missing event is the lead.</p>
3336
3337<p>It also helps to identify the last known good event and first known bad event. If the EA logged normal decisions until 21:58 and the terminal restarted at 22:00, the restart belongs at the center of the investigation. If it continued logging decisions but never reached an order attempt, examine filters and conditions. If an order attempt exists with an error response, preserve the exact response and the requested symbol, volume, and price.</p>
3338
3339<h2 id="read-patterns">Read Common Journal Patterns</h2>
3340
3341<p>Log messages are clues, not universal verdicts. An EA author can use custom wording, and broker responses vary. Still, several patterns recur often enough to guide the next check.</p>
3342
3343<table>
3344  <thead><tr><th>Pattern</th><th>Reasonable interpretation</th><th>First safe response</th></tr></thead>
3345  <tbody>
3346    <tr><td>Initialization followed quickly by deinitialization</td><td>The EA was removed, the chart changed, terminal settings changed, or initialization did not remain active</td><td>Check reason text, chart attachment, and AutoTrading state</td></tr>
3347    <tr><td>Regular decisions but no trade request</td><td>Rules or filters may be blocking entries</td><td>Compare each reported filter with saved inputs</td></tr>
3348    <tr><td>Trade request followed by an error or rejection</td><td>The EA reached execution, but request details or permissions need review</td><td>Record exact error, symbol, stops, volume, and market status</td></tr>
3349    <tr><td>Long silence during an expected active period</td><td>No ticks, disabled events, a terminal issue, or sparse EA logging are possible</td><td>Check connection, chart activity, timer design, and nearby Journal lines</td></tr>
3350    <tr><td>Repeated reconnects</td><td>Network, server, or VPS stability may be affecting operation</td><td>Measure the affected time window before modifying the EA</td></tr>
3351    <tr><td>Different symbol spelling than expected</td><td>A broker suffix or prefix may prevent matching logic</td><td>Compare Market Watch symbol names with EA inputs</td></tr>
3352  </tbody>
3353</table>
3354
3355<p>Error codes should be copied exactly and interpreted through the terminal documentation, broker conditions, and the surrounding event sequence. Do not rely on a screenshot of a code from a forum as a diagnosis. A price-related response may arise from a changing market, an unsuitable request parameter, or platform conditions. A permission-related response may be an account setting, the terminal's trade switch, or EA properties. The log tells an investigator where to look, not which button to press without checking.</p>
3356
3357<h2 id="decision-tree">Use a Controlled Decision Process</h2>
3358
3359<p>Once a timeline exists, use a narrow decision path. This avoids making five changes and learning nothing from the outcome.</p>
3360
3361<ol>
3362  <li><strong>No initialization record?</strong> Confirm the correct EX4 is attached to the correct chart, then inspect terminal and Experts messages around attachment. Do not assume the visible chart alone proves the loaded version.</li>
3363  <li><strong>Initialized, but no events?</strong> Confirm the connection, chart price activity, and whether the EA relies on ticks, a timer, or a new bar. Check the symbol and timeframe.</li>
3364  <li><strong>Events occurred, but no order attempt?</strong>
3364 Review the EA's printed conditions and saved inputs. If it does not log decision reasons, record that limitation rather than inventing one.</li>
3365  <li><strong>Order attempt occurred?</strong> Compare the request and response with account permissions, market state, symbol specification, and the broker's rules.</li>
3366  <li><strong>Platform instability appears first?</strong> Stabilize or document the environment before changing strategy settings. A code change cannot repair a recurring VPS restart.</li>
3367</ol>
3368
3369<p>For every branch, define a single test and a pass condition. For instance, “leave the existing settings unchanged for one scheduled session and verify that the Experts log records a timer event” is a test. “Make it trade again” is not. A controlled test is easier to reverse and safer for an account than a broad rewrite of inputs.</p>
3370
3371<h2 id="vps-checklist">VPS and Terminal Checklist</h2>
3372
3373<p>The environment deserves inspection even when the EA has been reliable for months. A VPS is not merely a screen in another location. It is a Windows computer running a specific terminal installation under specific account and network conditions.</p>
3374
3375<ul>
3376  <li>Confirm that the terminal is connected to the intended broker server and account, not a demo or alternate login.</li>
3377  <li>Check that AutoTrading is enabled at the terminal level and that the EA's own live-trading permission is consistent with the intended use.</li>
3378  <li>Verify the chart symbol, timeframe, and broker spelling. A suffix such as .m or a prefix can matter to exact string matching.</li>
3379  <li>Review whether Windows or the terminal restarted near the first bad event. Keep evidence before scheduling any update changes.</li>
3380  <li>Check free disk space and whether the terminal data folder is writable. Record actual observations, not an assumed VPS specification.</li>
3381  <li>Confirm the VPS clock and understand its relationship to broker server time before altering a session filter.</li>
3382  <li>Look for duplicate terminals or duplicate charts that may run the same magic number or compete for trade context.</li>
3383  <li>Document remote access changes. A well-meaning user can accidentally change a chart setting during maintenance.</li>
3384</ul>
3385
3386<p>Readers facing a move to a hosted environment may also find the site's <a href="/blog/expert-advisor-vps-transfer-audit-mt4">MT4 VPS transfer audit</a> useful. Transfer mistakes and runtime failures can look similar, but the first is about confirming a correct installation while the second is about locating a change in behavior after operation has begun.</p>
3387
3388<h2 id="ea-checklist">EA and Trade Permission Checklist</h2>
3389
3390<p>After the environment is documented, inspect the EA configuration without casually changing it. Save screenshots first. Inputs frequently contain session hours, maximum spread, news filters, symbol names, account restrictions, risk controls, and magic numbers. A setting that was suitable on one broker or account may be unsuitable on another, even if the robot starts normally.</p>
3391
3392<ul>
3393  <li>Compare the active inputs with the last known working record, if one exists.</li>
3394  <li>Check whether session hours use broker time, local time, UTC, or an internal conversion. Do not infer this from the label alone.</li>
3395  <li>Confirm whether the EA is designed to act on every tick, a new candle, or a periodic timer.</li>
3396  <li>Review spread, volatility, day-of-week, and open-position filters as possible intentional blockers.</li>
3397  <li>Confirm the magic number and determine whether another chart or EA uses it.</li>
3398  <li>Check symbol-specific requirements such as minimum volume, volume step, stop distance, and trading availability.</li>
3399  <li>Record any custom log message that explains a skipped trade, and retain its surrounding timestamp.</li>
3400</ul>
3401
3402<p>A stopped EA does not automatically indicate a broken strategy. It may be following its own rules in a market condition the operator did not expect. That is why the correct question is “what did it observe and decide?” rather than “why did it disobey?” The answer may remain unknown when a compiled EA produces minimal logs, but an honest unknown is preferable to a confident but unsupported repair.</p>
3403
3404<h2 id="examples">Three Practical Diagnostic Examples</h2>
3405
3406<h3>Example 1: The chart looks active but the robot misses the session</h3>
3407<p>An operator expects an entry shortly after a scheduled session begins. The chart has a smiling EA icon, but account history shows no request. The timeline shows initialization earlier in the day, then no Experts messages at the scheduled minute. The Journal shows a connection interruption across that window, followed by a re
3407connect. The next step is not to widen the EA's session hours. It is to determine whether the robot uses ticks or a timer, whether price delivery resumed, and whether the missed window coincided with the interruption. A later successful log entry can confirm that the EA was not permanently detached.</p>
3408
3409<h3>Example 2: Repeated order errors after a broker change</h3>
3410<p>An EA prints a trade attempt, then a response that indicates the request was not accepted. The operator recently moved the terminal to a new broker. The preserved inputs show an old symbol name, while Market Watch uses a similar name with a suffix. The correct conclusion is not yet “the code is corrupt.” First compare every requested symbol and volume setting with the new broker's specification. One controlled test on a suitable non-live environment, where appropriate, can establish whether configuration alignment fixes the request. Keep normal risk controls in place and avoid treating a test as financial advice or a performance promise.</p>
3411
3412<h3>Example 3: The EA stopped after an overnight restart</h3>
3413<p>Journal entries show terminal startup during the night. Experts output shows a deinitialization event before that restart but no later initialization for the expected chart. Screenshots reveal the chart remained open but the EA permission setting was not preserved as expected. Here, a new EX4 download would not address the cause. The repair is procedural: restore the intended attachment and permissions, record the configuration, then observe the next expected event in the logs. If restarts recur, the VPS and terminal setup need separate attention.</p>
3414
3415<h2 id="when-source-is-missing">When a Log Points to a Code Problem</h2>
3416
3417<p>Sometimes the evidence does point beyond configuration. Repeated runtime messages, a reproducible initialization failure under a stable environment, or logic that cannot be explained from available inputs may justify source review. That is a different project from ordinary VPS troubleshooting. It should begin with rights, a preserved original EX4, documented symptoms, and a narrowly stated maintenance purpose.</p>
3418
3419<p>For an owner or authorised maintainer who has lost source, an independent review of the service at ForexMQ5 may be relevant after the log work is complete. The useful handover is not simply “EA does not trade.” It includes the untouched EX4, build and terminal information, broker symbol, screenshots of inputs, the time-bounded Journal and Experts excerpts, and a description of the reproducible symptom. That gives a technical reviewer a clearer starting point while avoiding speculation about hidden strategy logic.</p>
3420
3421<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
3422  <h3 style="margin-top:0;">Need an Authorised Source Recovery Review?</h3>
3423  <p>ForexMQ5 is reviewed as a professional option for owners and authorised maintainers with a documented recovery need. Preserve the EX4 and diagnostic timeline before requesting an assessment.</p>
3424  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
3425</div>
3426
3427<p>Source recovery does not guarantee that a fault will be easy to identify or that reconstructed code will match an original development project exactly. Any recovered output should be treated as code requiring review, compilation checks, controlled testing, and appropriate authorization. Readers considering a documented maintenance path can compare <a href="/">ex4 decompile</a> options, while remembering that this review site explains the options rather than providing the underlying service or making claims about a particular trading outcome.</p>
3428
3429<h2 id="conclusion">Conclusion: Diagnose Before Repairing</h2>
3430
3431<p>MT4 VPS troubleshooting is most effective when the journal becomes a timeline. Preserve the original records, identify the last known good event, locate the first unexplained change, and test one hypothesis at a time. Start with connection, attachment, incoming events, and order responses before blaming the strategy or replacing files. That sequence protects evidence and reduces unnecessary changes.</p>
3432
3433<p>A disciplined log review also improves communication with a developer, broker, VPS host, or authorised recovery provider. Instead of reporting that an EA “failed,” an operator can say what happened, when it happened, which records supp
3433ort it, and what remains unconfirmed. That is the foundation for a safer technical decision, whether the result is a simple settings correction, an environment repair, or a justified source-maintenance investigation.</p>
3434`},{slug:"mql4-indicator-buffer-debugging-guide",title:"MQL4 Indicator Buffer Debugging: Fix Missing Lines and Wrong Signals",metaTitle:"MQL4 Indicator Buffer Debugging: Fix Missing Lines and Wrong Signals",metaDescription:"A practical MQL4 guide to tracing indicator buffers, restoring missing chart lines, and diagnosing wrong signals with Data Window checks and repeatable tests.",keywords:"MQL4 indicator buffer debugging, missing indicator lines MT4, wrong MQL4 signals, SetIndexBuffer guide, MT4 Data Window debugging, custom indicator buffers",excerpt:"Missing lines and misplaced arrows usually begin with a buffer mapping, index, drawing, or calculation problem. This guide shows how to trace each MQL4 indicator buffer from calculation to chart, test it safely, and document a reliable fix.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"19 min read",featuredImage:Su,imageAlt:"Forex chart showing multiple indicator lines connected to labeled MQL4 data buffers and debugging tools",tableOfContents:[{id:"symptom-map",title:"Start With a Symptom Map"},{id:"buffer-contract",title:"Understand the Buffer Contract"},{id:"drawn-not-drawn",title:"Why a Calculated Line Is Not Drawn"},{id:"index-direction",title:"Index Direction and Recalculation"},{id:"signal-errors",title:"Tracing Wrong Signals Bar by Bar"},{id:"debug-workbench",title:"Build a Practical Debug Workbench"},{id:"repair-sequence",title:"A Safe Repair Sequence"},{id:"reviewing-recovered-code",title:"Reviewing Recovered Indicator Code"},{id:"checklist",title:"Pre-Release Checklist"},{id:"conclusion",title:"Conclusion"}],content:`
3435<p>A custom MT4 indicator can appear simple on the chart while hiding several separate systems underneath it. A moving line, color histogram, arrow, or alert is normally the final output of a calculation loop. Between the input price series and that final mark sit declared arrays, buffer bindings, drawing settings, bar indexes, empty-value rules, and recalculation logic. When one piece disagrees with another, the visible symptom can be misleading. A line that seems missing may contain values but use the wrong draw type. An arrow that looks late may be placed on the intended bar but read with the opposite index direction. A Data Window value can be correct while the chart remains blank.</p>
3436
3437<p>This guide is for developers maintaining an MQ4 indicator they are entitled to inspect, including a personally written file or an authorised recovery project. It focuses on diagnosis rather than trading claims. Readers assessing an authorised recovery route can also review the site’s <a href="/">ex4 to mq4 decompiler</a> information. A buffer repair should be verified on historical bars, a changing current bar, and more than one symbol where appropriate. That matters because an indicator that merely looks plausible on one screenshot may still shift signals, repaint unexpectedly, or fail after the next tick.</p>
3438
3439<img src="${Su}" alt="Forex chart with multiple indicator lines linked to labeled MQL4 data buffers and debugging tools" style="width:100%;border-radius:8px;margin:24px 0;" />
3440
3441<p>Readers who are still becoming familiar with the relationship between compiled and source files may first find the site’s <a href="/blog/mql4-to-ex4-compilation-explained">MQL4 to EX4 compilation explanation</a> useful. For everyone else, the productive mindset is this: treat every plotted feature as evidence from one named buffer. Follow that buffer backwards through the code, then forward into MT4’s display settings. The path is concrete enough to test.</p>
3442
3443<h2 id="symptom-map">Start With a Symptom Map</h2>
3444
3445<p>Do not begin by changing formulas. First name the visible defect precisely. “The indicator is broken” combines too many possibilities. A symptom map narrows the search and preserves a before-and-after record for later testing. Capture the symbol, timeframe, indicator inputs, build environment, approximate bar time, and a screenshot with the Data Window open. If the defect occurs only after a refresh or only on the newest candle, say so.</p>
3446
3447<table>
3448<thead><tr><th>
3448Observed symptom</th><th>Likely layer to inspect first</th><th>Useful first check</th></tr></thead>
3449<tbody>
3450<tr><td>Whole line is absent</td><td>Binding or drawing setup</td><td>Confirm SetIndexBuffer, draw style, and non-empty values</td></tr>
3451<tr><td>Line begins far to the right</td><td>Loop start or draw begin</td><td>Compare SetIndexDrawBegin with required lookback</td></tr>
3452<tr><td>Gaps appear between valid-looking values</td><td>Empty values or conditional assignment</td><td>Inspect buffer values around each gap in Data Window</td></tr>
3453<tr><td>Arrows arrive one candle late</td><td>Series indexing or confirmation rule</td><td>Mark the calculation index and candle time in the log</td></tr>
3454<tr><td>Signals change after refresh</td><td>Recalculation and use of future bars</td><td>Test closed bars before and after reload</td></tr>
3455<tr><td>Only one color disappears</td><td>Separate color buffer or plot index</td><td>Map each visual color to its actual buffer number</td></tr>
3456</tbody>
3457</table>
3458
3459<p>Separate a missing plot from a missing calculation. In MT4, a custom indicator can have a buffer value in the Data Window and still not render a recognizable object. Conversely, it can show an old line even when the latest calculation no longer updates the correct cells. The fastest question is: which exact buffer should account for this mark, and what value does that buffer hold at the affected bar?</p>
3460
3461<p>Create a one-page buffer map before editing. List buffer number, array name, intended purpose, draw style, color, empty-value convention, and formula source. If the file contains six buffers but only two lines are expected, identify whether the others are calculation-only arrays, color indexes, arrow plots, or legacy outputs. This exercise frequently exposes an accidental mismatch between a readable name and the numeric index used in setup code.</p>
3462
3463<h2 id="buffer-contract">Understand the Buffer Contract</h2>
3464
3465<p>An indicator buffer is an array that MetaTrader can expose to the indicator engine. The core contract is established when a declared array is attached with SetIndexBuffer. The numeric index is the plot slot. The array is the storage. A later call such as SetIndexStyle configures how that slot is presented. The three must refer to the same intended feature.</p>
3466
3467<pre><code>double FastLine[];
3468double SlowLine[];
3469
3470int OnInit() {
3471  SetIndexBuffer(0, FastLine, INDICATOR_DATA);
3472  SetIndexBuffer(1, SlowLine, INDICATOR_DATA);
3473  SetIndexStyle(0, DRAW_LINE, STYLE_SOLID, 2, clrDodgerBlue);
3474  SetIndexStyle(1, DRAW_LINE, STYLE_SOLID, 2, clrOrange);
3475  SetIndexEmptyValue(0, EMPTY_VALUE);
3476  SetIndexEmptyValue(1, EMPTY_VALUE);
3477  return(INIT_SUCCEEDED);
3478}</code></pre>
3479
3480<p>This arrangement is easy to read because number zero remains FastLine throughout. A common failure is more subtle: the developer binds FastLine at zero but styles slot one as if it were FastLine, or calculates into an auxiliary array while the visible buffer remains untouched. Another is to reuse one numeric slot for two concepts after a partial refactor. The compiler may accept all of these cases. MT4 has no way to know that a blue line was meant to show a fast average rather than a signal threshold.</p>
3481
3482<h3>Check declarations against declared capacity</h3>
3483
3484<p>Older MQL4 files may use IndicatorBuffers to reserve a total number of buffers. Every visible and calculation buffer that needs terminal management must fit the intended setup. Count actual SetIndexBuffer calls, then compare that count with the configured capacity and any indicator property. Do not assume that a buffer mentioned in a comment is connected. Search for its exact array name and for its numeric slot.</p>
3485
3486<ol>
3487<li>Find every double array that appears to be a buffer.</li>
3488<li>Find each SetIndexBuffer call and write down index, array name, and buffer type.</li>
3489<li>Find every SetIndexStyle, SetIndexLabel, SetIndexArrow, and SetIndexEmptyValue call for that index.</li>
3490<li>Find every calculation assignment to that array.</li>
3491<li>Confirm that one visual purpose has one unambiguous route from formula to plot.</li>
3492</ol>
3493
3494<p>Labels deserve attention because they make the Data Window readable. A label does not repair an array, but a specific label such as “Fast baseline” is much more useful than “Buffer 0” when comparing a chart with a log. It also makes an accidental swap obvious. When reviewing code from a source-recovery project, clear labels and a buffer map are often more valuable than immediately attempting to rename every variable.</p>
3495
3496<h2 id="drawn-not-drawn">Why a Calculated Line Is Not Drawn</h2>
3497
3498<p>Once the data path is known, inspect rendering. A buffer must have values that the selected drawing style can use. DRAW_LINE joins successive non-empty numeric values. DRAW_HISTOGRAM uses vertical columns relative to its drawing baseline. DRAW_ARROW needs an arrow code set for the slot. DRAW_NONE intentionally hides a buffer while keeping it available for calculations or calls from another program. A buffer assigned DRAW_NONE is not a failed chart line.</p>
3499
3500<p>Empty values are equally important. EMPTY_VALUE is a special sentinel c
3500ommonly used to tell the terminal not to draw a point. It is appropriate before a moving average has enough source bars or when an arrow condition is false. But it must be used consistently. A zero is a real value in many indicator windows. If code writes zero to an arrow buffer when no signal exists, MT4 may draw symbols at the zero level rather than hide them. If code writes EMPTY_VALUE into a main-chart price line, the resulting discontinuity may look like a formula failure.</p>
3501
3502<h3>Distinguish intentional gaps from accidental gaps</h3>
3503
3504<p>For a line based on a 20-bar lookback, the earliest 19 bars should usually be empty because there is insufficient history. A gap later in the series needs an explanation. Look for a branch that skips assignment, a divide-by-zero safeguard, a session filter, or an array access failure. Every calculation pass should either assign a deliberate output or explicitly retain a documented previous value. Leaving a cell untouched can show stale data from a prior calculation pass.</p>
3505
3506<table>
3507<thead><tr><th>Setting or value</th><th>What it does</th><th>Frequent mistake</th></tr></thead>
3508<tbody>
3509<tr><td>DRAW_LINE</td><td>Connects visible numeric points</td><td>Expecting it to show a value separated by EMPTY_VALUE</td></tr>
3510<tr><td>DRAW_ARROW</td><td>Draws a symbol at buffer price</td><td>Forgetting SetIndexArrow or using zero for no signal</td></tr>
3511<tr><td>EMPTY_VALUE</td><td>Suppresses a plotted point</td><td>Using it in the wrong buffer or only on some passes</td></tr>
3512<tr><td>SetIndexDrawBegin</td><td>Hides unreliable initial bars</td><td>Setting a larger value than the formula needs</td></tr>
3513<tr><td>SetIndexShift</td><td>Moves display position horizontally</td><td>Mistaking a shifted line for a late calculation</td></tr>
3514</tbody>
3515</table>
3516
3517<p>Also inspect indicator scale and chart location. A price-level buffer drawn in a separate oscillator window can seem absent because its values lie outside a useful scale. An oscillator buffer drawn on the main price chart can flatten against the bottom. That is not a buffer calculation defect, but it is still a setup defect. Compare the buffer’s units with the indicator window and intended levels before touching arithmetic.</p>
3518
3519<h2 id="index-direction">Index Direction and Recalculation</h2>
3520
3521<p>Index direction is the source of many credible-looking wrong signals. In MT4 price arrays commonly operate as time series: index zero is the current, forming bar; one is the last closed bar; larger indexes move backward in time. A custom array’s direction must be understood explicitly rather than guessed from its name. ArraySetAsSeries can influence local arrays, while indicator buffers have platform behavior that needs testing in the specific code path.</p>
3522
3523<p>The practical rule is to annotate the intended bar at each calculation. If an entry condition is confirmed on the last closed candle, code should read index one and write the arrow to the documented bar index. Writing to zero instead creates a signal that can appear and vanish while the candle forms. Writing to two can create a signal that looks late. Neither outcome proves a poor strategy. They prove that the visual event and the indexing decision differ.</p>
3524
3525<pre><code>for(int i = start; i >= 0; i--) {
3526  BuyArrow[i] = EMPTY_VALUE;
3527  if(Close[i] > FastLine[i] && Close[i + 1] <= FastLine[i + 1]) {
3528    BuyArrow[i] = Low[i] - 10 * Point;
3529  }
3530}</code></pre>
3531
3532<p>This simplified crossover example has important questions. Is i plus one available for every loop iteration? Does FastLine have a valid value at both indexes? Is a crossover intended on a closed bar only? Is the arrow position suitable for symbols with different digits? The example is not a production trading rule. It is a reminder that a correct condition can still place a misleading mark when surrounding buffer state is not valid.</p>
3533
3534<h3>Use prev_calculated as a boundary, not a mystery</h3>
3535
3536<p>In modern MQL4 OnCalculate, rates_total identifies available bars and prev_calculated reports work completed by a prior call. A robust loop recalculates enough recent bars to account for dependencies, while avoiding needless full-history work on every tick. The exact start depends on lookback length and whether the formula references neighboring bars. Recalculating too little leaves stale output after history changes. Recalculating every bar may be acceptable for a small indicator but can mask logic errors and waste resources in a complex one.</p>
3537
3538<p>When debugging, temporarily favor clarity over micro-optimization. Establish a known-good full recalculation on a stable history. Then introduce a carefully documented incremental start point and compare output at several fixed timestamps. The goal is equality between a fresh load and an update path for c
3538ompleted bars. If those differ, the defect is usually in loop bounds, initialization, or state retained outside the buffers.</p>
3539
3540<h2 id="signal-errors">Tracing Wrong Signals Bar by Bar</h2>
3541
3542<p>A wrong signal should be investigated like a short chain of evidence, not debated by eye. Pick one arrow or line crossing with an unambiguous candle time. Record the index, Open, High, Low, Close, source indicator values, intermediate values, final signal buffer value, and expected result. Then inspect the same record after a refresh. This turns “it moved” into a statement such as “BuyArrow[1] was assigned at 10:00, but after reload the branch read an incomplete value from buffer index zero.”</p>
3543
3544<p>Useful diagnostic output is concise and temporary. Logging every bar on every tick hides the useful event and can make MT4 slow. Instead, gate output by a selected time, a debug input, or a small index range. Print the array name, index, candle time, relevant inputs, result, and branch name. Remove or disable verbose tracing after the issue is understood.</p>
3545
3546<h3>Four signal integrity questions</h3>
3547
3548<ol>
3549<li><strong>What bar owns the signal?</strong> Define whether the condition belongs to the forming bar, the just-closed bar, or an earlier confirmed pattern.</li>
3550<li><strong>Which values fed it?</strong> Verify all source buffers are valid at that bar and use the same orientation.</li>
3551<li><strong>Was the output cleared first?</strong> Arrow buffers should normally receive EMPTY_VALUE before a new condition is tested, preventing stale arrows.</li>
3552<li><strong>Can later data alter it?</strong> If yes, label the behavior as provisional rather than presenting a historical arrow as fixed confirmation.</li>
3553</ol>
3554
3555<p>Repainting is a description of changed historical output, not automatically proof of a defect. Some centered calculations need bars on both sides and therefore necessarily revise recent values. The engineering issue is disclosure and control: a user should know which bars are provisional, and the code should not silently convert an unconfirmed value into a past signal after the fact. Save screenshots before and after new bars arrive, then compare the final values of already closed candles.</p>
3556
3557<p>For broader deployment discipline, the site’s guide to <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating recovered MQL4 before live deployment</a> offers a useful separate testing framework. Indicator visuals may be inputs to an Expert Advisor or a discretionary decision, so a buffer fix deserves the same cautious test environment as other code changes.</p>
3558
3559<h2 id="debug-workbench">Build a Practical Debug Workbench</h2>
3560
3561<p>A useful workbench does not require exotic tools. It requires a repeatable order. Keep an untouched original, a working copy, and a change note that states what was altered and why. Compile after small changes. On the chart, use the Data Window to inspect named buffer values at the same candle used in logs. Enable visual mode in Strategy Tester when the indicator can be exercised there, but do not treat a favorable visual as proof of correct indexing.</p>
3562
3563<p>A practical session can follow this sequence:</p>
3564
3565<ol>
3566<li>Load the indicator with default inputs on a chart that has sufficient history.</li>
3567<li>Open the Data Window and hover the symptom candle. Record every relevant labeled buffer.</li>
3568<li>Confirm the indicator is attached to the intended chart window and its visible plot styles match the buffer map.</li>
3569<li>Add temporary logging for only the target bar and one neighboring bar.</li>
3570<li>Refresh or change timeframe, then compare values and plotted locations.</li>
3571<li>Make one minimal correction, compile, and repeat the same observation.</li>
3572</ol>
3573
3574<p>Use visual markers sparingly. A temporary buffer with DRAW_ARROW can identify loop indexes, but it must be mapped and later removed or hidden. Comments that show the current index and value can help while watching a live tick, though they are not a replacement for records. In recovered code, avoid changing formula, plot styling, and index flow in one pass. A smaller change set makes it possible to attribute an improvement to a specific repair.</p>
3575
3576<h3>Common false leads</h3>
3577
3578<p>Changing colors is not a fix for an unassigned buffer. Increasing the number of indicator buffers does not repair an index swap. Replacing every zero with EMPTY_VALUE can destroy valid oscillator output. Starting every loop at zero may avoid an out-of-range error while reversing the intended order. Copying a fragment from a different indicator can introduce a new mismatch in draw style, array orientation, or price units. Each intervention should answer a named observation from the symptom map.</p>
3579
3580<h2 id="repair-sequence">A Safe Repair Sequence</h2>
3581
3582<p>The following decision path keeps a buffer repair narrow. It is designed for maintainers who have authority to edit the file, not for bypassing restrictions in third-party software.</p>
3583
3584<ol>
3585<li><strong>Confirm the visual target.</strong> Identify the exact line, color, arrow, and timeframe that are wrong.</li>
3586<li><strong>Map its numeric slot.</strong> Trace the plot setting to SetIndexBuffer and the corresponding array.</li>
3587<li><strong>Inspect the target cell.</strong> At one affected bar, determine whether the array contains a valid numeric value, zero, or EMPTY_VALUE.</li>
3588<li><strong>Trace inputs.</strong> Check source buffers and price arrays at the same index and at every referenced neighbor.</li>
3589<li><strong>Inspect loop bounds.</strong> Ensure all referenced indexes exist and the loop reaches every bar that should update.</li>
3590<li><strong>Correct one contract breach.</strong> Examples include binding the intended array, clearing an arrow buffer, or adjusting a documented draw begin value.</li>
3591<li><strong>Retest fixed cases.</strong> Repeat the original screenshot and Data Window check, then refresh and change timeframe.</li>
3592<li><strong>Test edge conditions.</strong> Check insufficient history, a new bar, a missing quote interval, and an input change.</li>
3593</ol>
3594
3595<p>Keep formula changes separate from display repairs. If a moving average is calculated correctly but drawn through the wrong slot, fix the slot first. If the line then remains mathematically wrong, create a new issue for the formula. This separation protects against an attractive but untrustworthy result where tw
3595o mistakes happen to cancel on a sample chart.</p>
3596
3597<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
3598  <h3 style="margin-top:0;">Need an Authorised EX4 Recovery Review?</h3>
3599  <p>For a file the requester is entitled to recover and maintain, ForexMQ5 is reviewed as a professional option for obtaining a readable starting point before a careful buffer audit.</p>
3600  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
3601</div>
3602
3603<h2 id="reviewing-recovered-code">Reviewing Recovered Indicator Code</h2>
3604
3605<p>Recovered MQL4 may preserve functional structure without preserving the original author’s names, comments, or layout. That makes buffer debugging more dependent on behavior. Start by locating indicator properties, buffer declarations, setup calls, and every array assignment. Give neutral working names in a private review note before renaming code. For example, “plot slot 0, blue price line” is safer than guessing it is a trend filter before the formula supports that conclusion.</p>
3606
3607<p>Build a dependency sheet with columns for output buffer, calculation expression, input arrays, lookback, display rule, and alert rule. This reveals whether a visible arrow depends on a hidden intermediate buffer, whether two plots share a source, and whether an alert reads a different index than the drawing code. It also prevents a maintainer from deleting an apparently unused array that actually feeds a later condition.</p>
3608
3609<p>Recovery quality is not measured only by whether the file compiles. A compiled indicator can still have placeholder names, missing external dependencies, altered settings, or output that needs validation. Readers evaluating their options can use an <a href="/">mql4 decompiler</a> overview on the homepage to understand the review site’s distinction between authorised professional recovery, older utilities, and hands-on work. The service at ForexMQ5 should be considered only for legitimate, documented purposes, and recovered output should remain subject to technical review.</p>
3610
3611<p>When an indicator is part of a purchased or inherited package, preserve evidence of permission and avoid treating recovery as a right to redistribute strategy logic. A technical maintenance goal can be legitimate while contractual and intellectual-property constraints still matter. If authority is unclear, resolve that question before commissioning or modifying the code.</p>
3612
3613<h2 id="checklist">Pre-Release Checklist</h2>
3614
3615<p>Before calling a missing-line or wrong-signal fix complete, use this checklist. It is intentionally practical: each item should be answerable from code, a chart, or a recorded test.</p>
3616
3617<ul>
3618<li>Every visible plot has a documented numeric index, buffer array, label, style, and color.</li>
3619<li>Every bound buffer is assigned on every relevant calculation pass or deliberately assigned EMPTY_VALUE.</li>
3620<li>Zero is used only where zero is a meaningful plotted value.</li>
3621<li>Initial lookback bars are hidden deliberately with draw-begin or empty values.</li>
3622<li>Loop bounds protect every i plus or minus offset used by the formula.</li>
3623<li>Closed-bar and current-bar behavior are named and tested separately.</li>
3624<li>Fresh-load output matches incremental output for selected completed bars.</li>
3625<li>Data Window labels and values match the intended chart feature.</li>
3626<li>Refresh, timeframe change, input change, and insufficient-history behavior have been checked.</li>
3627<li>The change note states the symptom, root cause, code change, and test evidence.</li>
3628</ul>
3629
3630<p>Finally, test in a non-production environment before relying on an indicator for any trading decision. Platform data, symbol conventions, spreads, execution, and market conditions can affect outcomes beyond a buffer repair. The purpose of this process is to improve code observability and reduce avoidable display errors, not to promise a market result.</p>
3631
3632<h2 id="conclusion">Conclusion</h2>
3633
3634<p>Missing indicator lines and wrong signals become manageable when the chart is treated as the endpoint of a traceable buffer contract. Name the symptom, map the numeric plot to its array, inspect the value at a specific bar, verify drawing rules, and then examine indexes and recalculation boundaries. That order is more reliable than altering formulas until a screenshot looks better.</p>
3635
3636<p>The strongest repairs are small, documented, and repeatable. They explain why a buffer was absent or displaced, prove the correction through the Data Window and controlled comparisons, and retain clear limits around provisional bars. For authorised maintenance of an MQL4 indicator, this approach turns debugging tools into evidence rather than guesswork.</p>
3637`},{slug:"mt4-multi-timeframe-indicator-validation",title:"Validate Multi-Timeframe MT4 Indicators Without Repainting Mistakes",metaTitle:"Validate Multi-Timeframe MT4 Indicators Without Repainting | MT4 Guide",metaDescription:"Learn a practical MT4 multi-timeframe indicator validation process. Compare synchronized charts, detect repainting, verify closed-bar signals, and document results before use.",keywords:"MT4 multi-timeframe indicator validation, MT4 repainting indicator test, synchronized forex charts, closed bar signal verification, multi-timeframe forex indicator checklist",excerpt:"A multi-timeframe MT4 indicator can look precise while quietly using unfinished higher-timeframe data. This practical guide shows how to synchronize charts, distinguish recalculation from repainting, test closed-bar signals, and keep an evidence trail.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:Cu,imageAlt:"Synchronized MT4 forex charts used to validate multi-timeframe indicator signals",tableOfContents:[{id:"why-validation-matters",title:"Why Multi-Timeframe Signals Need a Different Test"},{id:"terms-and-timing",title:"Repainting, Recalculation, and Bar Timing"},{id:"build-reference",title:"Build a Synchronized Reference Workspace"},{id:"signal-contract",title:"Write a Signal Contract Before Testing"},{id:"closed-bar-protocol",title:"The Closed-Bar Validation Protocol"},{id:"history-and-refresh",title:"History, Refreshes, and Backtest Illusions"},{id:"example",title:"Worked Example: H1 Trend Filter on M15"},{id:"diagnose-differences",title:"How to Diagnose a Mismatch"},{id:"decision-checklist",title:"Release Checklist and Decision Rules"},{id:"reviewing-code",title:"When Source Review Adds Clarity"},{id:"conclusion",title:"Conclusion: Trust the Timestamp, Not the Screenshot"}],content:`
3638<p>A multi-timeframe indicator promises a useful idea: let a lower chart provide timing while a higher chart supplies context. An M15 chart might show an entry marker only when an H1 trend filter agrees. A scalper may watch M5 while a dashboard summarizes H4 momentum. The idea is reasonable, but the validation burden is higher than 
3638it is for a single-chart tool. The value displayed on the lower chart can depend on a higher-period candle that is still being built, on unavailable history, or on a mapping rule that shifts after a refresh.</p>
3639
3640<p>That is why a good-looking chart is not enough. An arrow that appears beside an earlier M15 candle may have been unavailable when that candle closed. A higher-timeframe line can legitimately move while its current candle is open, yet a tool that presents that moving value as a settled historical signal can mislead a user. This guide provides a practical, repeatable process for checking multiple synchronized forex chart timeframes in MetaTrader 4. It is written from an independent review perspective. It does not claim that this site provides indicator development, trading signals, or a trading service.</p>
3641
3642<img src="${Cu}" alt="Synchronized MT4 forex charts used to validate multi-timeframe indicator signals" style="width:100%;border-radius:8px;margin:24px 0;" />
3643
3644<p>The goal is not to prove that an indicator will be profitable. No chart exercise can establish that with certainty. The goal is narrower and more useful: determine what the indicator knew at a particular time, whether its plotted signals remain where they first appeared, and whether its stated multi-timeframe logic is reproducible. Those answers help a trader decide whether a tool is suitable for further demo observation, authorized code review, or rejection.</p>
3645
3646<h2 id="why-validation-matters">Why Multi-Timeframe Signals Need a Different Test</h2>
3647
3648<p>A single-timeframe moving average is normally evaluated from bars on the chart where it is drawn. A multi-timeframe calculation adds at least three questions. Which higher bar supplies the value? Is that bar closed? How does the indicator assign that value to the lower bars that sit inside it? MT4 functions such as iMA and iCustom can request data from another timeframe, but the platform cannot make a forming H1 candle final merely because it is being viewed from M15.</p>
3649
3650<p>Consider four M15 candles from 10:00 through 10:59. They collectively form the 10:00 H1 candle. At 10:15, 10:30, and 10:45, the H1 candle has not closed. Its high, low, close, and any calculation based on close can still change. If an indicator uses shift 0 from H1, it is intentionally reading that unfinished candle. That may be acceptable for a live information panel, provided the display says it is provisional. It is not acceptable to call an arrow at 10:15 a confirmed H1-based signal if the condition can disappear before 11:00.</p>
3651
3652<p>Many misunderstandings are really timing misunderstandings. Users see a clean historical row of arrows and assume every arrow was visible in real time. Developers may mean “the condition is true after the higher candle finishes,” while users hear “the condition was known at the lower candle close.” Validation turns those vague claims into timestamped observations.</p>
3653
3654<table>
3655<thead><tr><th>Question</th><th>Why it matters</th><th>Evidence to retain</th></tr></thead>
3656<tbody>
3657<tr><td>What is the signal timeframe?</td><td>It defines when an entry marker can be confirmed.</td><td>Chart screenshot and indicator inputs.</td></tr>
3658<tr><td>What is the filter timeframe?</td><td>It determines the slowest confirmation clock.</td><td>Matching higher chart with candle times visible.</td></tr>
3659<tr><td>Does the logic use bar 0 or bar 1?</td><td>Bar 0 is still forming; bar 1 is the most recently closed bar.</td><td>Documentation, source review, or live observation.</td></tr>
3660<tr><td>When is the marker written?</td><td>A late marker can make history look earlier than real availability.</td><td>Timestamped captures during the session.</td></tr>
3661<tr><td>Does a refresh change old marks?</td><td>That can reveal repainting, history dependence, or a mapping problem.</td><td>Before and after images plus saved templates.</td></tr>
3662</tbody>
3663</table>
3664
3665<p>Readers comparing the technical integrity of an automated system should keep this separate from performance marketing. The site guide on <a href="/blog/how-to-ver
3665ify-forex-ea-backtest-results">verifying forex EA backtest results</a> addresses how reports and test conditions can be examined. A multi-timeframe indicator test asks an earlier question: were the displayed conditions actually available at the claimed decision point?</p>
3666
3667<h2 id="terms-and-timing">Repainting, Recalculation, and Bar Timing</h2>
3668
3669<p>The word repainting is used too broadly. A precise vocabulary prevents false accusations and weak validation.</p>
3670
3671<ul>
3672<li><strong>Normal intrabar recalculation:</strong> A current-bar line, color, or value changes as new ticks arrive. This is expected when the calculation includes the open bar and the behavior is disclosed.</li>
3673<li><strong>Higher-timeframe updating:</strong> A lower chart repeats the current H1 or H4 value until the higher candle changes. This can be normal, but it is provisional until the higher candle closes.</li>
3674<li><strong>Confirmed-bar revision:</strong> A marker on a candle that had already been presented as closed moves, vanishes, or appears later without a data correction. This needs investigation.</li>
3675<li><strong>Historical backfilling:</strong> An indicator draws a signal on an old lower bar only after a later higher candle finishes. The visual location may be historical, but the availability time is later.</li>
3676<li><strong>Data revision:</strong> A broker history update, missing-bar repair, symbol change, or timeframe reload changes input prices. This can alter output without proving deceptive coding, but it still affects reproducibility.</li>
3677</ul>
3678
3679<p>There is no universal rule that every tool must use only closed bars. A discretionary dashboard may deliberately show a live H4 condition. The critical requirement is that the user can tell live information from confirmed information. A responsible test labels the two states. For example, “H1 trend currently bullish, confirmation pending at 11:00 server time” describes uncertainty honestly. “H1 bullish signal at 10:15” does not, if the H1 candle was incomplete.</p>
3680
3681<h3>Use the slowest clock</h3>
3682
3683<p>For a rule involving M5, M15, and H1, H1 is the slowest clock. A fully confirmed rule cannot exist until the relevant H1 candle has closed, unless the specification explicitly accepts provisional conditions. This simple principle is a strong defense against attractive but impossible claims. It also affects alerts. An alert fired at 10:20 on an M5 chart may be a useful heads-up, but it should not be logged as a confirmed H1 filter signal until the higher candle completes.</p>
3684
3685<h2 id="build-reference">Build a Synchronized Reference Workspace</h2>
3686
3687<p>Validation becomes unreliable when charts are not observing the same market data. Set up a clean MT4 profile using one broker account, one symbol spelling, and one terminal build. Open the exact signal timeframe and each referenced timeframe. For an M15 indicator with an H1 filter, open both M15 and H1 charts for EURUSD from the same server. If the broker uses a suffix, use it consistently. EURUSD and EURUSD.a may have different history or pricing.</p>
3688
3689<ol>
3690<li><strong>Record the environment.</strong> Note broker server, account type, terminal build, symbol, digits, spread display, and the terminal time shown on charts.</li>
3691<li><strong>Load enough history.</strong> Scroll each chart back far enough for the indicator lookback and its higher-period dependencies. A 200-period H1 average requires more than a few visible days of M15 data.</li>
3692<li><strong>Apply identical inputs.</strong> Save the indicator set file if possible. Record every period, price type, alert option, offset, and timeframe selector.</li>
3693<li><strong>Align chart times.</strong> Ensure the vertical crosshair points to the same server time on all charts. A screenshot with the Data Window open is often more useful than an image of colored lines alone.</li>
3694<li><strong>Preserve a baseline.</strong> Save the profile or template and take a dated initial capture before changing timeframes, symbols, or parameters.</li>
3695</ol>
3696
3697<p>Do not silently substitute a different feed to make a result look better. Different broker candles, particularly around session boundaries, can produce different oscillator values and moving average crossings. A discrepancy may be a feed effect rather than an indicator defect. The review task is to i
3697dentify it, not force every chart to agree.</p>
3698
3699<p>For tools acquired as compiled files, record the filename, version label, source, and checksum where practical. A later update with the same display name can invalidate a comparison. This is one reason a basic <a href="/">mt4 ea decompiler</a> discussion belongs in the wider education around compiled MT4 software: understanding the artifact, its build, and its dependencies helps define what can realistically be reviewed. It is not permission to inspect or copy software without the required rights.</p>
3700
3701<h2 id="signal-contract">Write a Signal Contract Before Testing</h2>
3702
3703<p>A signal contract is a one-page description of what counts as a valid signal. It is not legal paperwork. It prevents a test from changing its standard after an appealing chart appears. Use the vendor documentation if it exists, but replace promotional language with observable conditions.</p>
3704
3705<table>
3706<thead><tr><th>Field</th><th>Example entry</th></tr></thead>
3707<tbody>
3708<tr><td>Instrument and chart</td><td>EURUSD, M15, broker server time</td></tr>
3709<tr><td>Fast condition</td><td>M15 close above a 20-period moving average</td></tr>
3710<tr><td>Higher filter</td><td>Previous completed H1 close above a 50-period moving average</td></tr>
3711<tr><td>Confirmation event</td><td>M15 close, after the relevant H1 bar is closed</td></tr>
3712<tr><td>Marker rule</td><td>Arrow may print only on the candle that closes after confirmation</td></tr>
3713<tr><td>Invalidation</td><td>No marker if either closed-bar condition fails</td></tr>
3714<tr><td>Alert policy</td><td>Provisional alerts labeled as such; confirmed alert once only</td></tr>
3715</tbody>
3716</table>
3717
3718<p>The contract should also state the expected behavior when the higher timeframe is selected automatically. Some indicators choose the next higher period from the chart. On M15, that might mean H1. On M30, it might mean H4. The tester should not assume the mapping. Check the input label, documentation, and observed result. A confusing mapping can create a false impression that a signal failed when the tool was actually using a different chart period.</p>
3719
3720<p>Define tolerances in advance. A line value may differ by a tiny amount because of displayed precision, but a trend state should not flip merely because a rounded label is one point different. Define whether equality counts as above, below, or neutral. Define the timezone used for sessions. Small omissions become large disputes when a signal sits near a threshold.</p>
3721
3722<h2 id="closed-bar-protocol">The Closed-Bar Validation Protocol</h2>
3723
3724<p>The most useful test happens while the market is moving, preferably on a demo or observation-only chart. Historical images are supporting evidence, not the primary proof. Start the protocol before the higher-timeframe candle opens and continue until after it closes.</p>
3725
3726<ol>
3727<li><strong>Mark the higher candle opening time.</strong> For an H1 filter, write down the new H1 candle time. Identify the four M15 candles inside it.</li>
3728<li><strong>Capture the initial state.</strong> Note the prior completed H1 value, the current H1 value, and any lower-chart markers. Save a screenshot or screen recording frame with terminal time visible.</li>
3729<li><strong>Observe each lower close.</strong> At each M15 close, record whether the lower condition is true and whether the indicator prints, removes, or moves a marker.</li>
3730<li><strong>Separate live and confirmed states.</strong> If the tool uses current H1 data, label its reading provisional. Do not count it as a confirmed signal before H1 closes.</li>
3731<li><strong>Check the H1 close.</strong> At closure, compare the completed H1 candle and the indicator output. Determine which M15 candle, if any, receives the confirmed marker.</li>
3732<li><strong>Wait one more lower bar.</strong> This exposes delayed buffers and post-close revisions that a single screenshot can miss.</li>
3733<li><strong>Refresh without changing inputs.</strong> Remove and reattach the indicator or restart the terminal in a saved test copy. Compare the prior closed-bar record with the new chart.</li>
3734</ol>
3735
3736<p>Repeat this protocol across several different market conditions: quiet range, directional movement, a threshold crossing, and a period with wider spreads or sparse ticks if available. The aim is variety, not a cherry-picked sample. A tool that is stable only when price drifts smoothly may require a more cautious description than one whose timing remains clear through ordinary changes in price.</p>
3737
3738<h3>A compact observation log</h3>
3739
3740<table>
3741<thead><tr><th>
3741Server time</th><th>M15 condition</th><th>H1 state</th><th>Displayed result</th><th>Status</th></tr></thead>
3742<tbody>
3743<tr><td>10:15 close</td><td>True</td><td>Current H1 bullish</td><td>Up arrow</td><td>Provisional</td></tr>
3744<tr><td>10:30 close</td><td>True</td><td>Current H1 changed bearish</td><td>Arrow removed</td><td>Expected only if labeled live</td></tr>
3745<tr><td>11:00 close</td><td>True</td><td>10:00 H1 closed bearish</td><td>No confirmed arrow</td><td>Consistent</td></tr>
3746<tr><td>11:15 close</td><td>True</td><td>New H1 forming</td><td>Up arrow</td><td>Record as provisional</td></tr>
3747</tbody>
3748</table>
3749
3750<p>This log is deliberately plain. It gives a reviewer enough information to reconstruct the sequence without guessing from a final chart. If a vendor calls a signal “non-repainting,” ask which row in the log they mean. A claim may be valid for closed higher bars and invalid for intrabar arrows. Precision is better than a blanket label.</p>
3751
3752<h2 id="history-and-refresh">History, Refreshes, and Backtest Illusions</h2>
3753
3754<p>Multi-timeframe indicators can look strongest after MT4 has processed a complete history. In that state, every higher candle is closed and the program can map final higher values backward across lower bars. That is useful for studying the strategy concept, but it does not prove live availability. The test must distinguish a finished historical plot from the sequence a user would have seen candle by candle.</p>
3755
3756<p>Three checks are especially important. First, compare a screenshot made live with a screenshot after a terminal restart. Second, temporarily switch away from the chart period and back, then compare settled signals. Third, add a newly opened chart with the same settings and see whether its history matches the preserved baseline. Any difference should be described, not hidden. It may result from delayed history, indicator initialization, or an algorithm that fills buffers after the fact.</p>
3757
3758<p>Do not equate every changed historical pixel with misconduct. MT4 can download missing bars, brokers can correct prices, and custom indicators may need a full recalculation after an input change. The relevant question is whether the tool makes its conditions and timing understandable. A tool that requires completed data should say so. A tool that changes old signals after ordinary refreshes deserves a cautious finding until the cause is explained.</p>
3759
3760<p>A visual strategy tester can add another trap. Some indicator behavior is tick-sensitive, while a simplified model may generate only a limited sequence inside a bar. If testing an EA that consumes the indicator, record the modelling method, data source, spread assumptions, date range, and the exact indicator build. The site article about <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating a recovered MQL4 expert advisor before live deployment</a> offers a broader comparison framework for controlled testing. Indicator timing should be one documented input to that larger validation plan.</p>
3761
3762<h2 id="example">Worked Example: H1 Trend Filter on M15</h2>
3763
3764<p>Assume an indicator is attached to EURUSD M15. It draws a blue arrow when the M15 close is above a 20-period exponential moving average and the H1 close is above a 50-period exponential moving average. The advertised description says, “trade with the H1 trend.” The tester needs to establish whether “H1 close” means the live H1 candle or the preceding closed H1 candle.</p>
3765
3766<p>At 09:00, a new H1 candle begins. The 08:00 candle is closed and sits above its 50-period average. At 09:15, M15 closes above its fast average, and a blue arrow appears. That arrow is potentially defensible as a confirmed multi-timeframe signal only if the code uses the completed 08:00 H1 candle. If it instead reads the 09:00 H1 candle, the arrow is conditional. The current H1 price could fall below its average before 10:00.</p>
3767
3768<p>At 09:45, price falls and the live 09:00 H1 close moves below the average. If the 09:15 arrow disappears, the tool is using a forming higher candle or otherwise recalculating from current data. That is not automatically a defect. The tester should record, “Live H1 filter, arrows provisional until H1 close.” If the product presentation showed those 09:15 arrows as settled historical entries without that explanation, the presentation is incomplete.</p>
3769
3770<p>Now take the closed-bar design. The indicator explicitly uses H1 shift 1, meaning the last completed H1 candle. All M15 checks from 09:00 to 09:59 use the finalized 08:00 H1 trend. The blue arrow at 09:15 may remain stable despite the developing 09:00 candle. At 10:00, the newly closed 09:00 H1 value becomes the filter for future M15 decisions. This has a one-hour lag relative to a live filter, but its timing is clear and testable.</p>
3771
3772<p>Neither design is inherently superior for every method. The first is faster but provisional. The second is slower but confirmed. A reviewer should report which is present and avoid praising the historical appearance of one as though it had the live certainty of the other.</p>
3773
3774<h2 id="diagnose-differences">How to Diagnose a Mismatch</h2>
3775
3776<p>When the indicator and reference charts disagree, change one variable at a time. Randomly changing periods, brokers, and timeframes together destroys the evidence trail. Start with the simplest explanations, then progress to implementation details.</p>
3777
3778<table>
3779<thead><tr><th>
3779Observed mismatch</th><th>Likely causes</th><th>Next diagnostic step</th></tr></thead>
3780<tbody>
3781<tr><td>Different signal time on M15</td><td>Higher-bar shift, late plotting, server-time boundary</td><td>Compare the H1 candle timestamp and marker creation time.</td></tr>
3782<tr><td>Line differs after restart</td><td>Missing history, current-bar use, recalculation order</td><td>Save before and after data-window values; verify loaded bars.</td></tr>
3783<tr><td>Signals differ by broker</td><td>Feed prices, suffix, candle construction, session rules</td><td>Run the same template on both feeds and label the difference.</td></tr>
3784<tr><td>Only first chart instance is correct</td><td>Shared globals, symbol cache, weak initialization</td><td>Open a clean profile and attach one instance per chart.</td></tr>
3785<tr><td>Old arrows appear after loading history</td><td>Historical backfill or insufficient initial bars</td><td>Compare live captures with the final historical layout.</td></tr>
3786</tbody>
3787</table>
3788
3789<p>Inspect the Data Window before relying on colors. A buffer can hold an empty value, a price level, or a marker coordinate that is visually offset for readability. Arrows drawn below a candle do not necessarily mean the condition was met at that lower price. The timestamp and buffer index are more informative than artistic placement.</p>
3790
3791<p>If the mismatch concerns an authorized, owned, or commissioned indicator and documentation is inadequate, source-level review may clarify the question. In MQL4, the key facts often include the timeframe argument passed to iMA or iCustom, the shift used for the target bar, the way iBarShift maps a lower-bar time to a higher chart, and whether buffers are cleared before recalculation. Recovered code can still require careful interpretation. The site explanation of <a href="/">decompile ex4 to mq4</a> options emphasizes that source recovery is a technical process with ownership and validation considerations, not a shortcut to copy another creator’s work.</p>
3792
3793<h2 id="decision-checklist">Release Checklist and Decision Rules</h2>
3794
3795<p>Use this checklist before treating a multi-timeframe display as a candidate for demo use. A “no” does not always mean the indicator is useless. It means the limitation should be disclosed and the use case narrowed.</p>
3796
3797<ul>
3798<li>The symbol, broker server, terminal build, and all timeframe inputs are recorded.</li>
3799<li>Each referenced chart has sufficient history for the longest lookback.</li>
3800<li>The tester knows whether the higher timeframe reads bar 0, bar 1, or a configurable shift.</li>
3801<li>Every observed live signal is labeled provisional or confirmed at the time it appears.</li>
3802<li>At least several full higher-timeframe cycles were observed, not merely a completed historical chart.</li>
3803<li>Refresh, reattachment, and restart comparisons were saved.</li>
3804<li>Any changed historical output has a documented explanation or remains an unresolved finding.</li>
3805<li>Alert timing and chart-marker timing agree with the signal contract.</li>
3806<li>A second person could reproduce the setup from the saved template, inputs, and log.</li>
3807<li>No result is described as a guarantee of trading performance.</li>
3808</ul>
3809
3810<p>A practical decision tree follows. If the tool uses only closed higher bars and results remain stable after refresh, it may be suitable for continued demo observation. If it uses live higher-bar data but visibly labels that state as provisional, it may still be useful for an alerting workflow that accepts uncertainty. If it revises old closed-bar signals without explanation, pauses or historical backfilling, then the evidence does not support calling its markers confirmed. If essential documentation is missing, the correct decision can be “not yet validated,” rather than forcing a positive or negative conclusion.</p>
3811
3812<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
3813  <h3 style="margin-top:0;">Need an Authorized MT4 Code Recovery Option?</h3>
3814  <p>For users who own an EX4 or have written permission to inspect it, ForexMQ5 is reviewed as a professional source-recovery option. Any recovered output should still be checked against a controlled multi-timeframe validation plan.</p>
3815  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
3816</div>
3817
3818<h2 id="reviewing-code">When Source Review Adds Clarity</h2>
3819
3820<p>Live observation is the first choice because it tests the behavior actually delivered to the terminal. Source review can complement it when the requester has clear rights to the code and needs to understand an ambiguous result. It may reveal that an indicator deliberately references the previous completed higher candle, that it reads current values for early warning, or that its indexing has an off-by-one error. The source alone is not final proof, because platform data, initialization, and alert logic still affect runtime behavior.</p>
3821
3822<p>For an owned indicator, a reviewer can ask focused questions: Does the calculation guard against missing bars? Does it use time-based mapping rather than assuming a fixed number of lower bars? Are old buffer values cleared on recalculation? Are alerts restricted to a new bar, or can ticks trigger repeated notices? Are labels explicit about confirmation? These are maintainability questions as much as trading questions.</p>
3823
3824<p>ForexMQ5 is presented on this review site as a professional option for authorized EX4 to MQ4 recovery needs, not as the operator of this publication or as a provider of trading advice. A recovery result should be treated as a starting point for authorized technical review and controlled testing. It should not be used to bypass licensing restrictions, redistribute another party’s strategy, or make assumptions about future market outcomes.</p>
3825
3826<h2 id="conclusion">Conclusion: Trust the Timestamp, Not the Screenshot</h2>
3827
3828<p>Multi-timeframe MT4 indicators deserve a time-aware validation process. The central question is simple: what information was final when the signal was presented? Answer it by synchronizing the relevant charts, writing a signal contract, observing full higher-timeframe cycles, and preserving before-and-after evidence around refreshes. A final historical chart can illustrate a method, but it cannot replace a record of what occurred while candles were open.</p>
3829
3830<p>When a tool uses current higher-timeframe data, call its output provisional. When it uses completed higher bars and remains stable, call it confirmed within the documented rules. When closed history changes without a clear data explanation, withhold confidence until the behavior is understood. This approach does not promise returns. It gives traders and developers a clearer basis for deciding whether an indicator’s signals are transparent enough to study further.</p>
3831`},{slug:"mt4-ea-dependency-inventory-checklist",title:"Build an MT4 EA Dependency Inventory Before Recovery or Migration",metaTitle:"MT4 EA Dependency Inventory Checklist Before Recovery or Migration",metaDescription:"Create a practical dependency inventory for an MT4 Expert Advisor before source recovery or MT5 migration, covering files, indicators, libraries, DLLs, settings, and test evidence.",keywords:"MT4 EA dependency inventory, MT4 Expert Advisor migration checklist, EX4 recovery preparation, MQL4 dependencies, MT4 DLL audit, EA files and indicators",excerpt:"Before recovering source code or moving an MT4 Expert Advisor, map every file, indicator, library, DLL, setting, and operating assumption that lets the robot work. This checklist turns a fragile folder into an evidence-based handover package.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:Iu,imageAlt:"organized dependency inventory showing MT4 Expert Advisor files, indicators, libraries, DLLs, and settings",tableOfContents:[{id:"why-inventory-comes-first",title:"Why the Inventory Comes Before Recovery or Migration"},{id:"define-boundary",title:"Define the EA System Boundary"},{id:"capture-evidence",title:"Capture Evidence Without Changing the Installation"},{id:"file-map",title:"Build the File and Folder Map"},{id:"runtime-dependencies",title:"Identify Runtime Dependencies"},{id:"settings-and-state",title:"Record Settings, State, and Operating Assumptions"},{id:"relationship-map",title:"Turn the List Into a Relationship Map"},{id:"recovery-package",title:"Prepare a Recovery Package"},{id:"migration-package",title:"Prepare a Migration Package"},{id:"test-and-handover",title:"Test, Reconcile, and Hand Over"},{id:"decision-guide",title:"Decision Guide for Missing Dependencies"},{id:"conclusion",title:"Conclusion: Preserve the Working Context"}],content:`
3832<p>An MT4 Expert Advisor rarely lives in one file. The visible EX4 on a chart may depend on custom indicators, include files, compiled libraries, Windows DLLs, preset inputs, symbol conventions, terminal permissions, and data held outside the program folder. When source has been lost or a move to another machine or platform is planned, copying the EA alone can produce a misleading result: the file appears present, yet the system behaves differently or does not start at all.</p>
3833
3834<p>A dependency inventory is an organized map of those connections. It records what exists, where it sits, how it is loaded, why it matters, and what evidence confirms it. This work is useful before authorised source recovery, before an MT4 to MT5 conversion, and before a VPS move. It does not recover code by itself. Instead, it prevents a technical team from guessing which companion files, permissions, or inputs were part of the original working arrangement.</p>
3835
3836<p>The independent review perspective is simple. A documented inventory makes a legitimate project easier to scope and easier to validate. It also helps the owner distinguish a missing source-code problem from a missing-environment problem. Readers considering an <a href="/">mt4 ea decompiler</a> should treat the inventory as preparation, not as proof that recovery will recreate every external 
3836component.</p>
3837
3838<img src="${Iu}" alt="organized map of MT4 Expert Advisor dependencies including files, indicators, libraries, DLLs, and settings" style="width:100%;border-radius:8px;margin:24px 0;" />
3839
3840<h2 id="why-inventory-comes-first">Why the Inventory Comes Before Recovery or Migration</h2>
3841
3842<p>Recovery and migration ask different technical questions, but both need the same starting facts. Recovery asks what can be reconstructed from an authorised compiled file and its surrounding evidence. Migration asks what must be redesigned, replaced, or retested in a different platform environment. In either case, an isolated EX4 is only one artifact in a wider system.</p>
3843
3844<p>Consider an EA that calls a custom indicator through <code>iCustom()</code>. Its trade rules may be intact in the EA, while the indicator calculates the signal that triggers every order. If the indicator file is absent, a recovered EA can compile and still produce no meaningful behavior. Another EA may read a CSV calendar from the terminal files folder, or call a DLL for licensing, machine data, or a proprietary calculation. A migration developer needs to know that these pieces exist before estimating effort or promising a comparable result.</p>
3845
3846<p>An inventory also avoids accidental changes to the last known working installation. A hurried cleanup can overwrite a preset, update an indicator, remove a DLL, or open MT4 with different permissions. Once that happens, it becomes difficult to tell whether a later failure belongs to the EA, the new process, or the changed environment. The first rule is therefore observational: document first, copy second, alter last.</p>
3847
3848<table>
3849<thead><tr><th>Question</th><th>Why it matters</th><th>Useful evidence</th></tr></thead>
3850<tbody>
3851<tr><td>What launches on the chart?</td><td>Identifies the primary EA and its version.</td><td>Chart screenshot, file path, file hash.</td></tr>
3852<tr><td>What does it load or call?</td><td>Reveals indicators, libraries, DLLs, and data files.</td><td>Journal entries, source if available, folder listing.</td></tr>
3853<tr><td>What configuration changes behavior?</td><td>Separates code behavior from chosen inputs.</td><td>SET files, input screenshots, comments.</td></tr>
3854<tr><td>What does the terminal provide?</td><td>Exposes broker, symbol, history, and permission assumptions.</td><td>Terminal build, account type, symbol specifications.</td></tr>
3855<tr><td>What must be reproduced?</td><td>Defines a realistic recovery or migration acceptance test.</td><td>Named test cases and dated results.</td></tr>
3856</tbody>
3857</table>
3858
3859<p>Do not interpret an inventory as a licence to inspect software that the requester has no right to examine. Ownership, licence terms, and the purpose of the work still matter. Where the project concerns a purchased or commissioned robot, preserve the agreement and use a narrow documented purpose. The site’s guide to <a href="/blog/legal-rules-for-ex4-source-code-recovery">legal rules for EX4 source recovery</a> provides a useful rights-first framework before files are shared with anyone.</p>
3860
3861<h2 id="define-boundary">Define the EA System Boundary</h2>
3862
3863<p>Start by naming the system, its owner or authorised custodian, and the precise question the inventory must answer. “Everything on the laptop” is too broad. “The live EURUSD chart setup running AlphaEA.ex4 on terminal A at the time of capture” is a workable boundary. A clear boundary protects privacy, reduces irrelevant material, and lets another person understand what was included and what was deliberately excluded.</p>
3864
3865<p>Record three layers. The first is the <strong>core</strong>: the EA file attached to the chart and any source, preset, or documentation that directly identifies it. The second is the <strong>runtime layer</strong>: indicators, libraries, DLLs, files, templates, and terminal permissions used while it runs. The third is the <strong>environment layer</strong>: broker symbols, account type, terminal build, time zone, available history, VPS or local machine characteristics, and network-dependent services. Not every item will matter, but each should be considered rather than assumed away.</p>
3866
3867<h3>Write a one-paragraph scope statement</h3>
3868
3869<p>A practical statement names the artifact, the desired outcome, and the allowed activities. For example: “This inventory documents the authorised installation of AlphaEA.ex4 and the companion files needed to reproduce its observed behaviour in a controlled test environment. It is being prepared to support source recovery assessment and a possible MT5 migration. No licence restriction is to be bypassed and no output is intended for redistribution.” A statement like this is more useful than a generic folder archive because it c
3869ommunicates intent and limits.</p>
3870
3871<h3>Identify people and decisions</h3>
3872
3873<p>List the person who supplied the files, the person who can confirm the trading setup, the person who owns approval rights, and the person who will test results. In small projects, one individual may hold all four roles. In a business, separating them prevents a migration developer from making assumptions that only a trader or compliance contact can answer. Record contact details securely, not inside a package that may circulate widely.</p>
3874
3875<h2 id="capture-evidence">Capture Evidence Without Changing the Installation</h2>
3876
3877<p>Use a capture sheet and work from copies whenever possible. Note the date and time, the Windows user profile, the MT4 data-folder location, and whether the terminal is running. MetaTrader installations can store the executable in one location and data in another, so a shortcut on the desktop is not enough. In MT4, the data-folder command exposes the folders that generally matter for MQL4 programs and files.</p>
3878
3879<p>Take screenshots of the chart with the EA attached, the Inputs tab, the Common tab, and the Experts and Journal tabs around a normal initialization. Screenshots do not replace files, but they preserve the connections that a raw folder listing cannot show. If logs contain account numbers, server names, licence tokens, or personal information, restrict access to the originals and prepare a redacted working copy where appropriate.</p>
3880
3881<p>Create cryptographic hashes for original binaries and important data files when the project warrants it. A hash is a fingerprint that helps establish whether a file later changed. Record the algorithm used and the exact file name. A hash does not explain what a file does, but it supports chain-of-custody discipline. Avoid editing an EX4 merely to rename it or test it in place before preserving the original.</p>
3882
3883<ul>
3884<li>Capture the terminal build number and the full data-folder path.</li>
3885<li>Record the chart symbol, timeframe, account server, and whether the account is demo or live.</li>
3886<li>Export or copy the exact preset file if one is used.</li>
3887<li>Save relevant Journal and Experts messages from a normal startup.</li>
3888<li>Note the date range and source of historical data used for any known backtest.</li>
3889<li>Mark unknown items as unknown rather than filling gaps with a guess.</li>
3890</ul>
3891
3892<h2 id="file-map">Build the File and Folder Map</h2>
3893
3894<p>The file map is the backbone of the inventory. It should be a structured table, not a pile of screenshots. Start with the MQL4 directory and list only files plausibly connected to the scoped EA. Include full relative path, extension, size, modified date, hash when captured, status, and a short purpose statement. Keep the untouched evidence copy separate from a working copy used for analysis.</p>
3895
3896<table>
3897<thead><tr><th>Category</th><th>Typical location</th><th>What to record</th><th>Common mistake</th></tr></thead>
3898<tbody>
3899<tr><td>Expert Advisor</td><td>MQL4/Experts</td><td>EX4, MQ4 if present, variants, file hash, chart name.</td><td>Assuming the newest filename is the live version.</td></tr>
3900<tr><td>Custom indicator</td><td>MQL4/Indicators</td><td>EX4 or MQ4, subfolder path, inputs, buffers if known.</td><td>Missing an indicator in a nested folder.</td></tr>
3901<tr><td>Include file</td><td>MQL4/Include</td><td>MQH files and their parent library or vendor folder.</td><td>Ignoring includes because they are not loaded at runtime.</td></tr>
3902<tr><td>Compiled library</td><td>MQL4/Libraries</td><td>EX4 library name, calling EA, version, permissions.</td><td>Confusing a library with a standalone EA.</td></tr>
3903<tr><td>DLL</td><td>MQL4/Libraries or vendor path</td><td>DLL name, architecture, observed purpose, consent required.</td><td>Copying an unknown DLL without security review.</td></tr>
3904<tr><td>Data file</td><td>MQL4/Files or Common/Files</td><td>CSV, TXT, database, licence, configuration, update behavior.</td><td>Missing files stored in the shared common folder.</td></tr>
3905<tr><td>Template and preset</td><td>templates and MQL4/Presets</td><td>Chart template, SET file, attachment context.</td><td>Treating inputs as unimportant after recovery.</td></tr>
3906</tbody>
3907</table>
3908
3909<p>Extensions provide clues, not certainty. An MQ4 is source for an EA, indicator, script, or library. An EX4 is compiled MQL4 program code. An MQH normally supplies included 
3909source definitions and functions. A DLL is native code loaded through Windows, and it deserves special handling because it sits outside the normal MQL4 compiler model. A CSV may be an innocuous report or a critical session schedule. Read the evidence and observe behaviour before assigning importance.</p>
3910
3911<p>Use a status field with values such as present, referenced, confirmed active, optional, missing, replaced, or unknown. “Present” means it exists in the captured package. “Confirmed active” means there is evidence it loaded or affected the scoped setup. This distinction makes the map honest. A folder can contain old experiments that share a vendor name but have no relationship to the chart in question.</p>
3912
3913<h2 id="runtime-dependencies">Identify Runtime Dependencies</h2>
3914
3915<p>Runtime dependencies are the pieces the EA needs after it is attached to a chart. Custom indicators are especially easy to overlook. Their filenames may be constructed from input values or called from an iCustom reference rather than displayed on the chart. A missing indicator can lead to initialization errors, empty values, or silently altered signals. Capture its exact relative path because a file in <code>Indicators/Vendor/Signal.ex4</code> is not always equivalent to one placed directly in the Indicators folder.</p>
3916
3917<p>Libraries deserve a separate record. An MQL4 library may centralize order logic, encryption, calculations, or vendor functions. Its presence in the Libraries folder does not prove use, but initialization logs, documentation, or authorised source can confirm the link. If only compiled files exist, do not claim certainty about an internal call that has not been observed. State the basis: “co-located with EA” is weaker than “startup log identifies library load.”</p>
3918
3919<p>DLLs create both migration and security questions. MT4 may require the user to allow DLL imports in the EA settings, and a DLL might depend on a particular Windows architecture, runtime, file location, network endpoint, or registration state. Record whether the option was enabled, the filename, file version properties where available, and the visible consequence when it is disabled. Do not execute an unfamiliar DLL simply to complete an inventory. If provenance is uncertain, seek qualified security review in an isolated environment.</p>
3920
3921<h3>External and indirect dependencies</h3>
3922
3923<p>Some dependencies are not executable files. The EA may expect an HTTP endpoint, an email setting, a named global variable, a terminal global variable, a licence server, a news calendar, or a manually maintained file. Record the connection without publishing credentials or secret URLs. If an item contains a key or token, note that it exists and store the value only in an approved secret-management location. A migration package should never casually embed working credentials in notes or screenshots.</p>
3924
3925<p>For a focused explanation of how compiled and source artifacts relate, see the existing article on <a href="/blog/mql4-to-ex4-compilation-explained">how MQL4 becomes an EX4 file</a>. That background helps a project team avoid the common error of treating every item in the MQL4 folder as recoverable source code.</p>
3926
3927<h2 id="settings-and-state">Record Settings, State, and Operating Assumptions</h2>
3928
3929<p>A file inventory without settings is incomplete. Inputs can alter risk limits, hours, symbols, indicator periods, trade direction, magic numbers, order comments, and whether a feature is active. Capture values in a table as well as a SET export or screenshot. Explain the source of each value: current chart input, documented standard setting, or unknown historical setting. A default value visible today may not be the value used during the reference period.</p>
3930
3931<p>Also record the EA Common settings. Does it allow live trading? Does it permit DLL imports? Does it require WebRequest permissions? Is long-only or short-only behaviour selected by an input? Does the terminal itself permit automated trading? These controls can look like a code defect when moved to a fresh installation, even though the program is unchanged.</p>
3932
3933<table>
3934<thead><tr><th>
3934Setting group</th><th>Example to capture</th><th>Migration or recovery impact</th></tr></thead>
3935<tbody>
3936<tr><td>Trade identity</td><td>Magic number, comment prefix, chart symbol.</td><td>Prevents interference with other strategies and identifies historical orders.</td></tr>
3937<tr><td>Signal inputs</td><td>Indicator name, period, shift, threshold.</td><td>Connects behaviour to a particular indicator configuration.</td></tr>
3938<tr><td>Risk controls</td><td>Lot method, stop loss rule, daily limit.</td><td>Requires careful review, not blind copying into a new system.</td></tr>
3939<tr><td>Time rules</td><td>Trading hours, GMT offset, session filter.</td><td>May change when broker server time differs.</td></tr>
3940<tr><td>Access controls</td><td>DLL permission, WebRequest list, auto-trading status.</td><td>Can block startup or external communication.</td></tr>
3941<tr><td>Persistent state</td><td>Global variables, files, open-order assumptions.</td><td>Explains behaviour that is not encoded in a fresh install.</td></tr>
3942</tbody>
3943</table>
3944
3945<p>State needs special care. An EA may resume based on existing orders, a file counter, terminal global variables, or historical positions. Copying that state into a test environment can be useful, but copying it into a live environment can cause unintended actions. Inventory state separately and label whether it is safe to reproduce, safe only for analysis, or prohibited from transfer until reviewed.</p>
3946
3947<h2 id="relationship-map">Turn the List Into a Relationship Map</h2>
3948
3949<p>A spreadsheet list is necessary, but a relationship map makes it understandable. Put the primary EA in the center. Draw arrows to each indicator, library, DLL, data file, and external service. Label arrows with the type of connection: loads, reads, writes, calls, depends on permission, or assumes. Add the evidence source next to each relationship. This visual step often reveals that an apparently small migration is actually a group of independent workstreams.</p>
3950
3951<p>For example, an EA may load a trend indicator, read a CSV blacklist, call a licensing DLL, and rely on broker-specific symbol suffixes. The map shows four distinct risks: signal parity, data maintenance, vendor access, and symbol translation. The appropriate response is not to declare the EA broken. It is to assign an owner and a verification action to every connection.</p>
3952
3953<h3>Use a dependency priority score</h3>
3954
3955<p>A simple qualitative score helps sequence work. Rate each item by operational criticality and replaceability. A custom indicator that determines entries is high criticality and may be hard to replace. A decorative chart template is low criticality and easy to replace. A DLL that controls authorization can be high criticality but may require a vendor conversation rather than technical substitution. Do not turn these labels into false precision. Their purpose is to expose where an unknown could block the project.</p>
3956
3957<ol>
3958<li><strong>Critical:</strong> The EA cannot initialize or cannot produce its intended signals without it.</li>
3959<li><strong>Material:</strong> The EA can run, but orders, filters, reporting, or controls differ without it.</li>
3960<li><strong>Contextual:</strong> It supports repeatable testing or operations but is not required to start.</li>
3961<li><strong>Incidental:</strong> It is co-located but has no demonstrated relationship to the scoped setup.</li>
3962</ol>
3963
3964<h2 id="recovery-package">Prepare a Recovery Package</h2>
3965
3966<p>When a rights-holder is exploring source recovery, the package should help a provider assess the job without oversharing. Include the original EX4, a file manifest, the scope statement, proof of authority where appropriate, companion files that are authorised to share, screenshots of relevant inputs, and a description of the intended maintenance objective. State which parts are known to be missing. A candid gap list is more valuable than a polished but incomplete archive.</p>
3967
3968<p>Do not assume recovered output will automatically include separate indicators, MQH files, DLL code, web services, or configuration data. Separate compiled artifacts remain separate artifacts. The desired deliverable should specify whether the owner needs an assessment only, a readable starting point for the main EA, an inventory of unresolved calls, or a broader reconstruction plan. This makes expectations testable.</p>
3969
3970<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
3971  <h3 style="margin-top:0;">Organize the Evidence Before Requesting Help</h3>
3972  <p>ForexMQ5 is reviewed as a professional option for authorised EX4 recovery projects. A clear inventory, rights record, and narrow maintenance scope can help the requester describe the work responsibly.</p>
3973  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
3974</div>
3975
3976<p>Third-party recovery does not remove the requester’s responsibility for permission or later use. The service at ForexMQ5 should be viewed as a technical option, not as legal advice or a route around licence controls. A responsible request identifies authorised ownership or permission and excludes cloning, unlocking, and redistribution objectives.</p>
3977
3978<h2 id="migration-package">Prepare a Migration Package</h2>
3979
3980<p>An MT4 to MT5 migration is not a file-copy exercise. MQL4 and MQL5 have different program models, trade interfaces, indicator handling, and testing workflows. The inventory lets the project team classify each dependency as portable, adaptable, replaceable, vendor-controlled, or unknown. An EX4 cannot simply become an EX5 by changing an extension, and a DLL may need a compatible replacement or may not be appropriate to carry forward at all.</p>
3981
3982<p>For each critical dependency, create a migration card with five fields: current function, evidence of use, target-platform approach, owner, and acceptance test. A custom indicator could be ported from authorised source, rebuilt from documented logic, or retained as an unresolved blocker. A CSV feed might move to an MT5 files location or a managed service. A broker suffix rule may become a symbol lookup routine. The inventory supports informed choices instead of silent omissions.</p>
3983
3984<p>Separate requirements from implementation. “Do not trade during the listed events” is a requirement. “Read blacklist.csv from MQL4/Files” is one MT4 implementation. A sound migration preserves the required behavior after confirming it with the system owner, while allowing a different technical design. This distinction is crucial when source is incomplete or an external component cannot legally or technically be transferred.</p>
3985
3986<h2 id="test-and-handover">Test, Reconcile, and Hand Over</h2>
3987
3988<p>The final inventory should support verification, not merely archival. Build a small test matrix using a controlled account or test environment. Each row should name the setup, inputs, required dependencies, expected observable event, actual result, and reviewer. Examples include initialization with DLL permission enabled and disabled, indicator load confirmation, expected behavior on a broker symbol suffix, or recognition of a known CSV entry. Avoid treating a single profitable backtest as proof that migration succeeded.</p>
3989
3990<p>Reconcile every critical dependency. If an item was present but unused, say so. If it was missing and replaced, document the replacement and its limits. If behavior cannot be confirmed because the original server or vendor service is unavailable, mark it unresolved. Honest uncertainty is safer than declaring parity from superficial chart output.</p>
3991
3992<h3>Handover checklist</h3>
3993
3994<ul>
3995<li>Deliver the file manifest and relationship map in a readable format.</li>
3996<li>Keep original evidence, working copies, and generated output clearly separated.</li>
3997<li>Attach the input table, preset files, and redacted screenshots needed to reproduce tests.</li>
3998<li>List every critical dependency with its current status and accountable owner.</li>
3999<li>Document permissions, external endpoints, and secrets by reference, not in public notes.</li>
4000<li>Include failed tests and open questions, not just successful results.</li>
4001<li>State what has not been tested on a live account.</li>
4002</ul>
4003
4004<p>The inventory is also valuable after handover. When an EA later stops working on a VPS or after a broker change, the team can compare the current environment against the recorded map rather than starting from zero. Readers troubleshooting such a break can also use the site’s <a href="/">ea decompiler software</a> resources as part of a broader recovery assessment, while remembering that a tool alone does not restore a missing dependency.</p>
4005
4006<h2 id="decision-guide">Decision Guide for Missing Dependencies</h2>
4007
4008<p>Missing items should lead to a decision, not panic. First ask whether the item is actually referenced by the scoped EA. Next ask whether it is critical to initialization, signals, order management, reporting, or only presentation. Then determine whether authorised source, vendor support, documentation, or observed behavior can clarify the function. The answer may be recovery, replacement, redesign, or a decision to stop the project.</p>
4009
4010<table>
4011<thead><tr><th>
4011Finding</th><th>Practical next step</th><th>Do not assume</th></tr></thead>
4012<tbody>
4013<tr><td>Missing custom indicator</td><td>Locate authorised copy or document its observable signal role before rebuilding.</td><td>That the EA entry logic is self-contained.</td></tr>
4014<tr><td>Unknown DLL</td><td>Preserve it, record permissions, and obtain provenance or security review.</td><td>That it is safe to execute or portable to MT5.</td></tr>
4015<tr><td>Absent SET file</td><td>Use chart screenshots and stakeholder records to reconstruct a provisional input table.</td><td>That current defaults match historical settings.</td></tr>
4016<tr><td>Broker symbol mismatch</td><td>Map the intended instrument and contract specifications, then test deliberately.</td><td>That EURUSD means the same thing on every server.</td></tr>
4017<tr><td>External service unavailable</td><td>Document the dependency and define a permitted fallback requirement.</td><td>That code recovery can recreate a remote service.</td></tr>
4018<tr><td>Unclear rights</td><td>Pause sharing and seek written permission or appropriate advice.</td><td>That possession of the EX4 grants source rights.</td></tr>
4019</tbody>
4020</table>
4021
4022<p>This discipline also improves cost conversations. A request described as “convert one EA” may really include an indicator rewrite, a data-feed redesign, DLL replacement, symbol adaptation, and testing across several account types. A dependency inventory does not make the work larger. It reveals the work already present, allowing the owner to choose a staged plan or defer a component with open risk.</p>
4023
4024<h2 id="conclusion">Conclusion: Preserve the Working Context</h2>
4025
4026<p>The most useful artifact before recovery or migration is not a single copied EX4. It is a clear account of the working context around it. By mapping the EA, indicators, libraries, DLLs, data files, presets, permissions, state, and environment assumptions, an owner creates a practical bridge between a fragile installation and a controlled technical project.</p>
4027
4028<p>Begin with authority and scope. Preserve evidence before changing anything. Map files with statuses, convert the list into relationships, capture inputs and runtime controls, and give every critical dependency a test or an open-question label. That process makes it easier to assess authorised recovery, plan an MT5 migration, transfer an EA to a VPS, or diagnose a later failure without inventing facts.</p>
4029
4030<p>Most importantly, retain uncertainty where it belongs. A missing file, undocumented DLL, or unknown external service may be a real limitation. Naming it early is a sign of competent preparation, not a failed inventory. With the surrounding system documented, the next technical decision can be narrower, safer, and easier to verify.</p>
4031`},{slug:"mql4-source-code-escrow-guide",title:"MQL4 Source Code Escrow: Protect a Custom Expert Advisor Investment",metaTitle:"MQL4 Source Code Escrow Guide for Custom Expert Advisors",metaDescription:"Learn how MQL4 source code escrow can protect a custom Expert Advisor investment with a secure vault, release rules, contract keys, and a practical continuity plan.",keywords:"MQL4 source code escrow, Expert Advisor source code vault, custom EA continuity plan, MQ4 escrow agreement, trading robot source code protection",excerpt:"A custom Expert Advisor can outlive its developer relationship. This practical guide explains how an MQL4 source code escrow arrangement, secure vault, release conditions, and continuity records can protect an authorised owner's ability to maintain a system.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:Ru,imageAlt:"secure digital vault protecting MQL4 Expert Advisor source code and continuity records",tableOfContents:[{id:"why-escrow-matters",title:"Why a Custom EA Needs a Continuity Plan"},{id:"escrow-basics",title:"What Source Code Escrow Actually Does"},{id:"contract-key",title:"The Contract Key: Rights Before Files"},{id:"vault-design",title:"Designing a Secure Digital Vault"},{id:"deposit-package",title:"What to Place in the Deposit Package"},{id:"release-triggers",title:"Setting Clear Release Conditions"},{id:"verification",title:"Verify That the Deposit Can Be Used"},{id:"continuity-shield",title:"Build a Continuity Shield Around the C
4031ode"},{id:"decision-process",title:"A Decision Process for EA Owners"},{id:"common-mistakes",title:"Common Escrow Mistakes to Avoid"},{id:"conclusion",title:"Protect Access Without Assuming the Worst"}],content:`
4032<p>A custom Expert Advisor can be an important operating asset even when it occupies only a small corner of an MT4 installation. It may encode entry rules, position handling, session filters, broker adjustments, reporting logic, and years of testing decisions. Yet many owners receive only an EX4 at delivery, or receive an MQ4 once and assume it will always remain available. A failed laptop, unavailable contractor, closed development business, disputed handover, or missing dependency can expose how fragile that assumption is.</p>
4033
4034<p>MQL4 source code escrow is one way to plan for that risk. In a well designed arrangement, a trusted holder keeps a defined package of source materials in a secure digital vault and releases it only if agreed conditions occur. The arrangement is not a replacement for backups, technical documentation, or a carefully written development agreement. It is a continuity tool that can reduce dependence on a single developer while respecting the developer's intellectual property and the owner's agreed rights.</p>
4035
4036<p>This guide takes an educational review-site approach. It does not provide escrow services or legal advice. Instead, it helps a buyer, developer, or small trading operation ask better questions before commissioning a custom EA. Readers who are comparing ways to understand compiled files can also start with this overview of an <a href="/">ex4 to mq4 decompiler</a>, but escrow is best arranged before source access becomes a problem.</p>
4037
4038<img src="${Ru}" alt="secure digital vault protecting MQL4 Expert Advisor source code and continuity records" style="width:100%;border-radius:8px;margin:24px 0;" />
4039
4040<h2 id="why-escrow-matters">Why a Custom EA Needs a Continuity Plan</h2>
4041
4042<p>An EA is not simply a strategy description. The working system often depends on source files, include files, custom indicators, preset files, platform assumptions, compiler version, and a sequence of decisions known only to the original developer. If a developer is responsive and the project is small, informal trust may seem adequate. The difficulty appears later, when an update is needed and nobody can identify the current source revision or the right to change it.</p>
4043
4044<p>Continuity planning is not an accusation that a developer will disappear or act unfairly. It is ordinary operational planning. Businesses plan for a lost device, an expired domain, a staff departure, and a supplier outage because each can interrupt work. A bespoke trading robot deserves the same attention, especially where it performs a recurring operational role. The plan should be proportionate to the value, complexity, and dependence created by the EA.</p>
4045
4046<p>Consider three different situations. A hobbyist commissions a simple alert EA and can accept a future rewrite. A fund operations team uses a custom execution helper with several indicators and a defined support contract. A partnership relies on a robot built by one outside programmer who holds every source copy. Escrow is more compelling in the latter cases because the cost of losing maintenance access can exceed the effort of documenting it early.</p>
4047
4048<p>It is useful to distinguish continuity from ownership. A client may have a contractual right to use an EA without owning the developer's reusable libraries. A developer may properly protect general purpose components while agreeing that the client can receive enough material to maintain the commissioned implementation if support permanently fails. A good arrangement makes this boundary visible rather than pretending all code is either fully shared or permanently inaccessible.</p>
4049
4050<h3>Questions that reveal dependence</h3>
4051
4052<ul>
4053<li>Could a qualified replacement developer compile and test the EA if the original developer became unreachable?</li>
4054<li>Does anyone besides the developer hold the current source revision and build instructions?</li>
4055<li>Are external indicators, libraries, configuration files, or hosted services necessary for normal operation?</li>
4056<li>Does the contract say who may modify the code, and under what circumstances?</li>
4057<li>Is there a documented process for a serious support failure, retirement, or business closure?</li>
4058</ul>
4059
4060<p>If several answers are no, the project has a single point of failure. An escrow design may help, but first the parties should identify what they are trying to preserve: the right to use a compiled EA, the ability to maintain custom logic, access to a working build environment, or evidence of what was delivered. Those are related objectives, not identical ones.</p>
4061
4062<h2 id="escrow-basics">What Source Code Escrow Actually Does</h2>
4063
4064<p>Source code escrow has three basic elements: a depositor, a beneficiary, and a neutral holder. The depositor is usually the developer or vendor that supplies the source package. The beneficiary is commonly the customer that needs continuity protection. The holder retains the package under agreed security and release procedures. In some arrangements, the holder is a specialised escrow provider. In smaller projects, the parties may appoint a professional custodian, subject to appropriate advice and security review.</p>
4065
4066<p>The holder does not decide who owns the code merely by storing it. Nor does escrow automatically grant broad rights to copy, sell, publish, or alter the material. Its central function is controlled custody. The agreement should say what is deposited, how deposits are updated, what conditions permit release, how a release request is handled, and what licence or assignment applies after release.</p>
4067
4068<table style="width:100%;border-collapse:collapse;margin:16px 0;">
4069<thead><tr style="background:#f0f4ff;"><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Element</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Practical purpose</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Question to settle</th></tr></thead>
4070<tbody>
4071<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Deposit</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Preserves a defined source and environment package.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Which revision and dependencies are included?</td></tr>
4072<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Custody</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Limits unauthorised access while the relationship works normally.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Who can access the vault and how is access recorded?</td></tr>
4073<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Release</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Provides an orderly path if a stated failure occurs.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">What proof starts the release process?</td></tr>
4074<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Post-release licence</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Defines what the beneficiary may do with released materials.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">May it maintain, appoint a contractor, or distribute changes?</td></tr>
4075</tbody>
4076</table>
4077
4078<p>Escrow is therefore not a magic recovery button. If the deposit contains an old MQ4, omits a private indicator, or cannot compile in the documented environment, the holder can release only an incomplete package. If the contract gives the beneficiary no maintenance licence after release, access alone may not solve the business problem. The strength of the arrangement comes from matching the legal terms, deposited materials, and verification process.</p>
4079
4080<h2 id="contract-key">The Contract Key: Rights Before Files</h2>
4081
4082<p>The contract is the key that tells everyone what the vault is for. Before selecting storage technology, the parties should determine the intellectual property position. Did the client commission fully bespoke code? Does the developer retain a framework used across clients? Is a third-party library included? Does the customer need ownership, a perpetual licence, or a limited maintenance right if a trigger happens? These questions should be addressed in a written agreement appropriate to the relevant jurisdiction.</p>
4083
4084<p>Payment by itself does not always transfer copyright or a right to modify software. Likewise, a developer's desire to protect reusable work does not prevent a practical continuity commitment. A balanced contract can identify excluded background materials, define the client-specific layer, and grant a narrow licence to use and maintain the deposited ver
4084sion after a valid release. If the project involves meaningful money, multiple countries, employees, or a dispute, the parties should obtain advice from qualified counsel rather than relying on a template or article.</p>
4085
4086<h3>Contract clauses worth discussing</h3>
4087
4088<ol>
4089<li><strong>Asset definition.</strong> Name the EA, repositories, branches, indicators, includes, set files, and documentation that form the deposit. Avoid phrases such as “all related files” without a schedule.</li>
4090<li><strong>Ownership and licence.</strong> State which rights are assigned, retained, or licensed. Specify whether a replacement contractor may receive access after release.</li>
4091<li><strong>Update duty.</strong> Set a reasonable event or schedule for new deposits, such as each accepted production release or a quarterly review.</li>
4092<li><strong>Release process.</strong> Define triggers, notice steps, evidence, a response period, and what happens if the depositor disputes the request.</li>
4093<li><strong>Security and confidentiality.</strong> Require controlled access, encryption, audit records, and obligations for anyone who handles the package.</li>
4094<li><strong>Termination and transition.</strong> Explain what happens if the support relationship ends normally, the customer stops paying, or the holder ceases operating.</li>
4095</ol>
4096
4097<p>Clarity protects both sides. It lets a developer show that source access is conditional, not casual. It lets a customer know that a genuine continuity failure has a defined response. It also reduces pressure to seek technical work on a compiled file when a properly authorised source package should have been available under the original bargain.</p>
4098
4099<h2 id="vault-design">Designing a Secure Digital Vault</h2>
4100
4101<p>A digital vault should protect confidentiality, integrity, and availability. Confidentiality means that a curious employee, unrelated contractor, or attacker cannot simply read the source. Integrity means that the package can be shown to be the version deposited, rather than an altered substitute. Availability means that authorised parties can still obtain it when a release condition has been properly satisfied.</p>
4102
4103<p>For many projects, an encrypted archive with a cryptographic checksum, stored by a reputable custodian and accompanied by a signed manifest, is a sensible starting point. The encryption key should not live beside the archive in plain text. Access should require more than a shared mailbox password. The exact implementation depends on the parties, but useful controls include separate credentials, multifactor authentication, an access log, documented recovery contacts, and a tested retention plan.</p>
4104
4105<p>Separation of duties is valuable. The person who uploads the code should not be the only person able to alter the vault record or approve release. A customer should not obtain silent access to the working repository merely because it is named as a beneficiary. The holder should record each deposit, checksum, and requested retrieval. These controls make the arrangement credible when memories and relationships have changed.</p>
4106
4107<h3>A practical vault checklist</h3>
4108
4109<ul>
4110<li>Create a manifest with filenames, paths, versions, dates, and checksums.</li>
4111<li>Encrypt the archive during transfer and at rest using an agreed process.</li>
4112<li>Store decryption and recovery instructions separately from the encrypted archive.</li>
4113<li>Record named contacts for the depositor, beneficiary, and holder, with a process to update them.</li>
4114<li>Limit vault access to named roles and preserve an audit trail.</li>
4115<li>Define retention periods, backup locations, and what happens if a storage provider changes service.</li>
4116<li>Never place trading account passwords, API secrets, or personal identity documents in a routine source archive unless a protected, justified process specifically requires them.</li>
4117</ul>
4118
4119<p>Encryption is not enough if nobody can interpret the package later. A vault that holds unreadable files, an unknown password process, and no environment notes can create false confidence. The practical question is not only “Can the archive be opened?” but also “Can an authorised maintainer understand what to do next?”</p>
4120
4121<h2 id="deposit-package">What to Place in the Deposit Package</h2>
4122
4123<p>An effective deposit is a maintainable snapshot, not just one MQ4 file. MQL4 projects can refer to include files, custom indicators, DLLs, data files, chart templates, and preset configurations. A source file may compile on the developer's machine because it silently depends on files that were never delivered. The deposit schedule should reveal those dependencies and state whether each is included, excluded, or available from a separate authorised source.</p>
4124
4125<p>Start with the exact source revision used to create the accepted build. Include the repository commit identifier if version control is used, plus an exported archive that does not depend on the repository remaining online. Add build notes that state the MT4 and MetaEditor environment, required folder locations, compiler warnings, and the output filename. Preserve the associated EX4 too, so a future maintainer can compare the compiled baseline with a newly compiled candidate.</p>
4126
4127<table style="width:100%;border-collapse:collapse;margin:16px 0;">
4128<thead><tr style="background:#f0f4ff;"><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Package item</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Why it matters</th></tr></thead>
4129<tbody>
4130<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">MQ4 source and include files</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Provides the editable implementation and compile dependencies.</td></tr>
4131<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">
4131Original EX4 and checksum</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Preserves the delivered baseline for comparison.</td></tr>
4132<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Custom indicators and libraries</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Prevents hidden dependencies from blocking a build or test.</td></tr>
4133<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Set files and input register</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Explains how known configurations were intended to operate.</td></tr>
4134<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Build and test instructions</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Lets a future maintainer reproduce a controlled starting point.</td></tr>
4135<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Rights and third-party notices</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Shows what may be used, shared, or replaced after release.</td></tr>
4136</tbody>
4137</table>
4138
4139<p>Do not assume every dependency can be copied. A third-party library may have its own licence, and a vendor-owned service may not transfer through escrow. Record this plainly. A future maintainer can then decide whether to renew a licence, replace the component, or limit the maintenance scope without accidentally using material beyond the available authority.</p>
4140
4141<p>Owners who have already recovered authorised source can use the site's <a href="/blog/mql4-recovery-handover-documentation-plan">MQL4 recovery handover documentation plan</a> to structure the records around that code. Escrow and handover documentation complement each other: the first preserves access under conditions, while the second makes the accessed material understandable.</p>
4142
4143<h2 id="release-triggers">Setting Clear Release Conditions</h2>
4144
4145<p>Release clauses should be specific enough to administer without guesswork. “If the developer fails” is too vague. Failure may mean a missed email, a disputed invoice, a long illness, or a permanent inability to support the product. The agreement can distinguish between ordinary service disagreements, which should follow normal dispute procedures, and serious continuity events that justify source release.</p>
4146
4147<p>Possible triggers might include insolvency, formal cessation of the relevant support business, a material uncured support failure after written notice, a refusal or inability to provide contracted critical maintenance, or the developer's death or permanent incapacity where no successor accepts the support duty. The suitability of any trigger depends on the transaction and local law. Parties should avoid writing a clause that creates an automatic release over a minor issue neither side intended to treat as final.</p>
4148
4149<p>A robust procedure also gives the depositor notice. The beneficiary submits a written request and supporting evidence to the holder. The holder notifies the depositor through current contact channels and allows the stated response period. If the trigger is admitted or not credibly contested under the agreed process, release occurs with a record of what was released and to whom. If there is a dispute, the agreement should identify an interim process rather than expecting a storage provider to resolve complex legal questions without authority.</p>
4150
4151<h3>Example release decision record</h3>
4152
4153<p>A concise record can list the request date, asserted trigger, notices sent, response deadline, evidence received, decision maker, release scope, and recipient. The record should state whether the beneficiary receives the entire archive or only the material permitted by the post-release licence. This is not bureaucracy for its own sake. It prevents a later claim that a source package was quietly released without the agreed conditions.</p>
4154
4155<h2 id="verification">Verify That the Deposit Can Be Used</h2>
4156
4157<p>Depositing files without verification is like storing a spare key without checking that it fits the lock. The depositor may accidentally upload the wrong branch, omit an include, encrypt the archive with a lost key, or provide instructions that no longer match the current MT4 environment. A verification process turns storage into meaningful continuity protection.</p>
4158
4159<p>Verification need not expose the developer's source to the beneficiary during the normal relationship. A neutral verifier operating under confidentiality can confirm that an archive opens, its contents match the manifest, the expected source files exist, and the documented build procedure reaches the stated result in a controlled environment. The parties can decide how deep the test should go. A basic check might confirm archive integrity. A stronger check might compile the project and run a limited non-live smoke test.</p>
4160
4161<p>Each verified update should produce a short certificate or record stating the deposit identifier, date, checksum, verification scope, result, and unresolved exceptions. For example, the record might say that the source archive opened and compiled with two warnings, while a proprietary data feed was excluded by agreement. This is more useful than a generic statement that “the escrow is current.”</p>
4162
4163<p>
4163Technical behavior still needs separate validation before any live use. The guide to <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating recovered MQL4 before live deployment</a> explains why compilation alone does not prove equivalent behavior or safe operation. A released deposit should enter a controlled review and test process, not go straight onto a trading account.</p>
4164
4165<h2 id="continuity-shield">Build a Continuity Shield Around the Code</h2>
4166
4167<p>The vault is one layer of a broader continuity shield. It should sit alongside ordinary backups, a maintained source repository, role-based access, release notes, a dependency inventory, and a designated decision maker. No single control can cover every failure. A source archive cannot keep a hosted API alive, and a repository cannot settle a disputed right to modify code. Together, however, these measures make a future response calmer and more evidence based.</p>
4168
4169<p>For each production change, update the code repository, build a release archive, revise the manifest, and decide whether the escrow deposit also needs updating. The agreement can set a threshold, such as changes to order logic, risk controls, dependencies, or accepted releases. Small internal experiments may not require a deposit. A deployed change that affects the beneficiary's ability to maintain the EA usually does.</p>
4170
4171<p>Assign people, not just inboxes. Name the business owner who can request action, the technical custodian who understands the build, the developer contact, and an alternate for each role. Keep contact details current. Review the arrangement at least when the support contract renews, the EA moves to a new broker environment, or the developer's business structure changes.</p>
4172
4173<h2 id="decision-process">A Decision Process for EA Owners</h2>
4174
4175<p>Not every custom EA needs formal escrow. A simple decision process can help an owner choose a proportionate path.</p>
4176
4177<ol>
4178<li><strong>Map the dependency.</strong> List what would stop if the developer became unavailable: code updates, licence changes, indicators, hosted data, or basic support.</li>
4179<li><strong>Review current rights.</strong> Read the development and support terms. Identify whether an ownership transfer, maintenance licence, or source handover already exists.</li>
4180<li><strong>Estimate continuity impact.</strong> Consider operational interruption, replacement difficulty, and whether the system can be safely paused. Do not treat historic trading results as a promise of future value.</li>
4181<li><strong>Choose the lightest workable control.</strong> This might be a client-held repository copy, scheduled source delivery, or a formal escrow arrangement with verification.</li>
4182<li><strong>Agree the deposit and release scope.</strong> Write down files, updates, security controls, triggers, notice procedures, and post-release rights.</li>
4183<li><strong>Test and review.</strong> Verify the deposited package and revisit it when the system materially changes.</li>
4184</ol>
4185
4186<p>Owners evaluating their broader source-access risk may find the site's guide on <a href="/">decompile ex4 to mql4</a> useful for understanding why compiled output is a poor substitute for planned source custody. Where a legitimate owner has already lost source and cannot obtain it through the original relationship, ForexMQ5 is reviewed as a professional recovery option. Any recovery request should be limited to authorised maintenance purposes and supported by ownership or permission records.</p>
4187
4188<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
4189  <h3 style="margin-top:0;">Need a Source Recovery Option for an Authorised Project?</h3>
4190  <p>This review site presents ForexMQ5 as a specialist option for documented EX4-to-MQ4 recovery needs. Owners should preserve rights records, the original file, and a clear maintenance scope before requesting an assessment.</p>
4191  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
4192</div>
4193
4194<h2 id="common-mistakes">Common Escrow Mistakes to Avoid</h2>
4195
4196<p>The most frequent mistake is treating escrow as a one-time ceremony. A deposit made at project launch can become obsolete after several releases. Another mistake is depositing source without the components needed to build or test it. A third is using release language that sounds reassuring but gives no workable procedure when a problem actually occurs.</p>
4197
4198<p>Parties should also avoid confusing escrow with permission to bypass restrictions. A released package must still be used within the ownership and licence terms that apply. It should not become a route to disclose confidential material, clone another vendor's product, defeat account controls, or distribute code to people outside the authorised maintenance scope. If rights are uncertain, pause and seek qualified advice.</p>
4199
4200<p>
4200Finally, do not overlook the human side. An arrangement is weak if contact details are stale, the developer's successor is unknown, or nobody internally knows the EA exists. Put the continuity plan into the operational records, schedule a review, and make sure an authorised person can find the agreement when it is needed.</p>
4201
4202<h2 id="conclusion">Protect Access Without Assuming the Worst</h2>
4203
4204<p>Source code escrow is a practical way to protect a custom Expert Advisor investment without demanding unrestricted access on day one. Its value comes from a secure vault, a carefully defined deposit, a contract key that explains rights, verified updates, and a continuity shield around the source. The best time to arrange those pieces is while the developer relationship is healthy and the system is understandable.</p>
4205
4206<p>For an EA owner, the immediate next step is simple: inventory the current files and dependencies, read the development agreement, identify the maintenance risk, and discuss a proportionate continuity plan with appropriate professional advice. An orderly agreement will not remove every technical or legal uncertainty, but it can replace a single point of failure with a documented path forward.</p>
4207    `},{slug:"expert-advisor-business-continuity-plan",title:"Expert Advisor Business Continuity Plan for Traders and Development Teams",metaTitle:"Expert Advisor Business Continuity Plan for Traders and Development Teams",metaDescription:"Build a practical continuity map for an MT4 Expert Advisor, including backups, ownership records, team handover, controlled recovery, and resilient trading operations.",keywords:"expert advisor business continuity plan, MT4 EA backups, trading operations continuity, EA team handover, MQL4 recovery planning, resilient automated trading system",excerpt:"A practical continuity plan for traders and development teams who need an Expert Advisor to remain understandable, recoverable, and safely manageable when a person, computer, vendor, or platform changes.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:ju,imageAlt:"trading team reviewing an Expert Advisor business continuity map",tableOfContents:[{id:"continuity-purpose",title:"Why an EA Needs a Continuity Plan"},{id:"continuity-map",title:"Map the Trading Operation Before a Failure"},{id:"backup-design",title:"Build Backups That Can Actually Be Restored"},{id:"access-and-ownership",title:"Control Access, Ownership, and Evidence"},{id:"handover",title:"Create a Usable Team Handover Pack"},{id:"failure-playbooks",title:"Write Playbooks for Common Disruptions"},{id:"recovery-decision",title:"Decide When Source Recovery Is Appropriate"},{id:"testing",title:"Test Continuity Without Risking a Live Account"},{id:"maintenance-rhythm",title:"Set a Practical Maintenance Rhythm"},{id:"conclusion",title:"A Resilient EA Is a Managed System"}],content:`
4208<p>An Expert Advisor can look self contained because it sits in a terminal and opens or manages trades automatically. In reality, a working EA depends on a chain of people, files, settings, accounts, computers, and decisions. The chain can break when a developer leaves, a VPS is replaced, a laptop fails, a broker changes symbol conventions, or the only person who understands a parameter is unavailable. A business continuity plan turns that fragile arrangement into an operation that another authorized person can understand and restore.</p>
4209
4210<p>This guide is written from an independent review-site perspective for traders, small desks, and development teams using MT4 automation. It does not promise that any EA will remain profitable or available in every market condition. Its purpose is operational: preserve the ability to pause, inspect, restore, and hand over an authorized system responsibly. The plan is useful whether the EA was built in house, commissioned from a contractor, or acquired with rights that permit the intended maintenance.</p>
4211
4212<img src="${ju}" alt="trading team reviewing an Expert Advisor business continuity map" style="width:100%;border-radius:8px;margin:24px 0;" />
4213
4214<h2 id="continuity-purpose">Why an EA Needs a Continuity Plan</h2>
4215
4216<p>Continuity is not the same as making more copies of an EX4 file. A copy may start on another machine and still be operationally useless if the team cannot identify its inputs, confirm the broker account, locate the correct set file, or decide whether open positions should be left alone. A continuity plan identifies the minimum information and capabilities needed to reach a safe state after disruption.</p>
4217
4218<p>For an EA, that safe state is usually one of three outcomes: trading is deliberately stopped while facts are checked, the approved version is restored in a controlled environment, or responsibility is transferred to a named person with enough context to make the next decision. The right outcome depends on the event. A brief VPS outage and a disputed ownership claim should not trigger the same response.</p>
4219
4220<p>Continuity planning also protects against quiet failures. A robot can keep running after a change while behaving differently because a symbol suffix changed, an input was overwritten, a time filter uses the wrong server time, or a dependency was omitted. Readers who need a focused inventory for a hosting move can pair this plan with the site guide to an <a href="/blog/expert-advisor-vps-transfer-audit-mt4">Expert Advisor VPS transfer audit</a>. The broader continuity map below adds people, evidence, decision rights, and recovery practice.</p>
4221
4222<h3>The continuity objective</h3>
4223<p>Write one plain language objective before collecting files. For example: “If the primary operator cannot access the VPS, an authorized backup operator can stop new entries, preserve records, and restore the approved EA configuration within the team’s stated response window.” This wording is better than “keep trading at all costs.” It prioritizes control over activity and gives the team a way to judge whether the plan works.</p>
4224
4225<table>
4226<thead><tr><th>
4226Continuity question</th><th>Useful answer</th><th>Weak answer</th></tr></thead>
4227<tbody>
4228<tr><td>What must be protected?</td><td>Approved EA, settings, logs, account context, and ownership records</td><td>The robot file</td></tr>
4229<tr><td>Who can act?</td><td>Named primary and backup roles with defined permissions</td><td>Someone from the group chat</td></tr>
4230<tr><td>What happens first?</td><td>Pause new entries, document status, then assess restoration</td><td>Restart everything</td></tr>
4231<tr><td>How is success checked?</td><td>A documented test restore and handover exercise</td><td>Backups exist somewhere</td></tr>
4232</tbody>
4233</table>
4234
4235<h2 id="continuity-map">Map the Trading Operation Before a Failure</h2>
4236
4237<p>Start with a one page map. It does not need expensive software. A spreadsheet, secured document, or internal wiki can work if it is accessible to the people who need it and protected from casual access. The map should show dependencies, custodians, locations, and the consequence of losing each item. It should describe the current approved setup, not an idealized version remembered from months ago.</p>
4238
4239<h3>Inventory the operating components</h3>
4240<ul>
4241<li><strong>Strategy artifact:</strong> the approved EX4 or MQ4, version label, file checksum where practical, and release date.</li>
4242<li><strong>Configuration:</strong> set files, chart templates, magic numbers, symbol list, timeframe, trading sessions, and intended risk controls.</li>
4243<li><strong>Platform environment:</strong> MT4 build, operating system, VPS provider, terminal path, installed indicators, DLL settings if legitimately required, and scheduled tasks.</li>
4244<li><strong>Account context:</strong> broker name, server, account type, permissions, symbol suffixes, and the person authorized to contact the broker. Do not put passwords in the map.</li>
4245<li><strong>Records:</strong> journals, trade exports, change notes, deployment dates, incident notes, and source ownership documents.</li>
4246<li><strong>People:</strong> strategy owner, technical maintainer, trading decision maker, compliance or operations contact if applicable, and backup operator.</li>
4247</ul>
4248
4249<p>Then draw the relationships. An EA might depend on a custom indicator in a separate folder, a set file held only on a developer laptop, and a VPS account owned by a former contractor. That is not one risk but three. Mapping makes the single points of failure visible before they become urgent.</p>
4250
4251<h3>Use a simple criticality rating</h3>
4252<p>Rate each dependency by impact and replaceability. Impact asks what happens if the item is missing during active trading. Replaceability asks whether an authorized person can recreate or obtain it quickly. An EX4 with known settings may be important but replaceable from a controlled archive. An undocumented account credential or a source assignment agreement can be far harder to replace. Prioritize the items with high impact and low replaceability.</p>
4253
4254<table>
4255<thead><tr><th>Dependency</th><th>Failure effect</th><th>Owner</th><th>Protected copy or route</th></tr></thead>
4256<tbody>
4257<tr><td>Approved EX4 and version note</td><td>Cannot restore the validated release</td><td>Technical maintainer</td><td>Read only archive plus checksum record</td></tr>
4258<tr><td>Set file and chart template</td><td>EA may run with unintended inputs</td><td>Trading operator</td><td>Versioned configuration folder</td></tr>
4259<tr><td>Broker login recovery route</td><td>Cannot inspect or intervene</td><td>Account holder</td><td>Broker approved recovery process</td></tr>
4260<tr><td>Source and entitlement records</td><td>Maintenance scope becomes uncertain</td><td>Business owner</td><td>Restricted legal and project archive</td></tr>
4261<tr><td>Deployment instructions</td><td>Backup operator improvises</td><td>Primary operator</td><td>Handover pack reviewed quarterly</td></tr>
4262</tbody>
4263</table>
4264
4265<p>Keep the map separate from secrets. It can point to a password manager entry or broker recovery procedure without reproducing credentials. This separation matters because a continuity document that exposes account access broadly creates a new risk while solving an old one.</p>
4266
4267<h2 id="backup-design">Build Backups That Can Actually Be Restored</h2>
4268
4269<p>A backup is only useful when it can be found, read, and restored by an authorized person. The usual failure is not that no copy exists. It is that copies are scattered across chat attachments, old terminals, personal cloud drives, and unnamed USB devices. Teams then cannot establish which copy was approved or whether its settings match the last known deployment.</p>
4270
4271<p>Create a controlled release folder for each approved version. Include the executable artifact, the matching configuration, a short release note, required dependencies, and a text file describing where it was tested. Name files consistently, such as strategy name, version, and approval date. A checksum can help distinguish an unchanged binary from a similarly named replacement. It does not prove strategy quality, but it provides a useful integrity reference.</p>
4272
4273<h3>The restore set checklist</h3>
4274<ol>
4275<li>Keep the original approved EX4 or source file only where access rights allow.</li>
4276<li>Store matching set files and chart templates beside the release, not only inside a live terminal.</li>
4277<li>Record required indicators, libraries, fonts, DLL permissions, and terminal settings.</li>
4278<li>Preserve an export of relevant account and trade history for incident context.</li>
4279<li>Maintain one protected primary archive and one separate recovery copy under documented access control.</li>
4280<li>
4280Test a restore into a non live environment after meaningful changes.</li>
4281</ol>
4282
4283<p>Do not confuse redundancy with unlimited duplication. More uncontrolled copies increase the chance that a sensitive strategy leaks or an outdated file is deployed. A better design has a small number of identified repositories, access logs where appropriate, and a clear label for the currently approved release. For a sole trader, this may be a secured primary storage location plus an encrypted recovery location and a written recovery instruction. For a team, it may be a restricted repository and managed document store.</p>
4284
4285<p>Configuration deserves the same attention as code. A sound backup of an EA with the wrong lot logic, account filter, news behavior, or symbol list is not a sound backup. Capture screenshots of the approved inputs when exporting a set file, then note why material values exist. The next operator should not have to guess whether a setting was deliberate or an experiment.</p>
4286
4287<h2 id="access-and-ownership">Control Access, Ownership, and Evidence</h2>
4288
4289<p>A resilient system has named authority. Technical access, trading authority, and intellectual property ownership are different things. The person who can log into a VPS might not be allowed to alter the EA. The client who funds an account might have a licence to use the robot but not the right to obtain or modify source. Blurring those roles creates avoidable conflict during an incident.</p>
4290
4291<p>Maintain a concise authority register. For each role, state what it may do, what it may not do, and how authority is verified. Include a route for removing access when a contractor leaves. Where a business uses commissioned work, retain the agreement, delivery acceptance, licence terms, and any source handover clause with the continuity records. This is not legal advice, but it prevents the team from relying solely on memory when a recovery decision is needed.</p>
4292
4293<h3>Minimum role design</h3>
4294<ul>
4295<li><strong>Account owner:</strong> authorizes broker and funding decisions, and retains the formal account relationship.</li>
4296<li><strong>Strategy owner:</strong> decides whether the strategy may be activated, paused, changed, or retired.</li>
4297<li><strong>Technical maintainer:</strong> preserves releases, performs controlled deployments, and documents technical changes.</li>
4298<li><strong>Backup operator:</strong> can perform predefined safe actions when the primary is unavailable.</li>
4299<li><strong>Independent reviewer:</strong> where needed, checks that restoration follows the documented version and scope.</li>
4300</ul>
4301
4302<p>Access should follow least privilege. A backup operator may need access to stop the terminal or disable automated trading, but not necessarily unrestricted rights to withdraw funds or alter source. Use the platform and broker controls available to separate responsibilities. Review access after personnel changes and after a vendor relationship ends. A continuity plan that still relies on a departed person’s email address has not been completed.</p>
4303
4304<p>For teams facing lost source, the continuity file should distinguish verified ownership from a mere copy of an EX4. The site’s <a href="/blog/recover-lost-mq4-expert-advisor-source-code">lost MQ4 source recovery guide</a> explains the evidence and technical questions in more depth. In a continuity plan, the immediate objective is narrower: preserve entitlement records and ensure the team knows who can authorize a recovery request.</p>
4305
4306<h2 id="handover">Create a Usable Team Handover Pack</h2>
4307
4308<p>A handover is successful when a capable newcomer can follow it without interpreting hidden assumptions. It should not be a biography of the EA or a pile of screenshots. It should be a short operating manual linked to the controlled archives. Write it for a calm person who has access but has never seen the chart before.</p>
4309
4310<h3>Suggested handover pack</h3>
4311<table>
4312<thead><tr><th>Item</th><th>What to include</th><th>Why it matters</th></tr></thead>
4313<tbody>
4314<tr><td>Service summary</td><td>EA purpose, markets, timeframe, and current status</td><td>Prevents an operator treating every file as interchangeable</td></tr>
4315<tr><td>Safe actions</td><td>How to stop new entries, capture logs, and notify authority holders</td><td>Gives a safe first move during uncertainty</td></tr>
4316<tr><td>Deployment runbook</td><td>Approved folder, template, set file, checks, and rollback point</td><td>Reduces configuration drift</td></tr>
4317<tr><td>Open exposure note</td><td>How the EA handles existing positions after being stopped</td><td>Separates operational pause from trading judgment</td></tr>
4318<tr><td>Contact ladder</td><td>Primary, backup, broker route, and vendor route where applicable</td><td>Avoids improvised escalation</td></tr>
4319<tr><td>Change record</td><td>What changed, who approved it, and where validation occurred</td><td>Makes later diagnosis possible</td></tr>
4320</tbody>
4321</table>
4322
4323<p>Use screenshots sparingly and date them. Screens change after platform updates, while a 
4323written check such as “confirm the account number and server shown in the terminal before attaching the EA” remains useful. Include the exact location of each controlled document, but do not embed credentials. If two people must approve a production change, say so explicitly.</p>
4324
4325<p>Run a handover conversation at least once. The primary operator should ask the backup to explain the first five actions after a VPS loss, then compare the answer to the runbook. Gaps are valuable findings, not a reason to blame the backup. Revise the pack until it supports confident, bounded action.</p>
4326
4327<h2 id="failure-playbooks">Write Playbooks for Common Disruptions</h2>
4328
4329<p>A continuity plan becomes practical through event playbooks. Each playbook should begin with a trigger, a safe immediate action, evidence to capture, who decides next steps, and a recovery condition. It should avoid pretending that every event has an automatic answer. Market exposure, client obligations, and broker rules may require judgment outside the playbook.</p>
4330
4331<h3>Example: primary VPS becomes unavailable</h3>
4332<ol>
4333<li>Confirm the outage through the VPS provider or terminal status rather than assuming a strategy fault.</li>
4334<li>Notify the named strategy owner and backup operator using the contact ladder.</li>
4335<li>Record the last known terminal time, open orders and positions, connection state, and screenshots if available.</li>
4336<li>Do not attach an EA to a replacement terminal until account, version, settings, and duplicate order risk are checked.</li>
4337<li>Restore only the approved release in a controlled environment, then document the decision to resume or remain paused.</li>
4338</ol>
4339
4340<h3>Example: the sole developer is unavailable</h3>
4341<p>First identify whether the immediate need is to keep an existing setup stable, fix a defect, or change strategy behavior. Stability may require no code change at all. Locate the handover pack, source archive, build notes, and ownership records. If source is unavailable, do not assume that an EX4 can be freely reconstructed or altered. Verify rights and scope, seek the developer or rights holder when possible, and use a documented decision path for any authorized recovery work.</p>
4342
4343<h3>Example: a broker or symbol change is suspected</h3>
4344<p>Pause modification activity and gather facts: terminal journal entries, expert logs, symbol specifications, spread behavior, and the exact failed condition. Compare the live environment against the approved map. A symbol mismatch can look like a strategy failure when it is actually a naming or contract specification change. Test any adjustment on a suitable non live setup before considering deployment. The goal is to avoid solving a configuration problem with an unreviewed code change.</p>
4345
4346<h2 id="recovery-decision">Decide When Source Recovery Is Appropriate</h2>
4347
4348<p>Source recovery belongs in a continuity plan as a conditional option, not as the default answer to every missing file. If an authorized team owns the source but has lost its copies, recovery may provide a starting point for maintenance. If a valid licence only permits use of a compiled EA, recovering or modifying code may exceed the team’s rights. Technical possibility does not settle ownership, contract, confidentiality, or local legal questions.</p>
4349
4350<p>Use a decision sequence: confirm the file identity, collect entitlement evidence, define the minimum maintenance purpose, ask whether an authorized original source route exists, and restrict the output to people with a need to know. Keep the recovered material out of public repositories and do not use it to bypass account locks, expiration controls, or other vendor restrictions. Where rights are uncertain or a dispute exists, obtain qualified advice before proceeding.</p>
4351
4352<p>For readers who have documented authority and need specialist help, this review site identifies the service at ForexMQ5 as a professional recovery option. The team requesting work remains responsible for confirming its rights and for the downstream use of any result. A controlled professional route may be preferable to unknown download tools, but it does not convert an unauthorized objective into an authorized one.</p>
4353
4354<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
4355  <h3 style="margin-top:0;">Need an Authorized Recovery Assessment?</h3>
4356  <p>Teams with a documented ownership or maintenance purpose can review the professional option described at ForexMQ5 before deciding how to preserve an EA project.</p>
4357  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
4358</div>
4359
4360<h2 id="testing">Test Continuity Without Risking a Live Account</h2>
4361
4362<p>A plan that has never been exercised is a hypothesis. Test the operational steps in a non live environment whenever feasible. The exercise is not a performance test and should not be treated as financial assurance. It is a check that files, access routes, instructions, and people still align.</p>
4363
4364<p>A simple quarterly exercise can be enough for a small operation. Give the backup operator a scenario such as “the primary terminal cannot be reached.” Ask them to locate the approved release, identify the safe stop action, find the contact ladder, and describe the checks required before a restoration. Record how long the steps took and what information was missing. Do not share real credentials merely to make the exercise convenient.</p>
4365
4366<h3>Continuity test acceptance checks</h3>
4367<ul>
4368<li>The operator found the currently approved version without guessing.</li>
4369<li>The set file and required dependencies were available and clearly matched the release.</li>
4370<li>The operator could explain how to prevent duplicate activation.</li>
4371<li>Authority holders and escalation routes were current.</li>
4372<li>The test produced a short record of actions, observations, and required updates.</li>
4373</ul>
4374
4375<p>When a restoration requires recovered MQL4, compile and inspect it in a controlled setup before it goes anywhere near a funded account. Recovered code can need cleanup, dependency checks, and behavior validation. A resilient operation does not mistake readable output for a ready to trade release.</p>
4376
4377<h2 id="maintenance-rhythm">Set a Practical Maintenance Rhythm</h2>
4378
4379<p>Continuity work succeeds through small recurring checks, not one dramatic document. Set a calendar reminder after every material release, staffing change, broker migration, VPS move, or change in ownership terms. Review the map, archives, and handover pack together. If no one can state which version is approved, the plan needs attention before an incident forces the issue.</p>
4380
4381<p>A lightweight rhythm might include a monthly review of terminal and backup access, a quarterly restore or handover exercise, and an immediate update after a deployment change. Record the date, reviewer, findings, and next action. This record is useful operational evidence that the plan reflects real practice rather than a forgotten template.</p>
4382
4383<p>Traders who are still building basic file literacy can begin with the homepage explanation of an <a href="/">ex4 decompiler</a> and the difference between compiled and editable artifacts. Teams planning an authorized maintenance path may also use the homepage overview of how to <a href="/">decompile ex4 to mq4</a> as background, while keeping continuity decisions grounded in their own contracts, backups, and approvals.</p>
4384
4385<h2 id="conclusion">A Resilient EA Is a Managed System</h2>
4386
4387<p>An EA business continuity plan does not eliminate outages, personnel changes, platform updates, or uncertainty. It gives an authorized team a measured response when those events occur. The essentials are straightforward: map dependencies, maintain restore sets, separate access from ownership, document a handover, rehearse safe actions, and treat source recovery as a rights based option rather than an automatic fix.</p>
4388
4389<p>The strongest plan favors a controlled pause over an uninformed restart. It makes the approved version easy to identify, gives backup operators limited but useful authority, and leaves an evidence trail for later review. That is 
4389what turns a trading robot from a single person dependency into a system that can be responsibly maintained through change.</p>
4390`},{slug:"ex4-recovery-service-quote-checklist",title:"EX4 Recovery Service Quote Checklist: Questions to Ask Before Paying",metaTitle:"EX4 Recovery Service Quote Checklist: Questions Before Paying",metaDescription:"Compare EX4 recovery service quotes with a practical checklist covering file assessment, scope, price, privacy, deliverables, testing, and support.",keywords:"EX4 recovery service quote, EX4 to MQ4 price, EX4 recovery checklist, compare EX4 decompilation services, MQ4 recovery deliverables",excerpt:"A low headline price is not a complete EX4 recovery quote. This independent checklist helps MT4 users compare scope, file assessment, deliverables, confidentiality, testing, revisions, and final cost before paying.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:qu,imageAlt:"EX4 recovery service quote checklist with price tag and comparison magnifier",tableOfContents:[{id:"quote-is-a-scope",title:"A Quote Is a Scope, Not Just a Price"},{id:"prepare-before-asking",title:"Prepare the File Before Requesting Quotes"},{id:"assessment-questions",title:"Questions About Assessment and Feasibility"},{id:"scope-and-deliverables",title:"Define Scope and Deliverables"},{id:"compare-price",title:"Compare Price Without Comparing Headlines"},{id:"quality-and-testing",title:"Ask How Quality Will Be Checked"},{id:"privacy-and-rights",title:"Privacy, Rights, and File Handling"},{id:"turnaround-and-support",title:"Turnaround, Revisions, and Support"},{id:"comparison-sheet",title:"Build a Fair Comparison Sheet"},{id:"decision-process",title:"A Practical Decision Process"},{id:"conclusion",title:"The Bottom Line Before Paying"}],content:`
4391<p>An EX4 recovery quote can look simple: upload a compiled MetaTrader 4 file, receive a price, and decide whether to pay. In practice, the useful comparison starts before the number. Two providers can quote different amounts because they are describing different work, different uncertainty, or different final deliverables. One may mean a raw reconstructed MQ4 file. Another may include compilation fixes, dependency notes, a basic review, or a defined revision window. A third may be pricing an attempt rather than a usable result.</p>
4392
4393<p>That is why a buyer should treat a quote as a compact project plan. It should explain what file is being assessed, what outcome is being proposed, what is excluded, how the result will be delivered, and what happens if the file cannot be handled as expected. This guide is written from an independent review-site perspective. It does not offer EX4 recovery. Its purpose is to help owners and authorised users ask better questions when evaluating a professional option such as ForexMQ5 or any alternative.</p>
4394
4395<img src="${qu}" alt="price tag and comparison magnifier for an EX4 recovery service quote" style="width:100%;border-radius:8px;margin:24px 0;" />
4396
4397<p>Good quote comparison also starts with a realistic expectation. An EX4 is compiled output, not a neatly packaged copy of the original project. Source recovery may require interpretation, cleanup, and testing. The build generation, protection methods, external libraries, custom indicators, and the condition of the supplied file all affect what can reasonably be reconstructed. No responsible buyer should assume that a single advertised price guarantees identical output for every file.</p>
4398
4399<p>The availability of an <a href="/">ex4 decompiler</a> does not make every quoted result equivalent. A tool, a manual process, and a professional recovery service can each involve different levels of review and accountability. Comparing the proposed result rather than the label is the safer starting point.</p>
4400
4401<p>Readers who are still deciding whether recovery is the right route may first want to understand the tradeoff between recovery and a fresh implementation in the site’s <a href="/blog/expert-advisor-source-recovery-vs-rebuild-budget-guide">source recovery versus rebuild budget guide</a>. This article instead focuses on the point where recovery remains under consideration and a quote needs to be judged fairly.</p>
4402
4403<h2 id="quote-is-a-scope">A Quote Is a Scope, Not Just a Price</h2>
4404
4405<p>A price alone answers very little. It does not tell a buyer whether the provider has examined the actual file, whether the quote covers one EA or a set of related files, or whether the output is expected to compile. It also does not identify the assumptions behind the number. A quote becomes useful when its scope is specific enough that two peo
4405ple would understand the same job from it.</p>
4406
4407<p>For an EX4 project, scope normally has five parts: the input, the objective, the work included, the deliverables, and the boundaries. The input is the exact file or files, along with relevant platform details. The objective might be maintenance of an owned EA, an authorised code audit, or restoration after original source was lost. Included work could range from extraction only to cleanup and compile-error correction. Deliverables are the files and notes the customer receives. Boundaries state what will not be done, such as strategy redesign, account-lock removal, performance promises, or integration with unprovided libraries.</p>
4408
4409<table>
4410<thead><tr><th>Quote element</th><th>What a buyer should be able to identify</th><th>Why it matters</th></tr></thead>
4411<tbody>
4412<tr><td>Input</td><td>File name, type, version or build clues, and number of files</td><td>Prevents a one-file quote from quietly becoming a multi-file job.</td></tr>
4413<tr><td>Objective</td><td>Recovery, maintenance, authorised inspection, or migration preparation</td><td>Keeps the work aligned with a legitimate and measurable need.</td></tr>
4414<tr><td>Included work</td><td>Extraction, cleanup, compile fixes, annotations, or testing</td><td>Separates a raw output from a more complete handover.</td></tr>
4415<tr><td>Deliverables</td><td>MQ4, MQH files, report, dependency list, and test notes where applicable</td><td>Lets the buyer compare what is actually being purchased.</td></tr>
4416<tr><td>Exclusions</td><td>Unsupported libraries, changes to strategy logic, live deployment, or guarantee limits</td><td>Reduces surprise invoices and unrealistic expectations.</td></tr>
4417</tbody>
4418</table>
4419
4420<p>Specificity should not be confused with a promise that every technical unknown has disappeared. A careful provider may say that final recoverability depends on an initial inspection. That is more useful than a confident but unexplained guarantee. The buyer’s goal is not to force certainty where none exists. The goal is to make uncertainty visible, priced, and bounded.</p>
4421
4422<h2 id="prepare-before-asking">Prepare the File Before Requesting Quotes</h2>
4423
4424<p>A short preparation step improves both the quality and speed of quotations. It avoids asking providers to guess about a file’s origin, role, and dependencies. It also helps the requester confirm that they have a legitimate basis to seek recovery. Possessing an EX4 is not automatically permission to reconstruct or redistribute its code. An owner should retain the contract, licence, assignment, or written authorisation that supports the intended work.</p>
4425
4426<p>Prepare a neutral project brief. It does not need to disclose a trading method in detail. It should identify the practical maintenance problem, the required platform, and any known components. For example: “Custom MT4 EA commissioned by the requester in 2022; source archive is unavailable; request is for authorised maintenance; the EA loads one supplied custom indicator and uses no known DLL.” This is more useful than “please decompile urgently.”</p>
4427
4428<h3>Pre-quote file checklist</h3>
4429<ul>
4430<li>Make an untouched backup of the original EX4 before sending copies anywhere.</li>
4431<li>Record the file name, size, modification date, and where it came from.</li>
4432<li>State whether it is an Expert Advisor, custom indicator, script, or library.</li>
4433<li>Note the MT4 terminal and build context if known, without guessing.</li>
4434<li>List related EX4, MQH, DLL, set, preset, or indicator files that may be needed.</li>
4435<li>Describe the intended outcome, such as readable code for maintenance or a compile-ready starting point.</li>
4436<li>Gather proof of ownership, licence rights, or authorisation for the requested purpose.</li>
4437<li>Remove passwords, account credentials, and unrelated client data from any accompanying archive.</li>
4438</ul>
4439
4440<p>Do not alter the original to make it easier to upload. Renaming a copy for clarity is usually fine, but modifying the file can complicate later troubleshooting. If a provider asks for a working setup, send a separate, carefully checked package and say exactly what it contains. A quote based on a complete dependency picture is often more reliable than one based on an isolated binary that cannot be evaluated in context.</p>
4441
4442<h2 id="assessment-questions">Questions About Assessment and Feasibility</h2>
4443
4444<p>The first commercial question should be whether the provider will assess the actual EX4 before setting a firm price. A provider does not necessarily need to reveal technical methods, but they should be able to explain the decision process in plain language. A file’s age and build characteristics can affect the likely result. So can signs of packing, obfuscation, missing dependencies, or damage. A generic price card may be a starting point, not a final diagnosis.</p>
4445
4446<h3>Questions to ask during assessment</h3>
4447<ol>
4448<li><strong>Is this a fixed quote, an estimate, or an assessment fee?</strong> Ask what triggers any price change and whether approval is required before extra work begins.
4448</li>
4449<li><strong>Has the quote been based on the actual file?</strong> If not, ask which details are assumed and what happens after inspection.</li>
4450<li><strong>What conditions could limit or prevent a useful recovery?</strong> A clear answer should mention technical constraints without inventing certainty.</li>
4451<li><strong>Does the assessment distinguish an EA from an indicator, script, or library?</strong> Their dependency and testing needs can differ.</li>
4452<li><strong>Are external components in scope?</strong> Ask specifically about DLL calls, imported functions, included files, and custom indicators.</li>
4453<li><strong>Will the provider identify missing inputs before work starts?</strong> This can prevent a recovered file that cannot be meaningfully reviewed.</li>
4454<li><strong>What is the outcome if the assessment finds the job unsuitable?</strong> Obtain the answer in writing, including any fee treatment.</li>
4455</ol>
4456
4457<p>Buyers should be cautious with vague language such as “all versions supported” or “perfect source guaranteed” when no file review has happened. That language may be marketing shorthand, but it is not a scope. A more credible response describes the next step: inspect the file, identify its likely characteristics, then provide a stated path and price. Technical limits are not a defect in a quote when they are communicated honestly.</p>
4458
4459<p>For background on why file generation matters, the site’s <a href="/blog/ex4-mt4-build-detection-guide">MT4 EX4 build detection guide</a> explains the clues that can shape a recovery conversation. A customer need not become a reverse-engineering specialist, but knowing that build context matters makes it easier to recognise an incomplete quote.</p>
4460
4461<h2 id="scope-and-deliverables">Define Scope and Deliverables</h2>
4462
4463<p>The word “decompiled” is too broad to serve as a deliverable by itself. One buyer may expect a folder that opens in MetaEditor. Another may only need enough readable logic for an independent developer to estimate a rebuild. A third may want an authorised audit package with comments and a dependency map. Each can be reasonable, but they are different projects and should be quoted differently.</p>
4464
4465<p>Ask the provider to name every expected item. At a minimum, this may be an MQ4 file. For more involved work, it may include reconstructed include files, a list of unresolved external calls, compile notes, a description of changes made during cleanup, and a statement of whether testing occurred. A delivered file that compiles is useful, but compilation alone does not prove it behaves like the original. Conversely, a file with compile errors may still contain valuable readable material if the agreed goal was analysis rather than deployment. The quote should say which standard applies.</p>
4466
4467<table>
4468<thead><tr><th>Possible deliverable</th><th>Question to ask</th><th>Useful acceptance check</th></tr></thead>
4469<tbody>
4470<tr><td>Recovered MQ4</td><td>Will it be supplied in editable text form?</td><td>File opens and can be archived by the customer.</td></tr>
4471<tr><td>Compile-ready project</td><td>Which MT4 environment was used for the compile check?</td><td>Customer can reproduce the stated compile result with supplied dependencies.</td></tr>
4472<tr><td>Dependency inventory</td><td>Will missing indicators, libraries, or resources be listed?</td><td>List distinguishes supplied items from unresolved items.</td></tr>
4473<tr><td>Cleanup notes</td><td>Which edits were made after initial reconstruction?</td><td>Notes identify material fixes without claiming original authorship.</td></tr>
4474<tr><td>Test record</td><td>What test was run, with which inputs and limits?</td><td>Record describes observations, not a trading-performance promise.</td></tr>
4475</tbody>
4476</table>
4477
4478<h3>Ask about source readability</h3>
4479<p>Readability is often worth discussing separately from mere output. Decompiled code may contain generic variable names, repeated structures, or sections that require interpretation. A buyer can ask whether the quoted scope includes sensible formatting, basic renaming where confidence is justified, comments describing uncertain areas, or a handover call to explain the file structure. They should not demand that a provider recreate the original programmer’s naming choices or documentation if that material was never present in the EX4.</p>
4480
4481<p>A practical phrasing is: “What level of cleanup is included, and how will uncertain logic be marked?” This gives the provider room to be accurate. It also stops a customer from mistaking a reconstructed artifact for a historical original source archive.</p>
4482
4483<h2 id="compare-price">Compare Price Without Comparing Headlines</h2>
4484
4485<p>Price matters, but a low number is meaningful only when it purchases the same scope. A quote that includes assessment, reconstruction, compile correction, and a limited revision period may cost more than a bare output quote. Neither is automatically better. The right choice depends on the buyer’s actual need and the cost of work left for someone else.</p>
4486
4487<p>Separate the price into stages where possible. An assessment charge, a base recovery amount, a fee for additional dependencies, and an optional testing or cleanup stage are easier to evaluate than a single unexplained total. This structure also helps a buyer set a stop point. If assessment shows that the file needs extensive manual reconstruction, the owner can compare the updated quote with a rebuild estimate rather than continuing because money has already been spent.</p>
4488
4489<h3>Price questions that expose hidden scope</h3>
4490<ul>
4491<li>Is the quoted amount per file, per project, or per hour?</li>
4492<li>Does “one file” include related EX4 libraries or custom indicators?</li>
4493<li>Are taxes, payment processing charges, rush fees, or currency conversion costs additional?</li>
4494<li>Is the assessment included, credited against the project, or non-refundable?</li>
4495<li>What work causes a revised quote, and must the customer approve it first?</li>
4496<li>Does the price include compile-error correction or only delivery of recovered text?</li>
4497<li>Is there a charge for a reasonable correction if the delivered scope does not match the written quote?</li>
4498<li>What happens financially if the provider cannot produce the agreed outcome?</li>
4499</ul>
4500
4501<p>A useful comparison should also consider the buyer’s downstream cost. Suppose Quote A is cheaper but provides only an MQ4 file with several unresolved dependencies. Quote B costs more but supplies a dependency list and a compile check. If an independent MQL4 developer will need to spend time discovering the same problems after Quote A, the initial saving may not be the lower total cost. The answer depends on the available technical help, the urgency of the maintenance task, and the desired handover standard.</p>
4502
4503<p>Price should never be used as evidence that a provider can lawfully bypass a licence restriction or recover every protected file. A request to remove account, broker, expiry, or activation controls deserves particular caution. Buyers should obtain authorised support from the rights holder where possible. Recovery for a documented maintenance purpose is different from seeking to defeat a vendor’s access controls.</p>
4504
4505<h2 id="quality-and-testing">Ask How Quality Will Be Checked</h2>
4506
4507<p>A quote should say something about verification, even if only basic checks are included. Quality assurance for recovered MQL4 has layers. Syntax and compilation are one layer. Loading the EA in a controlled MT4 environment is another. Comparing observable behavior using known settings can add useful evidence, provided the test conditions are documented. None of these steps proves future profitability or guarantees identical behavior across brokers, symbols, spreads, or market conditions.</p>
4508
4509<p>Ask the provider to distinguish what they will test from what the customer must test. A professional recovery process may reasonably validate whether supplied code compiles in a stated environment and whether obvious missing references are identified. It may not reasonably promise that a strategy will achieve a particular return, pass a prop-firm evaluation, or operate safely on a live account. Those are trading and deployment questions that need a separate validation plan.</p>
4510
4511<h3>Minimum quality questions</h3>
4512<ol>
4513<li>Will the delivered MQ4 be compiled, and in what environment?</li>
4514<li>Will compile warnings and errors be included in the handover notes?</li>
4515<li>Are supplied dependencies used in the check, and are absent dependencies identified?</li>
4516<li>Is a controlled attach or backtest check included, if appropriate?</li>
4517<li>How are uncertain sections or manual corrections documented?</li>
4518<li>What evidence is provided for the stated test, if any?</li>
4519<li>What customer testing is recommended before any live use?</li>
4520</ol>
4521
4522<p>A buyer should retain the original EX4 and compare it with the recovered project only in a safe, authorised setting. Inputs, logs, trade timing, and error messages can all be useful. If behavior differs, the difference is a diagnostic signal, not proof that either file is inherently wrong. Broker symbol suffixes, terminal build differences, unavailable data, and missing dependencies can all affect results. No recovered EA should be moved directly to a funded account merely because it c
4522ompiled.</p>
4523
4524<h2 id="privacy-and-rights">Privacy, Rights, and File Handling</h2>
4525
4526<p>An EX4 file may embody commercially sensitive logic. The quote process should therefore cover confidentiality and handling, not only technical output. Ask where the file is uploaded, who can access it, whether it is stored after delivery, and whether the provider uses it for any purpose beyond the agreed work. A concise written answer is better than a vague assurance that files are “safe.”</p>
4527
4528<p>The requester also has responsibilities. They should provide only files they are entitled to share and avoid including account credentials, personal records, customer databases, or unrelated proprietary material. If the file belongs to a business, the person requesting a quote should have authority to disclose it. An independent reviewer cannot decide ownership from an invoice alone, and neither should a customer assume that payment for an EA automatically includes source recovery rights.</p>
4529
4530<table>
4531<thead><tr><th>Handling topic</th><th>Question for the quote</th><th>Reasonable clarity looks like</th></tr></thead>
4532<tbody>
4533<tr><td>Upload</td><td>How should the EX4 be transferred?</td><td>A defined channel and guidance not to send passwords.</td></tr>
4534<tr><td>Access</td><td>Who may view the file and output?</td><td>A role-based explanation, not an unlimited claim.</td></tr>
4535<tr><td>Retention</td><td>How long are working copies retained after handover?</td><td>A stated period or deletion process.</td></tr>
4536<tr><td>Confidentiality</td><td>Can the provider sign or follow an appropriate confidentiality arrangement?</td><td>Terms that match the project rather than casual promises.</td></tr>
4537<tr><td>Rights</td><td>What confirmation does the requester make about authority?</td><td>A clear acknowledgement that the customer is responsible for permission.</td></tr>
4538</tbody>
4539</table>
4540
4541<p>These questions are not adversarial. They establish a professional boundary that benefits both sides. A provider that asks about intended use and rights may be protecting the customer as well as itself. A buyer who needs certainty on local copyright, contract, employment, or licence issues should speak with a qualified adviser in the relevant jurisdiction. This checklist is an operational guide, not legal advice.</p>
4542
4543<h2 id="turnaround-and-support">Turnaround, Revisions, and Support</h2>
4544
4545<p>Turnaround time should be tied to milestones. “Fast delivery” is not enough when a file must be assessed, dependencies checked, output cleaned, and results handed over. Ask when the provider expects to confirm feasibility, when payment is due, when draft or final output is expected, and what events could extend the timeline. A file that proves more complex than first expected may justify an updated estimate, but the customer should be told before unapproved work proceeds.</p>
4546
4547<p>Revision terms deserve equal attention. Recovery work can involve ambiguity. A buyer should ask what counts as a correction to the agreed scope, what counts as new work, how long a correction request may be submitted after delivery, and what evidence is helpful. “It does not trade the way I remember” is too broad without settings, logs, and a reproducible test. “The promised MQ4 cannot compile in the named environment using the supplied files, and here is the error log” is a clearer support request.</p>
4548
4549<h3>Support checklist</h3>
4550<ul>
4551<li>Get a written expected timeline and the point from which it starts.</li>
4552<li>Ask whether rush handling exists and what it changes in price or scope.</li>
4553<li>Confirm the payment milestones and accepted payment method before transfer.</li>
4554<li>Request a defined handover channel and an inventory of delivered files.</li>
4555<li>Ask for the period allowed to report a scope mismatch or delivery issue.</li>
4556<li>Clarify whether post-delivery code changes are revisions, consulting, or a new project.</li>
4557<li>Keep all approvals, test notes, and final files in one project folder.</li>
4558</ul>
4559
4560<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
4561<h3 style="margin-top:0;">Ready to Compare a Professional Option?</h3>
4562<p>ForexMQ5 is reviewed as a professional EX4 recovery option for customers with a documented, authorised maintenance or recovery need. A clear project brief and checklist make any quote easier to assess.</p>
4563<a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
4564</div>
4565
4566<h2 id="comparison-sheet">Build a Fair Comparison Sheet</h2>
4567
4568<p>Memory is a poor comparison tool when several quotes arrive over different days. Put each answer into one simple sheet. Do not score a provider only by price. Instead, identify whether the answer was direct, whether scope is comparable, and whether a limitation was explained. A provider that says “unknown until assessment” may be more transparent than one that claims certainty without seeing the EX4.</p>
4569
4570<table>
4571<thead><tr><th>Comparison field</th><th>Provider A</th><th>Provider B</th><th>What to look for</th></tr></thead>
4572<tbody>
4573<tr><td>Actual-file assessment</td><td>Record answer</td><td>Record answer</td><td>Whether assumptions are stated.</td></tr>
4574<tr><td>Quoted scope</td><td>Record deliverables</td><td>Record deliverables</td><td>Like-for-like work, not labels.</td></tr>
4575<tr><td>Total and possible extras</td><td>Record amount</td><td>Record amount</td><td>Approval required before additions.</td></tr>
4576<tr><td>Dependencies</td><td>Record treatment</td><td>Record treatment</td><td>Missing items identified clearly.</td></tr>
4577<tr><td>Compile and test checks</td><td>Record method</td><td>Record method</td><td>Evidence and stated limits.</td></tr>
4578<tr><td>Privacy and retention</td><td>Record terms</td><td>Record terms</td><td>Specific handling process.</td></tr>
4579<tr><td>Timeline and revisions</td><td>Record terms</td><td>Record terms</td><td>Milestones and correction boundary.</td></tr>
4580</tbody>
4581</table>
4582
4583<p>Use notes rather than forcing every item into a numeric score. For a straightforward owned EA with no dependencies, a fixed-price recovery with a compile check may be sufficient. For a business-critical system with indicators, libraries, and a handover to another developer, documentation and support may matter more than the lowest opening number. The comparison sheet makes that distinction visible.</p>
4584
4585<h2 id="decision-process">A Practical Decision Process</h2>
4586
4587<p>Once quotes are collected, use a deliberate decision sequence. First, remove any quote that does not fit the requester’s documented rights or asks the customer to conceal the intended use. Second, remove quotes whose deliverables cannot be understood. Third, compare the remaining scopes and all-in costs. Finally, choose the level of validation and support that matches the consequence of a poor handover.</p>
4588
4589<p>A simple example illustrates the process. An owner has one custom EA and evidence that the source was commissioned for their business. The EA uses a custom indicator. One quote offers a low fixed amount for “decompile EX4” but says nothing about the indicator or compilation. Another quote costs more after an assessment but lists the EA, indicator review, an MQ4 handover, a dependency note, and a compile check in a named terminal environment. The second quote may be the more comparable fit because it addresses the actual project. It is not automatically the better provider, but it is the more complete proposal.</p>
4590
4591<p>Before payment, send a final confirmation that repeats the agreed essentials: files included, price and currency, payment stage, deliverables, expected timeline, privacy handling, test scope, and revision terms. This message is not bureaucracy for its own sake. It gives both parties a shared reference if a later question arises about what was purchased.</p>
4592
4593<h3>Final pre-payment checklist</h3>
4594<ol>
4595<li>Confirm authority to request recovery and share every supplied file.</li>
4596<li>Keep an untouched original EX4 and a record of its origin.</li>
4597<li>Verify that the quote names the files and objective correctly.</li>
4598<li>Check whether the figure is fixed, estimated, or subject to assessment.</li>
4599<li>List all promised deliverables and exclusions in writing.</li>
4600<li>Confirm how dependencies, compile errors, and uncertain sections are handled.</li>
4601<li>Understand the quality check without treating it as a trading guarantee.</li>
4602<li>Review confidentiality, access, and retention terms.</li>
4603<li>Confirm timeline, payment milestone, support period, and revision boundary.</li>
4604<li>Plan controlled testing before any production or live trading use.</li>
4605</ol>
4606
4607<p>For readers comparing technical approaches at the same time, the site’s <a href="/">ex4 to mq4 decompiler</a> review resources explain why a professional route, an older free utility, and hands-on analysis should not be treated as interchangeable products. The appropriate route depends on the file, the rights held, the desired result, and the buyer’s ability to validate what comes back.</p>
4608
4609<h2 id="conclusion">The Bottom Line Before Paying</h2>
4610
4611<p>The best EX4 recovery quote is not necessarily the cheapest, fastest, or most confident sounding one. It is the one that accurately describes the authorised job, makes technical uncertainty visible, identifies the deliverable, and sets sensible boundaries around price, privacy, testing, and support. A buyer who asks those questions can compare providers on 
4611substance rather than on a headline figure.</p>
4612
4613<p>Start with rights and a clean project brief. Ask whether the actual file was assessed. Require a clear list of included work, exclusions, and final files. Compare total scope rather than a single price tag. Then preserve the quote, test the recovered result in a controlled environment, and keep live trading decisions separate from the recovery transaction. That disciplined process gives an EX4 owner a much better basis for deciding whether to pay and what to expect after delivery.</p>
4614`},{slug:"ex4-source-recovery-confidentiality-checklist",title:"EX4 Source Recovery Confidentiality Checklist for Proprietary Trading Code",metaTitle:"EX4 Source Recovery Confidentiality Checklist | Proprietary Code",metaDescription:"Use this practical confidentiality checklist to prepare proprietary EX4 code for authorised source recovery, including agreements, encrypted transfer, access control, and secure delivery.",keywords:"EX4 source recovery confidentiality, encrypted EX4 file transfer, proprietary trading code security, EX4 confidentiality agreement, secure MQ4 delivery, source recovery checklist",excerpt:"A practical review-site checklist for owners preparing proprietary EX4 files for authorised source recovery. Learn how to define scope, document rights, encrypt transfer, control access, and receive recovered code securely.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:Pu,imageAlt:"encrypted source code transfer checklist for proprietary EX4 trading software",tableOfContents:[{id:"why-confidentiality-needs-a-plan",title:"Why Confidentiality Needs a Plan"},{id:"define-the-sensitive-asset",title:"Define the Sensitive Asset and Scope"},{id:"rights-and-authority",title:"Confirm Rights and Authority"},{id:"agreement-checklist",title:"Build a Useful Confidentiality Agreement"},{id:"prepare-the-package",title:"Prepare a Minimal Transfer Package"},{id:"encrypted-transfer",title:"Choose an Encrypted Delivery Channel"},{id:"access-controls",title:"Control Access During the Work"},{id:"recovery-output",title:"Secure the Recovered Output"},{id:"decision-workflow",title:"A Practical Decision Workflow"},{id:"common-failures",title:"Common Confidentiality Failures"},{id:"conclusion",title:"Conclusion: Treat Recovery as a Controlled Project"}],content:`
4615<p>Recovering source from a proprietary EX4 is not only a technical request. The file may embody a trading method, risk rules, licensing logic, client-specific settings, or years of iterative development. Even when a requester has a legitimate right to seek recovery, careless handling can disclose information that the owner intended to keep private. A sensible process therefore asks two questions at the same time: is the request authorised, and can the file move through the project without unnecessary exposure?</p>
4616
4617<p>This guide is written from an independent review-site perspective. It helps owners, managers, and authorised developers prepare a confidential recovery project before they choose a route. It does not provide legal advice, and it does not suggest that every EX4 should be recovered. Contract terms, copyright, employment arrangements, privacy obligations, and local law can affect what is appropriate. When the ownership position is uncertain or the code has material business value, qualified legal advice may be worthwhile before transfer.</p>
4618
4619<img src="${Pu}" alt="encrypted transfer process for proprietary EX4 source recovery" style="width:100%;border-radius:8px;margin:24px 0;" />
4620
4621<p>The aim is practical restraint. Send only the files needed for the stated purpose. Give access only to people who need it. Use a channel that protects data in transit and verify who receives it. Agree in advance on the destination, retention period, and deletion process for the result. Those habits reduce avoidable risk whether the owner uses an internal engineer or assesses a specialist option.</p>
4622
4623<h2 id="why-confidentiality-needs-a-plan">Why Confidentiality Needs a Plan</h2>
4624
4625<p>An EX4 is compiled, but compilation is not a confidentiality program. It may make ordinary reading difficult while still containing behavior that can be examined, tested, or partially reconstructed. The surrounding project can be even more revealing than the binary itself. File names, parameter sets, account identifiers, trade logs, comments, screenshots, and emails may expose strategy assumptions or personal data. Sending an entire terminal folder because it feels convenient is usually a larger disclosure than the technical task needs.
4625</p>
4626
4627<p>Confidentiality should be designed before the first upload, not added after a disagreement. Once a file is copied to an uncontrolled mailbox, public file host, or chat attachment, the owner may have little visibility into forwarding, download history, or retention. A disciplined intake also creates a record of what was provided and why. That record helps distinguish an authorised maintenance exercise from an open-ended request for access to someone else's trading logic.</p>
4628
4629<p>There are several interests to protect:</p>
4630<ul>
4631  <li><strong>Strategy confidentiality:</strong> entries, exits, filters, position sizing, and execution handling may be commercially sensitive.</li>
4632  <li><strong>Business confidentiality:</strong> client names, broker arrangements, product roadmaps, and commercial terms can appear in accompanying material.</li>
4633  <li><strong>Personal and account data:</strong> logs and configuration files can contain identifiers that do not belong in a recovery package.</li>
4634  <li><strong>Operational security:</strong> credentials, server addresses, licence keys, and remote access details should never be treated as routine attachments.</li>
4635  <li><strong>Chain of custody:</strong> the owner may later need to know which exact binary was supplied and which output came back.</li>
4636</ul>
4637
4638<p>Readers who are still deciding whether recovery is the right technical path can compare the available approaches in the site’s <a href="/blog/ex4-to-mq4-recovery-methods-and-validation-guide">EX4 recovery methods and validation guide</a>. The confidentiality plan should fit the selected path. A small, authorised repair request has different exposure than a migration project involving several indicators, custom libraries, and a development team.</p>
4639
4640<h2 id="define-the-sensitive-asset">Define the Sensitive Asset and Scope</h2>
4641
4642<p>Start by describing the asset in plain language. “The EA” is too vague. Identify the exact EX4 name, version, build context if known, file hash, intended outcome, and business owner. If a contractor must determine whether recovery is technically possible, that initial scope can be limited to assessment. It does not need to become permission to inspect every related file or to alter the recovered code. Owners comparing tools and processes can begin with this site’s <a href="/">ex4 decompiler</a> review resources, then narrow the decision to an authorised and confidential workflow.</p>
4643
4644<p>A short scope statement prevents scope creep. For example: “Assess whether the owner’s archived Expert Advisor can be reconstructed into maintainable MQ4 for an internal compatibility review. No account controls, credentials, customer files, or unrelated indicators are included. Output is for the named owner’s internal engineering team only.” This is clearer than asking someone to “unlock” a robot or “see how it works.”</p>
4645
4646<table>
4647  <thead><tr><th>Item</th><th>Include?</th><th>Reason</th></tr></thead>
4648  <tbody>
4649    <tr><td>Exact EX4 under review</td><td>Usually</td><td>It is the minimum technical input for an assessment or recovery.</td></tr>
4650    <tr><td>Checksum and version note</td><td>Yes</td><td>They help identify the submitted binary and support a clean handover record.</td></tr>
4651    <tr><td>Compiler errors from a prior attempt</td><td>Only if relevant</td><td>Useful context can be shared without unrelated terminal data.</td></tr>
4652    <tr><td>Terminal logs and statements</td><td>Normally no</td><td>They can reveal account or trading information without helping source recovery.</td></tr>
4653    <tr><td>Passwords, API keys, licence keys</td><td>Never</td><td>They are not needed to reconstruct code and create needless security risk.</td></tr>
4654    <tr><td>Other EAs, DLLs, or libraries</td><td>Only after review</td><td>Provide them only when a specific dependency makes them necessary.</td></tr>
4655  </tbody>
4656</table>
4657
4658<p>File minimisation is a security control, not an inconvenience. A provider cannot expose material it never receives. Before packaging, inspect folders for hidden files, archives, screenshots, configuration backups, and exported account reports. Remove data that is unrelated to the defined task. Do not alter the original EX4 to make it smaller or more anonymous. Preserve it separately, then create a controlled copy for transfer.</p>
4659
4660<h2 id="rights-and-authority">Confirm Rights and Authority</h2>
4661
4662<p>Confidential handling does not solve an unauthorised request. The person sending a file should be able to explain why they may authorise recovery and who may receive the result. Ownership of an account, possession of a download, or payment for an EA licence may not equal ownership of source code. A commissioned project may have an assignment clause, a source handover clause, or a restriction that changes the answer. Internal staff may 
4662need authority from the company that owns the asset.</p>
4663
4664<p>Create a compact authority record before sending anything. It need not reveal a full contract to every technician. It should identify the legal or organisational owner, the authorised contact, the basis for the request, and the permitted purpose. Keep the underlying documents with the owner. If the request relies on a licence, written permission, employment role, or a client instruction, retain the relevant evidence in case questions arise.</p>
4665
4666<h3>Authority checkpoint</h3>
4667<ol>
4668  <li>Identify the creator and current rights holder as accurately as the records allow.</li>
4669  <li>Read the development agreement, licence, purchase terms, or assignment for source and reverse-engineering restrictions.</li>
4670  <li>Confirm that the person approving transfer can bind the owner or has written approval.</li>
4671  <li>State the limited purpose, such as recovery, maintenance, compatibility analysis, or an authorised audit.</li>
4672  <li>Pause if the goal is to bypass account limits, copy a competitor, redistribute code, or remove vendor controls.</li>
4673</ol>
4674
4675<p>This checkpoint is especially important when a business has changed hands, a freelancer is unavailable, or a former employee kept the original repository. An urgent operational problem is understandable, but it does not clarify title by itself. Legal and purpose questions should be resolved before technical action, particularly where a contract, licence, or third-party rights may apply.</p>
4676
4677<h2 id="agreement-checklist">Build a Useful Confidentiality Agreement</h2>
4678
4679<p>A confidentiality agreement, sometimes called an NDA, is most useful when it names the actual information and describes real handling expectations. A generic promise to keep “everything confidential” can leave practical gaps. It may not say whether an EX4, reconstructed MQ4, communications, test output, and strategy documentation are all covered. It may also omit subcontractors, retention, incident notification, or the return of material at the end.</p>
4680
4681<p>The agreement should be proportionate. A solo owner sending one file may need a clear written confirmation and a secure process more than a lengthy document designed for a corporate acquisition. A company with valuable proprietary systems may need its own counsel to prepare terms. Neither situation benefits from pretending that a template guarantees protection in every jurisdiction.</p>
4682
4683<table>
4684  <thead><tr><th>Clause topic</th><th>Practical question to settle</th></tr></thead>
4685  <tbody>
4686    <tr><td>Confidential information</td><td>Does it expressly cover the EX4, recovered source, reports, parameters, and supporting material?</td></tr>
4687    <tr><td>Permitted purpose</td><td>Is use limited to the named assessment, recovery, or maintenance task?</td></tr>
4688    <tr><td>Access group</td><td>Who may view the material, and are staff or subcontractors held to equivalent obligations?</td></tr>
4689    <tr><td>Security measures</td><td>What protection is expected for storage, transmission, authentication, and device access?</td></tr>
4690    <tr><td>Retention and deletion</td><td>How long may copies remain, what backups are excepted, and how is deletion confirmed?</td></tr>
4691    <tr><td>Incident handling</td><td>Who is notified if there is suspected unauthorised access, and how promptly?</td></tr>
4692    <tr><td>Ownership</td><td>Does the agreement avoid transferring rights simply because a party receives a copy?</td></tr>
4693    <tr><td>Output delivery</td><td>Which recipient and channel are authorised to receive recovered material?</td></tr>
4694  </tbody>
4695</table>
4696
4697<p>Terms should be read, not merely signed. For example, a deletion promise may reasonably preserve limited records required by law or routine encrypted backups for a defined cycle. That is different from indefinite use of a file for unrelated testing. Ask what operationally happens, who has access, and whether the answer matches the sensitivity of the code.</p>
4698
4699<p>Where a professional service is being evaluated, the service at ForexMQ5 can be assessed as one option for an authorised recovery request. The owner should still ask direct questions about confidentiality, transfer, access, output delivery, and retention before proceeding. No vend
4699or statement replaces the requester’s responsibility to confirm their rights and provide only what is necessary.</p>
4700
4701<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
4702  <h3 style="margin-top:0;">Preparing an Authorised Recovery Request?</h3>
4703  <p>Owners can review ForexMQ5 as a specialist option after documenting authority, scope, and confidential handling requirements.</p>
4704  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
4705</div>
4706
4707<h2 id="prepare-the-package">Prepare a Minimal Transfer Package</h2>
4708
4709<p>Packaging is the point where a good policy becomes a repeatable action. Make a working directory that contains only approved material. Name files so the recipient can identify them without revealing sensitive strategy details in a public-looking filename. For example, an internal reference number and version label may be safer than a client name or a claim about profitability.</p>
4710
4711<p>Record a cryptographic hash of the original and of the transfer copy. A hash is not secrecy, but it is useful evidence that the received file is the file that was approved. Put the hash in a separate project note or share it through an agreed channel. If the recipient reports a mismatch, stop and resolve it rather than assuming an attachment was altered harmlessly.</p>
4712
4713<h3>Pre-transfer checklist</h3>
4714<ul>
4715  <li>Keep an untouched original in controlled storage.</li>
4716  <li>Make a transfer copy and calculate its checksum.</li>
4717  <li>Remove logs, credentials, personal data, and unrelated project files.</li>
4718  <li>Confirm the recipient name, address, and approved delivery channel independently.</li>
4719  <li>Write the task scope and expected output in the project record.</li>
4720  <li>Decide who may hold the decryption password and who may receive the final source.</li>
4721  <li>Set a review date for deleting temporary local copies after confirmation of receipt.</li>
4722</ul>
4723
4724<p>Do not put a password in the same email as the archive it opens. That pattern defeats much of the benefit of encryption if the mailbox is compromised. Likewise, do not depend on a file name such as “private” to communicate handling rules. Instructions should be explicit and delivered through a channel already verified with the recipient.</p>
4725
4726<h2 id="encrypted-transfer">Choose an Encrypted Delivery Channel</h2>
4727
4728<p>Encryption in transit protects data while it moves between endpoints, but the practical choice still matters. A reputable platform may use encrypted connections while retaining files in an account with broad sharing permissions. A password-protected archive may be strong or weak depending on the encryption method and the password. A secure process combines appropriate technology with recipient verification, limited access, and separate transmission of secrets.</p>
4729
4730<p>For a single file, an encrypted archive can be practical when both parties understand how to use it. Use a long, unique passphrase and a modern archive format with encryption rather than assuming every ZIP password provides equivalent protection. Send the archive through the agreed channel, then communicate the passphrase through a separate verified route, such as a known phone number or an established secure messenger. Never reuse a passphrase from an unrelated project.</p>
4731
4732<p>For larger or ongoing work, a restricted file-sharing workspace may offer better control. Look for individual accounts, multi-factor authentication, access expiration, download visibility where available, and the ability to revoke a recipient. Confirm whether shared links are public, whether forwarding is possible, and whether the service stores data in locations that matter to the owner’s contractual obligations. “Anyone with the link” is rarely suitable for proprietary code.</p>
4733
4734<table>
4735  <thead><tr><th>Method</th><th>Useful when</th><th>Controls to verify</th></tr></thead>
4736  <tbody>
4737    <tr><td>Encrypted archive plus separate passphrase</td><td>One small, defined handover</td><td>Strong unique passphrase, verified second channel, recipient confirmation</td></tr>
4738    <tr><td>Restricted file-sharing workspace</td><td>Several files or a staged project</td><td>Named accounts, multi-factor authentication, expiry, revoked access after completion</td></tr>
4739    <tr><td>Managed secure portal</td><td>Provider has a documented intake system</td><td>Correct domain, account identity, encryption, retention terms, download permissions</td></tr>
4740    <tr><td>Ordinary email attachment</td><td>Rarely appropriate for sensitive code</td><td>Avoid as the sole control, especially for unencrypted binaries or passwords</td></tr>
4741  </tbody>
4742</table>
4743
4744<p>Verify destination details before upload. Phishing messages can imitate a provider, change one character in a domain, or request that a file be sent to a new address. Use contact information obtained from a trusted source, not just a link in an unexpected message. If delivery instructions change, confirm the change through an existing verified contact before acting.</p>
4745
4746<h2 id="access-controls">Control Access During the Work</h2>
4747
4748<p>Transfer security is only the first boundary. The owner should understand how access is limited once the binary arrives. The most important principle is least privilege: each person receives only the material and permissions required for their task. A person preparing an intake record does not necessarily need access to recovered source. A reviewer may 
4748need a report but not a copy of the original binary.</p>
4749
4750<p>Ask practical questions rather than relying on broad assurances. Is work performed on accounts protected by individual credentials? Are devices encrypted and locked? Is remote access controlled? Can a subcontractor receive the file? Is personal storage prohibited? Is access removed when the task ends? The appropriate answers depend on the project, but vague answers are a reason to slow down.</p>
4751
4752<p>There is also a customer-side responsibility. Limit internal distribution. Avoid forwarding the archive to a group mailbox, placing output in a shared chat, or leaving it on a desktop used by several people. Designate one owner for approvals and one secure location for records. If several engineers need to review recovered MQ4, grant access individually and keep a current list of recipients.</p>
4753
4754<h3>Example access map</h3>
4755<p>A small firm might assign an operations manager as approval owner, a technical lead as recipient of the source, and an external specialist as processor for the defined recovery task. The operations manager holds the agreement and authority record. The technical lead receives the output through an encrypted channel and tests it in a separated environment. The specialist receives the minimum input, not account credentials or unrelated repositories. This simple division makes accidental sharing less likely and clarifies who should respond to a delivery question.</p>
4756
4757<h2 id="recovery-output">Secure the Recovered Output</h2>
4758
4759<p>Recovered MQ4 can be more sensitive than the EX4 because it is designed to be readable and editable. Treat delivery as a new confidential handover, not the casual end of a ticket. Agree on the output format, recipient identity, encryption method, and confirmation process before work begins. If a report, notes, or dependency list accompany the source, include them in the confidentiality plan as well.</p>
4760
4761<p>On receipt, verify the sender, archive integrity, and expected file list. Store the result in a private repository or encrypted controlled folder with individual access rather than copying it into a broad team drive. Create a backup under the owner’s control, then decide whether any temporary transfer archive can be deleted. Source should not be compiled or put on a live trading account until it has undergone technical review and testing.</p>
4762
4763<p>Output quality and safety are separate questions. A recovered project may need cleanup, identification of missing dependencies, and a line-by-line review before it behaves predictably. For that next phase, the site’s guide to <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating recovered MQL4 before live deployment</a> is a useful companion. Its testing focus should not be read as a guarantee of strategy performance or as permission to use code beyond the owner’s rights.</p>
4764
4765<p>At closeout, ask for a written confirmation of the agreed deletion or return process. Be specific about what “deleted” means: working copies, temporary folders, and accessible workspace files may be addressed differently from routine backups. If a provider needs to retain a minimal invoice or task record, that is not necessarily a concern, but the owner should know what remains and why.</p>
4766
4767<h2 id="decision-workflow">A Practical Decision Workflow</h2>
4768
4769<ol>
4770  <li><strong>Classify the request.</strong> Is this the owner’s lost source, an authorised maintenance task, or a request involving a third-party commercial EA? Stop if authority cannot be established.</li>
4771  <li><strong>Set the minimum outcome.</strong> Choose assessment, reconstruction, compatibility review, or repair. Do not use an undefined request that invites unnecessary inspection.</li>
4772  <li><strong>Choose the approval owner.</strong> Identify the person who can confirm rights, scope, recipient list, and spending authority.</li>
4773  <li><strong>Document confidentiality expectations.</strong> Use an appropriate written agreement or written handling confirmation before transfer.</li>
4774  <li><strong>Build a clean package.</strong> Include the approved EX4 and limited context, exclude credentials and unrelated data, and record hashes.</li>
4775  <li><strong>Select two channels.</strong> Use one controlled route for the encrypted file and another verified route for the passphrase or identity confirmation.</li>
4776  <li><strong>Confirm receipt and scope.</strong> Obtain acknowledgement of the exact file and task before analysis proceeds.</li>
4777  <li><strong>Control output delivery.</strong> Send readable source only to the named recipient, then store, test, and retain it under internal 
4777controls.</li>
4778  <li><strong>Close the project.</strong> Revoke sharing access, remove temporary copies, record deletion commitments, and preserve the authority record.</li>
4779</ol>
4780
4781<p>This workflow is intentionally conservative. It may feel slower than attaching a file to a message, but it is usually easier than responding to a mistaken disclosure after the fact. It also makes a professional conversation more efficient because both parties understand the purpose, materials, and boundary of the work.</p>
4782
4783<h2 id="common-failures">Common Confidentiality Failures</h2>
4784
4785<p><strong>Failure: treating a signed NDA as the whole security plan.</strong> An agreement is important, but it does not encrypt an attachment, verify an address, or remove broad folder permissions. Pair written obligations with concrete handling controls.</p>
4786
4787<p><strong>Failure: providing a full MT4 data folder “just in case.”</strong> This can add account information, logs, and other protected files to the disclosure. Begin with the exact EX4 and add a dependency only when the technical need is identified.</p>
4788
4789<p><strong>Failure: using the same email for the archive and password.</strong> A compromised inbox can yield both. Separate the file transfer from the secret and verify the second channel.</p>
4790
4791<p><strong>Failure: sharing a public cloud link.</strong> A link may be forwarded, indexed, or remain active longer than intended. Use named access, expiry, and revocation where possible.</p>
4792
4793<p><strong>Failure: accepting changed delivery details without verification.</strong> A convincing request to use a different address may be a simple impersonation attempt. Confirm through an already trusted contact route.</p>
4794
4795<p><strong>Failure: forgetting the output is the sensitive asset.</strong> Recovered source copied into a team chat or an unrestricted repository can defeat every precaution taken during intake. Plan output storage and recipient access before recovery begins.</p>
4796
4797<p><strong>Failure: mistaking confidentiality for authorisation.</strong> Secure transmission protects a file from casual exposure. It does not grant a licence to inspect, reproduce, modify, or distribute code. Keep the rights record alongside the security checklist.</p>
4798
4799<h2 id="conclusion">Conclusion: Treat Recovery as a Controlled Project</h2>
4800
4801<p>Proprietary EX4 recovery deserves the same care as any transfer of valuable source code. The strongest practical approach begins with authority and a narrow purpose, then uses a written confidentiality framework, a minimal encrypted package, verified recipients, restricted access, and an agreed output handover. Each layer addresses a different failure point. None is perfect alone, but together they make accidental disclosure and misunderstanding less likely.</p>
4802
4803<p>For an owner considering an <a href="/">ex4 to mq4 decompiler</a> path, the useful question is not merely whether source can be recovered. It is whether the project can be authorised, scoped, transferred, performed, and closed without exposing more than necessary. A final review of rights, channel, recipient, and retention before upload is a small step that can protect a trading business long after the technical work is complete.</p>
4804
4805<p>Where the need is legitimate but the process is unclear, pause and document the unanswered questions. A careful provider assessment and a controlled delivery plan are preferable to rushing proprietary code through a convenient but unverified channel.</p>
4806`},{slug:"recovered-mql4-code-acceptance-checklist",title:"Recovered MQL4 Code Acceptance Checklist: Verify Delivery Before Sign-Off",metaTitle:"Recovered MQL4 Code Acceptance Checklist Before Sign-Off",metaDescription:"Use a practical acceptance checklist to verify recovered MQL4 delivery files, compilation, dependencies, behavior comparisons, test evidence, and approval records.",keywords:"recovered MQL4 code acceptance checklist, MQ4 delivery verification, EX4 recovery sign-off, MQL4 compile test, recovered EA behavior comparison",excerpt:"Recovered MQ4 source should be accepted as a documented engineering delivery, not merely because a file arrived. This checklist helps owners verify the package, compile result, dependencies, behavior evidence, and approval decision before sign-off.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:Fs,imageAlt:"reviewer checking a recovered MQL4 delivery package before approval",tableOfContents:[{id:"acceptance-purpose",title:"What Acceptance Actually Confirms"}
4806,{id:"before-delivery",title:"Set the Acceptance Baseline Before Opening Files"},{id:"package-inventory",title:"Inspect the Delivery Package"},{id:"compile-test",title:"Run a Reproducible Compile Test"},{id:"dependency-review",title:"Map Dependencies and Operating Assumptions"},{id:"behavior-comparison",title:"Compare Behavior Without Chasing Perfect Charts"},{id:"defect-triage",title:"Classify Findings and Decide What Must Change"},{id:"approval-record",title:"Complete the Approval Record"},{id:"handover",title:"Preserve a Maintainable Handover"},{id:"questions",title:"Acceptance Questions"},{id:"conclusion",title:"Conclusion"}],content:`
4807<p>Receiving recovered MQL4 code is a useful milestone, but it is not the same thing as accepting a finished engineering delivery. A readable MQ4 file can arrive with missing includes, generic names, warnings, unstated assumptions, or behavior that has not yet been compared with the original EX4. Owners who sign off at that point may later discover that nobody can rebuild the file, reproduce the test, or explain which version was approved.</p>
4808
4809<p>This independent review guide describes a practical acceptance process for an authorised recovery or maintenance project. It is written for the person responsible for deciding whether delivery is complete, whether further work is needed, and what evidence should accompany approval. It does not assume that every recovered source file can reproduce every historical detail. Compilation removes context, and recovery can require interpretation. The aim is a defensible, useful delivery decision rather than an unrealistic claim of perfect restoration.</p>
4810
4811<img src="${Fs}" alt="reviewer checking a recovered MQL4 delivery package before approval" style="width:100%;border-radius:8px;margin:24px 0;" />
4812
4813<p>A disciplined approach also keeps roles clear. This site reviews ForexMQ5 as a possible professional option for legitimate EX4 recovery needs; it does not perform recovery work itself. The owner remains responsible for confirming authority to use the code, defining the intended use, and approving the final package. A reviewer can ask better questions when the acceptance criteria are prepared before the recovered files are opened.</p>
4814
4815<h2 id="acceptance-purpose">What Acceptance Actually Confirms</h2>
4816
4817<p>Acceptance is a statement about evidence, scope, and remaining risk. It should confirm that the requested artifacts were received, can be identified, and meet the agreed technical criteria. It should not silently certify things nobody tested, such as future profitability, suitability for a particular broker, or legal rights that were never reviewed. A concise acceptance record is more valuable when it states both what was verified and what was not.</p>
4818
4819<p>For recovered MQL4, a sound sign-off normally answers five questions:</p>
4820
4821<ol>
4822<li><strong>Is the package complete?</strong> The recipient has the recovered source, original binary reference, build output, dependency list, settings, and supporting notes promised in the scope.</li>
4823<li><strong>Can the source compile in the recorded environment?</strong> A named person can follow documented steps and obtain the expected result, with errors and warnings recorded rather than hidden.</li>
4824<li><strong>Is the file understandable enough to maintain?</strong> Important inputs, files, custom indicators, DLL calls, symbol assumptions, and control points are identified, even where original names cannot be known.</li>
4825<li><strong>Has observed behavior been compared responsibly?</strong> Test cases compare relevant actions and conditions between the EX4 baseline and recovered build without treating one favorable backtest as proof.</li>
4826<li><strong>Is the approval decision explicit?</strong> The owner accepts, accepts with listed limitations, requests correction, or defers deployment. No one should infer approval from a casual email.</li>
4827</ol>
4828
4829<p>This distinction is especially important for trading software. A clean compile demonstrates syntax and dependencies in one environment. It does not prove that position sizing, stop placement, session filters, or error handling match an unknown original under every market condition. Readers needing broader background on the recovery process can review the site's <a href="/">ex4 to mq4 decompiler</a> overview before using this checklist as the delivery stage.</p>
4830
4831<h2 id="before-delivery">Set the Acceptance Baseline Before Opening Files</h2>
4832
4833<p>The best time to define acceptance is before delivery, not after a reviewer has become attached to a promising result. Start with a short scope note. It can be one page, but it should identify the original EX4, the intended recovered output, the authorised purpose, the testing environment, and the person with authority to decide. If the original file is available, calculate and record a checksum or another stable identifier. Preserve an untouched copy in a separate folder.</p>
4834
4835<p>Next, distinguish requirements from preferences. A requirement might be that the recovered EA compiles in a named MetaEditor version with all supplied dependencies present. A preference might be that variables are renamed for readability. Both matter, but a reviewer should not reject a technically complete recovery merely because recovered identifiers remain generic, unless readable naming was part of the agreed scope.</p>
4836
4837<table>
4838<thead><tr><th>
4838Baseline item</th><th>Record before review</th><th>Why it matters</th></tr></thead>
4839<tbody>
4840<tr><td>Original artifact</td><td>Filename, size, location, checksum, source of file</td><td>Prevents a later comparison against the wrong EX4</td></tr>
4841<tr><td>Requested output</td><td>EA, indicator, script, include files, or full project</td><td>Defines what delivery must contain</td></tr>
4842<tr><td>Known environment</td><td>MT4 build, broker, symbol naming, timeframe, test dates</td><td>Explains conditions that affect behavior</td></tr>
4843<tr><td>Known settings</td><td>Set file, inputs, magic number, chart details</td><td>Allows a repeatable test case</td></tr>
4844<tr><td>Decision owner</td><td>Name, role, and approval authority</td><td>Avoids informal or conflicting sign-off</td></tr>
4845</tbody>
4846</table>
4847
4848<p>The scope should name exclusions too. For example, it may say that the task is source recovery and compilation only, not strategy redesign, broker migration, performance optimization, licence removal, or live deployment. Exclusions protect both sides from a common misunderstanding: a recovered file is an engineering starting point, not an automatic replacement for all historical operations.</p>
4849
4850<h2 id="package-inventory">Inspect the Delivery Package</h2>
4851
4852<p>Do not begin by double-clicking the MQ4. First inventory the package. A complete delivery is easier to protect and evaluate when files are arranged predictably. Create a read-only archive of what arrived, then work from a copied review directory. Record the delivery date and any transfer reference. If the package was compressed, retain the original archive as received.</p>
4853
4854<p>A practical inventory separates artifacts into four groups: original evidence, recovered source, build dependencies, and review records. The source group might contain an MQ4 and included MQH files. Dependency material may include custom indicators, libraries, templates, set files, CSV inputs, or installation instructions. Review records could include a compile log, known limitations, and a change note describing manual corrections.</p>
4855
4856<h3>Package acceptance checklist</h3>
4857
4858<ul>
4859<li>The original EX4 is present or its stable identifier and storage location are recorded.</li>
4860<li>Each delivered MQ4, MQH, EX4, indicator, library, and configuration file has a clear name and location.</li>
4861<li>A short manifest lists every item and its purpose.</li>
4862<li>The source opens as readable text without unexplained corruption or password protection.</li>
4863<li>Any edits made after initial recovery are identified separately from raw recovery output.</li>
4864<li>Required external resources are supplied or explicitly listed as unavailable.</li>
4865<li>Instructions identify the expected Experts, Indicators, Include, Libraries, and Files locations.</li>
4866<li>Known limitations, unresolved functions, and assumptions are written down.</li>
4867</ul>
4868
4869<p>Pay particular attention to the boundary between raw output and modified output. If someone added declarations, corrected a typo, renamed variables, or reorganised functions to make the source compile, that can be entirely reasonable. The package should still reveal what changed. A reviewer needs to know whether a difference arises from recovery, a compilation fix, or later strategy work. Version labels such as raw-recovery, compile-fix-01, and reviewed-candidate are more useful than a sequence of files named final.</p>
4870
4871<p>Missing items do not always mean rejection. An EA may not use any external dependency. A missing set file may be recoverable from a documented input card. The correct response is to log the gap and judge whether it prevents the stated acceptance test. If an undisclosed DLL or custom indicator is essential to initialization, the package is incomplete for reproducible delivery even if the main MQ4 looks polished.</p>
4872
4873<h2 id="compile-test">Run a Reproducible Compile Test</h2>
4874
4875<p>Compilation is the first technical gate, but it should be repeatable. Use a clean or documented test installation rather than a terminal full of unexplained legacy files. Note the MetaEditor and terminal build, operating system, source path, dependency locations, and whether any existing compiled artifacts were removed before the test. This avoids a fal
4875se pass caused by an old EX4 or include file already sitting in the folders.</p>
4876
4877<p>Compile the delivered source exactly as instructed. Save the compiler output as text or screenshots, including zero-error results and every warning. Then repeat the build from the archived review copy if practical. The second pass checks that the result was not dependent on an unsaved local edit. Where a warning remains, do not automatically treat it as harmless. Read the line, identify its type, and decide whether it affects the intended use.</p>
4878
4879<table>
4880<thead><tr><th>Result</th><th>Acceptance response</th><th>Example</th></tr></thead>
4881<tbody>
4882<tr><td>Compile error</td><td>Block acceptance until corrected or scope is changed</td><td>Undefined custom indicator call</td></tr>
4883<tr><td>Warning with understood impact</td><td>Log it and obtain reviewer decision</td><td>Possible data-loss conversion in a display value</td></tr>
4884<tr><td>Warning affecting trade logic</td><td>Investigate before approval</td><td>Unchecked return from an order operation</td></tr>
4885<tr><td>Zero errors, zero warnings</td><td>Proceed to runtime checks</td><td>Useful evidence, not final proof</td></tr>
4886</tbody>
4887</table>
4888
4889<p>A compile notebook should include the source revision, compiler version, date, operator, result, output filename, and any manual action. If the reviewer adds a missing semicolon or adjusts an include path, that is a change to record, not a private convenience. The final approval should identify the exact candidate that was compiled, preferably by archive name and checksum.</p>
4890
4891<p>For a deeper explanation of why an EX4 cannot simply retain all source-level context, see the related guide on <a href="/blog/mql4-to-ex4-compilation-explained">how MQL4 becomes an EX4 during compilation</a>. That limitation is why acceptance focuses on reproducible evidence and observed behavior rather than promises about original comments or variable names.</p>
4892
4893<h2 id="dependency-review">Map Dependencies and Operating Assumptions</h2>
4894
4895<p>Many delivery failures occur after a successful compile. The EA attaches but does nothing, initializes incorrectly, or produces different values because the operating context was never captured. Review dependencies as a system map. Search the source for include directives, custom indicator calls, file access, global variables, DLL imports, web requests, symbol strings, timeframe references, and account checks. Ask whether each item is delivered, configured, permitted, and safe to test.</p>
4896
4897<p>Symbol and broker assumptions deserve special attention. A recovered EA might refer to EURUSD while the terminal exposes EURUSD.a. It may calculate pip values from a particular digit count, expect a fixed server time, or use a spread threshold that is unsuitable in another environment. These are not necessarily code defects. They are conditions that must be named before behavior can be fairly compared.</p>
4898
4899<h3>Dependency map questions</h3>
4900
4901<ol>
4902<li>Does the EA require custom indicators, and are their exact files included?</li>
4903<li>Are include files local, standard, or missing from the package?</li>
4904<li>Does it read a file, use terminal global variables, or expect a preset input?</li>
4905<li>Are DLL or web permissions required, and is their purpose documented?</li>
4906<li>Which symbol, suffix, timeframe, server time, and account conditions are assumed?</li>
4907<li>Does it use a magic number or order comment that could conflict with another EA?</li>
4908<li>What happens if a dependency is absent or a trade operation fails?</li>
4909</ol>
4910
4911<p>Use a safe test environment for this review. Never enable unknown DLLs, web requests, or trade permissions merely to get past an initialization screen. First establish why they are called and whether the owner has authorised the test. If a dependency cannot be obtained, label the relevant scenario unverified. Honest incompleteness is better than an invented substitute that changes behavior.</p>
4912
4913<h2 id="behavior-comparison">Compare Behavior Without Chasing Perfect Charts</h2>
4914
4915<p>Behavior comparison is the central acceptance activity. It asks whether the compiled recovered candidate behaves consistently with the original EX4 under selected, controlled conditions. It is not a search for the most attractive equity curve. A tester who keeps changing inputs, data periods, or code until results look good can conceal a material difference rather than resolve it.</p>
4916
4917<p>Start with a comparison matrix. Choose a small number of scenarios that exercise the functions relevant to the stated purpose. For an EA, include initialization, no-trade conditions, a qualifying entry, position sizing, stop and target placement, modification logic, exit logic, and handling of a rejected trade where feasible. For an indicator, compare initialization, buffer values, drawing behavior, and response to new bars. Record the same inputs, symbol, timeframe, historical data source, and test interval for both artifacts.</p>
4918
4919<table>
4920<thead><tr><th>
4920Observation</th><th>Compare</th><th>Evidence to save</th></tr></thead>
4921<tbody>
4922<tr><td>Initialization</td><td>Messages, visible objects, input validation, failure state</td><td>Journal extract and chart screenshot</td></tr>
4923<tr><td>Signal timing</td><td>Bar or tick where a condition becomes true</td><td>Timestamped test note</td></tr>
4924<tr><td>Orders</td><td>Direction, volume, comment, magic number, count</td><td>Statement or tester report</td></tr>
4925<tr><td>Risk controls</td><td>Stop loss, take profit, trailing, maximum exposure</td><td>Order details and code reference</td></tr>
4926<tr><td>Exit handling</td><td>Close condition, modification, retry behavior</td><td>Log and selected trade examples</td></tr>
4927</tbody>
4928</table>
4929
4930<p>A difference needs diagnosis before it becomes a verdict. It may come from different data, spread modelling, terminal build, symbol suffix, a missing dependency, an uninitialised value, or a genuine reconstruction issue. Isolate one condition at a time. Verify that both versions received the same inputs. Check the journal. Inspect the code path around the observed decision. Then classify the result as explained, unresolved, or corrected and retested.</p>
4931
4932<p>Do not equate a matching backtest balance with matching logic. Two systems can arrive at similar totals while placing different trades or managing risk differently. Conversely, a small difference in a report may be explained by quotes or modelling choices while the important logic aligns. The goal is a reasoned comparison of relevant actions. The related article on <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">validating a recovered MQL4 EA before live deployment</a> offers a useful next-stage testing framework after package acceptance.</p>
4933
4934<p>Use a demo or isolated environment before any live consideration. Acceptance of recovery output does not require live trading, and a live account is a poor diagnostic tool. If the owner later chooses deployment, that should be a separate decision with broker, risk, and operational checks. No checklist can guarantee future trading results.</p>
4935
4936<h2 id="defect-triage">Classify Findings and Decide What Must Change</h2>
4937
4938<p>Not every finding deserves the same response. Triage keeps sign-off from becoming either careless approval or endless polishing. Give each issue an identifier, a clear observation, reproduction steps, evidence, severity, owner, and status. Avoid labels such as looks wrong. A better record says that with a stated input set on a named symbol and date range, the recovered candidate calculated a different volume than the EX4 baseline.</p>
4939
4940<ul>
4941<li><strong>Blocking:</strong> The source will not compile, an essential dependency is missing, the file performs an unexplained trade action, or a required function cannot be tested.</li>
4942<li><strong>Material:</strong> Behavior differs in a way that could affect intended operation, risk controls, compatibility, or maintainability. Correction or a written scope decision is needed.</li>
4943<li><strong>Minor:</strong> A comment, naming issue, cosmetic warning, or documentation omission does not prevent intended testing but should be scheduled or noted.</li>
4944<li><strong>Observation:</strong> A condition is outside the agreed scope, such as a broker-specific setting to investigate during deployment planning.</li>
4945</ul>
4946
4947<p>The approval options should be equally explicit. Accept when all required criteria pass and evidence is archived. Accept with limitations when defined non-blocking items are disclosed and the owner agrees they do not prevent the stated use. Return for correction when a blocking or material issue remains. Defer when evidence is insufficient, perhaps because a necessary dependency or reliable baseline cannot be obtained. Deferral is a valid outcome, not a failure to make a decision.</p>
4948
4949<h2 id="approval-record">Complete the Approval Record</h2>
4950
4951<p>Sign-off should fit on a clear record that another maintainer can understand. Identify the project, delivery version, original artifact reference, review environment, tests run, results, open issues, decision, and approver. Attach or link the manifest, compile log, comparison matrix, and any correction history. The record should not claim that the site or provider guarantees the system. It should say what the owner reviewed and accepted.</p>
4952
4953<h3>Example approval wording</h3>
4954
4955<p>The recovered candidate identified in the attached manifest compiled in the recorded MetaEditor environment with the documented warning status. The reviewer completed the listed initialization and behavior comparisons using the stated inputs and test data. The package is accepted for authorised maintenance evaluation, subject to the listed broker-symbol mapping limitation. This approval does not authorise live deployment, redistribution, removal of licence controls, or use outside the recorded scope.</p>
4956
4957<p>This wording is intentionally narrow. It prevents a handover note from being mistaken for a performance promise or a blanket rights statement. If the project has contractual, ownership, or regulatory implications, the owner should seek appropriate qualified advice rather than relying on a technical acceptance form.</p>
4958
4959<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
4960  <h3 style="margin-top:0;">Considering a Professional Recovery Route?</h3>
4961  <p>ForexMQ5 is reviewed as a specialist option for owners with a legitimate recovery need. A clear scope, original-file record, and acceptance plan help make any delivery easier to evaluate.</p>
4962  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
4963</div>
4964
4965<h2 id="handover">Preserve a Maintainable Handover</h2>
4966
4967<p>After acceptance, archive the evidence so the next change does not restart the investigation. Keep the untouched original EX4, raw recovery output, accepted source, compiled output, manifest, compiler record, dependencies, test inputs, comparison evidence, and approval note. Restrict access to people who need it and preserve a simple change log. Source that can compile today but cannot be traced six months later is not a fully maintainable asset.</p>
4968
4969<p>Create one short handover note explaining how to rebuild and test the accepted candidate. Include folder placement, permissions, expected inputs, known limitations, and the location of the rollback artifact. When a future developer changes logic, branch or copy from the accepted version rather than overwriting it. This keeps recovery evidence distinct from ordinary maintenance.</p>
4970
4971<p>For owners preparing a broader archive, the site's <a href="/">mql4 decompiler</a> resource can help frame recovery within a controlled maintenance process. The important principle remains simple: preserve the original, identify each derivative, and document the evidence behind each decision.</p>
4972
4973<h2 id="questions">Acceptance Questions</h2>
4974
4975<h3>Is zero compiler warnings mandatory?</h3>
4976<p>Not always. A warning should be read, recorded, and assessed in context. Some may be harmless for the agreed test, while others can point to a type, return-value, or compatibility problem that deserves correction. The acceptance record should never pretend warnings did not exist.</p>
4977
4978<h3>What if the original EX4 cannot be tested?</h3>
4979<p>Acceptance can still cover package completeness and reproducible compilation, but behavior equivalence cannot be confirmed against that baseline. State this limitation plainly. Use available specifications, historical logs, or known inputs as secondary evidence without claiming they prove identical operation.</p>
4980
4981<h3>Can an owner approve code before every possible scenario is tested?</h3>
4982<p>Yes, if approval is scoped to the completed tests and known limitations. No finite test set covers every market condition. The decision should identify which functions were exercised, which were not, and whether more testing is required before a separate deployment decision.</p>
4983
4984<h3>Does acceptance permit modifying or sharing the source?</h3>
4985<p>No. Technical acceptance is separate from ownership, licence, confidentiality, and distribution rights. The owner should rely on their agreements and applicable law for those questions.</p>
4986
4987<h2 id="conclusion">Conclusion</h2>
4988
4989<p>A recovered MQL4 file deserves the same care as any important software delivery. Inventory the artifacts, compile in a recorded environment, map dependencies, compare observable behavior, triage differences, and make the approval decision explicit. This approach does not promise a perfect historical reconstruction, and it does not turn untested code into a live-ready system. It does give the owner a clear basis for deciding whether the delivered source is complete enough for its authorised purpose and maintainable enough for the next responsible step.</p>
4990  `},{slug:"mql4-event-handlers-explained",title:"MQL4 Event Handlers Explained: OnInit, OnTick, OnTimer, and OnDeinit",metaTitle:"MQL4 Event Handlers Explained: OnInit, OnTick, OnTimer, and OnDeinit",metaDescription:"Understand the MQL4 Expert Advisor event flow. Learn what OnInit, OnTick, OnTimer, and OnDeinit do, how they connect, and how to review each stage safely.",keywords:"MQL4 event handlers, OnInit MQL4, OnTick MQL4, OnTimer MQL4, OnDeinit MQL4, MQL4 Expert Advisor event flow, MT4 EA code review",excerpt:"A practical guide to the four event handlers that give an MQL4 Expert Advisor its lifecycle. Follow the flow from startup to ticks, scheduled work, and clean shutdown with review questions and code examples.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:Du,imageAlt:"four stage MQL4 Expert Advisor event flow diagram showing initialization, tick processing, timer work, and shutdown",tableOfContents:[{id:"why-event-flow-matters",title:"Why an EA Event Flow Matters"},{id:"four-stage-map",title:"The Four Stage Event Map"}
4990,{id:"oninit",title:"Stage One: OnInit Sets the Contract"},{id:"ontick",title:"Stage Two: OnTick Handles Market Arrival"},{id:"ontimer",title:"Stage Three: OnTimer Handles Scheduled Work"},{id:"ondeinit",title:"Stage Four: OnDeinit Leaves Cleanly"},{id:"sequence",title:"How Events Interact in Practice"},{id:"review-method",title:"A Code Review Method for Recovered EAs"},{id:"examples",title:"Patterns, Mistakes, and Safer Choices"},{id:"testing",title:"Testing the Lifecycle Before Use"},{id:"conclusion",title:"A Better Way to Read EA Behavior"}],content:`
4991<p>An MQL4 Expert Advisor does not run as one long script from top to bottom. MetaTrader calls named functions when something relevant happens. A chart receives a new price quote. A timer interval expires. The program is attached, recompiled, removed, or its inputs change. Those events form the EA's operating rhythm.</p>
4992
4993<p>For someone reading a custom or recovered EA, the event handlers are the quickest route to understanding that rhythm. They reveal what must be ready before the robot acts, what it evaluates when the market changes, what it performs on a schedule, and what it tries to clean up at the end. That makes them more useful than a random tour through helper functions or a list of global variables.</p>
4994
4995<p>This guide explains the familiar four stage flow: <strong>OnInit</strong>, <strong>OnTick</strong>, <strong>OnTimer</strong>, and <strong>OnDeinit</strong>. It focuses on the modern MQL4 event model used by Expert Advisors, not on promises about profitability or an invitation to run unknown code. A handler can explain software behavior, but its trading logic still needs careful validation.</p>
4996
4997<p>Readers new to the file types behind an MT4 robot can first review <a href="/blog/mql4-to-ex4-compilation-explained">how MQL4 becomes an EX4 file</a>. That background helps explain why readable source is valuable when a trader needs to inspect lifecycle decisions instead of treating an EA as a black box.</p>
4998
4999<img src="${Du}" alt="four stage MQL4 Expert Advisor event flow diagram showing initialization, tick processing, timer work, and shutdown" style="width:100%;border-radius:8px;margin:24px 0;" />
5000
5001<h2 id="why-event-flow-matters">Why an EA Event Flow Matters</h2>
5002
5003<p>An Expert Advisor is event driven. It waits until the terminal gives it a reason to run, then it completes the applicable handler. It is not guaranteed to examine every tiny movement in the market, and it does not continuously execute in the background in the way a beginner might imagine. Understanding that constraint changes how a reviewer reads nearly every trading decision.</p>
5004
5005<p>Suppose an EA checks for a moving average crossover in OnTick. Its opportunity to detect that condition depends on price ticks arriving for the chart symbol. If the market is quiet, there may be no calls. If many ticks arrive, the handler may be called often. Now suppose the same EA refreshes a panel or checks a once-per-minute maintenance condition in OnTimer. That work has a separate trigger and should not be confused with quote processing.</p>
5006
5007<p>The separation creates useful questions. Is a price-sensitive decision placed in OnTick? Is a periodic housekeeping task placed in OnTimer? Does startup reject an invalid configuration before orders can be considered? Does removal clear objects and release resources without accidentally changing trading state? The answers are evidence of the author's design choices.</p>
5008
5009<p>Event flow also helps locate faults. An EA that never opens a trade may have a valid signal function that is never reached. An EA that opens repeated orders may evaluate the same condition on every incoming quote without a new-bar guard. A timer task may fail because the timer was never registered. These are lifecycle problems, distinct from whether a strategy's entry rule is sensible.</p>
5010
5011<h3>A practical boundary</h3>
5012
5013<p>MetaTrader invokes these handlers in the context of one program attached to one chart. OnTick is associated with ticks for that chart's symbol. A robot can inspect other symbols through MQL4 functions, but receiving an update for another symbol does not itself mean its OnTick handler runs. This distinction matters for multi-symbol designs. A review should look for an intentional refresh plan rather than assume all markets wake the EA equally.</p>
5014
5015<p>Likewise, an event handler is not a license to make a decision on every call. Sound code may return immediately when trading is disabled, a spread condition is outside its stated limit, a position already exists, or the current bar has already been processed. Those gates often tell more about operational behavior than the entry formula 
5015itself.</p>
5016
5017<h2 id="four-stage-map">The Four Stage Event Map</h2>
5018
5019<p>The cleanest mental model is a loop with an entry and an exit. Initialization prepares the EA. Market ticks and timer moments can then trigger work while it remains attached. Deinitialization runs when the terminal ends that attachment or resets the program. The following table turns that model into an inspection map.</p>
5020
5021<table>
5022  <thead><tr><th>Stage</th><th>Typical trigger</th><th>Primary responsibility</th><th>Key review question</th></tr></thead>
5023  <tbody>
5024    <tr><td>OnInit</td><td>EA attachment or reinitialization</td><td>Validate inputs and prepare state</td><td>Can the EA fail safely before trading begins?</td></tr>
5025    <tr><td>OnTick</td><td>A new quote for the chart symbol</td><td>Evaluate current market driven logic</td><td>What stops duplicate or unsuitable actions?</td></tr>
5026    <tr><td>OnTimer</td><td>The timer interval expires</td><td>Perform scheduled, non-tick work</td><td>Was the timer created and is the task bounded?</td></tr>
5027    <tr><td>OnDeinit</td><td>Removal, parameter change, recompile, chart change, or terminal event</td><td>Clean up resources and chart objects</td><td>Does shutdown avoid unintended trades or lost context?</td></tr>
5028  </tbody>
5029</table>
5030
5031<p>Not every EA uses all four handlers. A simple robot may need only OnInit and OnTick. A more complete implementation uses OnTimer for status updates, session checks, or retry logic that should not depend on price activity. OnDeinit is strongly worth having whenever the EA creates chart objects, opens files, allocates indicator handles in compatible code, or starts a timer.</p>
5032
5033<p>Handler signatures matter. In MQL4, the platform recognizes an event handler when its name, return type, and parameters match the expected form. A misspelled function or an extra parameter can become an ordinary unused function rather than a handler. During source review, compare the declaration with the language reference and do not infer that a function runs merely because its name looks familiar.</p>
5034
5035<h2 id="oninit">Stage One: OnInit Sets the Contract</h2>
5036
5037<p>OnInit is the opening checkpoint. It is called when the EA begins and again when a change requires reinitialization. Its task is not to hunt for trades. Its task is to establish whether the EA can operate under the current chart, inputs, terminal settings, and account conditions that its author requires.</p>
5038
5039<p>A robust initialization routine commonly reads user inputs, checks the chart timeframe or symbol assumptions, creates chart labels, initializes tracking variables, and requests timer events where needed. It can also verify that a required indicator setup or trading permission is available. The exact checks vary by strategy, but the underlying principle is stable: reject an unsuitable operating context before the market handler receives control.</p>
5040
5041<pre><code>int OnInit()
5042{
5043   if(FastPeriod &lt;= 0 || SlowPeriod &lt;= FastPeriod)
5044   {
5045      Print("Invalid moving average inputs");
5046      return(INIT_PARAMETERS_INCORRECT);
5047   }
5048
5049   lastProcessedBar = 0;
5050   EventSetTimer(60);
5051   CreateStatusLabel();
5052   return(INIT_SUCCEEDED);
5053}</code></pre>
5054
5055<p>This example has three distinct jobs. It validates a relationship between inputs, establishes a known starting value, and asks the terminal for a 60 second timer. Returning INIT_PARAMETERS_INCORRECT communicates that the chosen inputs do not meet the program's own requirements. Returning INIT_SUCCEEDED permits the EA to proceed. A reviewer should trace what happens on every early return, not just the successful path.</p>
5056
5057<h3>Initialization checklist</h3>
5058
5059<ul>
5060  <li>Confirm that every input used for sizing, timing, or signal calculation is checked for impossible values.</li>
5061  <li>Identify assumptions about the chart symbol, digits, timeframe, and trading permissions.</li>
5062  <li>Look for explicit initialization of counters, ticket references, timestamps, and new-bar markers.</li>
5063  <li>Check whether EventSetTimer is called if an OnTimer function exists.</li>
5064  <li>Note objects, files, or global terminal variables created here, because they need an ownership and cleanup plan.</li>
5065  <li>Read error messages as clues, but verify the surrounding condition rather than trusting a label alone.</li>
5066</ul>
5067
5068<p>There is a subtle but important distinction between configuration and account state. An input such as a magic number can be validated in OnInit. A current open order can change after initialization, so a safe EA normally checks it again when it acts. Initialization is a foundation, not a substitute for live checks.</p>
5069
5070<p>Recovered code sometimes initializes variables in several places because original formatting or structure was lost. In that case, make a table of each global variable, its default value, its assigned value in OnInit, and its first use in OnTick. This small exercise can expose a counter that is never reset or an assumed ticket value that is actually zero.</p>
5071
5072<h2 id="ontick">Stage Two: OnTick Handles Market Arrival</h2>
5073
5074<p>OnTick is where many readers begin, because order functions and indicator calls frequently appear here. It is better viewed as the market arrival gate. Each new tick for the chart symbol gives the EA an opportunity to inspect the latest available state. It does not compel an order, modify an existing order, or even require a complex calculation.</p>
5075
5076<p>A disciplined OnTick often follows a readable sequence: verify the terminal and spread conditions, refresh prices if necessary, decide whether a new evaluation is due, inspect existing exposure, calculate a signal, then take a bounded action if all gates pass. The order is significant. A strategy should not calculate a trade volume and send an order before it has checked whether trading is permitted or whether an existing position conflicts with the plan.</p>
5077
5078<pre><code>void OnTick()
5079{
5080   if(!IsTradeAllowed())
5081      return;
5082
5083   if(!IsNewBar())
5084      return;
5085
5086   if(HasOpenPosition(Symbol(), MagicNumber))
5087      return;
5088
5089   int signal = GetSignal();
5090   if(signal == OP_BUY)
5091      OpenBuyAfterChecks();
5092   else if(signal == OP_SELL)
5093      OpenSellAfterChecks();
5094}</code></pre>
5095
5096<p>The code is intentionally incomplete. It illustrates that guards are part of the strategy's operational definition. IsNewBar might prevent multiple entries on the same candle. HasOpenPosition might prevent stacking. OpenBuyAfterChecks should still verify pricing, lot constraints, stop levels, and the result of OrderSend. A reviewer should not assume these safeguards exist simply because helper names suggest them.</p>
5097
5098<h3>Ticks are not bars</h3>
5099
5100<p>A recurring source of confusion is the difference between a tick and a completed candle. An EA can receive many ticks while the current bar remains open. If a signal is meant to use a completed bar, the code should explicitly reference the prior bar or use a new-bar detection method. If it uses shift zero indicator values, its signal can change as the current candle develops. That may be intentional, but it should be evident from the design.</p>
5101
5102<p>Reviewers can look for Time[0], iTime, Bars, or a stored timestamp such as lastProcessedBar. Then ask what exactly changes when the condition becomes true. A single stored timestamp may be adequate for one symbol and timeframe but inadequate for a multi-symbol scan. Context determines whether a guard is correct.</p>
5103
5104<h3>Order handling deserves a separate read</h3>
5105
5106<p>OnTick may call an order helper rather than contain OrderSend directly. Follow that call. Check the symbol, command type, volume, price, stop loss, take profit, slippage setting, magic number, comment, and error handling. Then inspect the branch that follows a failed order. A failed request should not be silently treated as a filled trade, and a retry loop should have a clear limit.</p>
5107
5108<p>This is also where a source reviewer should distinguish observable mechanics from claims. Code may show that an EA attempts a specific action under stated conditions. It does not establish that the action will be filled at a particular price, suit a particular account, or produce a future return. Testing in a controlled environment remains necessary.</p>
5109
5110<h2 id="ontimer">Stage Three: OnTimer Handles Scheduled Work</h2>
5111
5112<p>OnTimer exists for jobs that should occur at an interval rather than only when a quote arrives. The interval is typically requested through EventSetTimer in OnInit, and EventKillTimer should later cancel it. This gives an EA a clock of its own while it is attached to the chart.</p>
5113
5114<p>Useful timer jobs include refreshing a chart dashboard, writing a diagnostic snapshot, checking a calendar boundary, scanning a watchlist according to a deliberate schedule, or reporting stale data. A timer can make a quiet market easier to manage, but it is not a shortcut around careful design. If a task sends orders, it still needs the same current checks around price, permissions, exposure, and errors that a tick-driven task needs.</p>
5115
5116<pre><code>void OnTimer()
5117{
5118   UpdateStatusPanel();
5119
5120   if(TimeCurrent() - lastHealthCheck &gt;= 300)
5121   {
5122      LogConnectionState();
5123      lastHealthCheck = TimeCurrent();
5124   }
5125}</code></pre>
5126
5127<p>Here the terminal invokes the handler at the registered interval, but the code further limits a health check to once every 300 seconds. That second gate can be helpful when one timer supports several duties. It also creates a review obligation: lastHealthCheck must be initialized and the use of TimeCurrent must fit the intended clock behavior.</p>
5128
5129<h3>Timer questions that prevent surprises</h3>
5130
5131<ol>
5132  <li>Where is the timer registered, and is its interval appropriate for the workload?</li>
5133  <li>Does the timer function make trading decisions that should instead wait for a fresh quote?</li>
5134  <li>Could a slow scan or repeated file operation make the handler expensive?</li>
5135  <li>Are shared variables accessed predictably by both OnTick and OnTimer?</li>
5136  <li>Does the deinitialization routine call EventKillTimer?</li>
5137</ol>
5138
5139<p>An event driven program benefits from short handlers. A lengthy loop inside OnTimer can delay the next useful task and make diagnostics difficult. If an EA scans a list of symbols, a reviewer can check whether it limits the work per event, records failures, and handles symbols that do not have usable quote data. A timer is best treated as a scheduling tool, not as an excuse to hide a large uncontrolled process.</p>
5140
5141<p>For readers reviewing source recovered from an EX4, timer code can be especially revealing. It may contain status messages, licensing checks, panel refreshes, or delayed actions that do not appear in the main trade path. The site guide to <a href="/blog/how-to-read-decompiled-mq4-code-from-ex4">reading decompiled MQ4 code from EX4</a> offers a complementary method for naming functions and tracing these less obvious branches.</p>
5142
5143<h2 id="ondeinit">Stage Four: OnDeinit Leaves Cleanly</h2>
5144
5145<p>OnDeinit is called when the EA is being removed or reinitialized. Reasons can include a user removing it, a chart or input change, recompilation, a template change, or terminal shutdown. MQL4 provides a reason code so the program can log context if needed. The central goal is orderly cleanup.</p>
5146
5147<pre><code>void OnDeinit(const int reason)
5148{
5149   EventKillTimer();
5150   DeleteStatusLabel();
5151   CloseLogFile();
5152   Print("EA stopped. Reason: ", reason);
5153}</code></pre>
5154
5155<p>This handler stops the timer, removes a chart object owned by the EA, closes a file, and records why the lifecycle ended. It should generally avoid opening new trades or making speculative changes to market exposure merely because the program is shutting down. Whether an EA closes open positions at deinitialization is a major behavioral decision, not routine cleanup. If that behavior exists, it should be explicit, configurable where appropriate, and tested carefully.</p>
5156
5157<h3>Cleanup is about ownership</h3>
5158
5159<p>
5159Object deletion is safe only when the EA can identify objects it created. A common pattern is a unique prefix that includes the EA name, symbol, or magic number. A broad loop that deletes every chart object can disrupt other indicators or tools on the same chart. The same principle applies to terminal global variables and files. A cleanup routine should remove its own resources, not erase shared context indiscriminately.</p>
5160
5161<p>Also consider reinitialization. If inputs change, OnDeinit may run and OnInit may soon follow. State that was only held in memory can disappear. State saved externally can persist unexpectedly. A reviewer should ask whether the EA intentionally restores what it needs and whether stale state is detected rather than reused without checks.</p>
5162
5163<h2 id="sequence">How Events Interact in Practice</h2>
5164
5165<p>The four handlers are not a rigid sequence that occurs once. OnInit occurs first for an attachment cycle. After that, ticks and timer events can occur repeatedly in an order determined by market activity and the schedule. Finally, OnDeinit ends that cycle. A parameter change can begin another cycle immediately afterward.</p>
5166
5167<table>
5168  <thead><tr><th>Situation</th><th>Likely event path</th><th>What to inspect</th></tr></thead>
5169  <tbody>
5170    <tr><td>EA attached during an active market</td><td>OnInit, then recurring OnTick and possibly OnTimer</td><td>Input validation, initial state, duplicate-entry gates</td></tr>
5171    <tr><td>EA attached during a quiet period</td><td>OnInit, timer events if set, no OnTick until a quote arrives</td><td>Whether essential work wrongly depends on ticks</td></tr>
5172    <tr><td>User changes an input</td><td>OnDeinit, then OnInit</td><td>State reset, object ownership, timer replacement</td></tr>
5173    <tr><td>EA is removed</td><td>OnDeinit</td><td>Timer cancellation, file closure, unintended position actions</td></tr>
5174  </tbody>
5175</table>
5176
5177<p>Shared state is where interaction bugs often live. A variable updated in OnTimer and read in OnTick needs a clear meaning at every point. For example, a timer might set a daily permission flag while OnTick submits orders. The reviewer should identify the initial flag value, the time source, update conditions, and the fallback if the timer has not yet run. Clear names and small functions make this easier, but recovered code can require a manual trace.</p>
5178
5179<h2 id="review-method">A Code Review Method for Recovered EAs</h2>
5180
5181<p>When source has been recovered or inherited, start with a lifecycle inventory rather than changing code immediately. The goal is to create a factual map of what the program does. This review site discusses recovery options in a third-person capacity, and a readable result should be treated as material for verification, not as an automatic approval for deployment.</p>
5182
5183<ol>
5184  <li><strong>Find the handlers.</strong> Search for OnInit, OnTick, OnTimer, and OnDeinit, then confirm their declarations are valid handlers.</li>
5185  <li><strong>List calls made by each handler.</strong> Draw arrows from each handler to signal, order, display, file, and cleanup helpers.</li>
5186  <li><strong>Mark state writes.</strong> Record global variables, files, chart objects, and terminal variables created or changed at each stage.</li>
5187  <li><strong>Trace one ordinary path.</strong> Follow a normal startup, one tick, one timer event, and removal without assuming a helper succeeds.</li>
5188  <li><strong>Trace failure paths.</strong> Note invalid inputs, failed order operations, unavailable history, and a timer that was not registered.</li>
5189  <li><strong>Separate facts from assumptions.</strong> Write what the code checks and does, then separately list behavior that must be tested.</li>
5190</ol>
5191
5192<p>A useful worksheet has four columns: event, trigger, state read or written, and possible external action. External actions include sending or modifying orders, deleting objects, writing files, showing alerts, and calling web or DLL related functions where enabled. This format prevents an attractive entry condition from distracting the reviewer from operational side effects.</p>
5193
5194<p>If the purpose is to understand an old EA whose original author cannot provide source, establish the right to inspect it before using any recovery path. Readers considering the technical route can compare an <a href="/">mql4 decompiler</a> approach with supported alternatives, but possession of an EX4 alone does not establish permission to recover or distribute its code. The appropriate scope depends on ownership, licence terms, and local law.</p>
5195
5196<h2 id="examples">Patterns, Mistakes, and Safer Choices</h2>
5197
5198<h3>Pattern: single responsibility by handler</h3>
5199
5200<p>A maintainable EA uses OnInit to prepare, OnTick to respond to market data, OnTimer for periodic work, and OnDeinit to clean up. This does not prohibit shared helper functions. It means the reason a helper is called should be easy to explain. A trade signal evaluated inside a display refresh function is harder to review than the same signal called from a clearly guarded OnTick.</p>
5201
5202<h3>Mistake: an unregistered timer</h3>
5203
5204<p>An OnTimer function can look polished yet never run if EventSetTimer is absent or unreachable. Search for both EventSetTimer and EventKillTimer. Confirm that initialization reaches the registration call only after necessary validation, and that failure handling is visible. If the EA depends on a timer for a risk or session flag, an absent registration is a substantive defect, not a cosmetic issue.</p>
5205
5206<h3>Mistake: duplicate entries on one candle</h3>
5207
5208<p>When an entry condition remains true across several ticks, a tick-based EA may submit repeated requests unless it checks open exposure or records that the current bar has been handled. The safer choice depends on the documented strategy. It might use one trade per bar, one trade per signal transition, or a position count. The key is an explicit rule that matches the intended behavior.</p>
5209
5210<h3>Mistake: cleanup that trades</h3>
5211
5212<p>Some EAs include a broad CloseAll function and call it from OnDeinit. This may surprise a user who simply changes a parameter or recompiles. A reviewer should flag any trading function called from cleanup and determine whether it is deliberate, documented, and suitable for the intended operating environment. There is no universally correct close-on-remove policy.</p>
5213
5214<h3>Pattern: observable status without decision leakage</h3>
5215
5216<p>A timer can update a label with the last signal time, current spread, or count of managed orders. This can help an operator see that the EA is alive without mixing presentation into trade execution. Use names that make ownership clear, remove only those labels in OnDeinit, and make sure a missing label does not alter the order path.</p>
5217
5218<h2 id="testing">Testing the Lifecycle Before Use</h2>
5219
5220<p>Lifecycle testing should precede any live use of an edited or recovered EA. It is not a claim that testing eliminates risk. Markets, execution conditions, broker rules, and account settings can differ from a test environment. It is a way to discover whether the observable event flow matches the reviewer’s expectations.</p>
5221
5222<h3>Suggested test sequence</h3>
5223
5224<ul>
5225  <li>
5225Attach the EA with deliberately invalid inputs and confirm that OnInit refuses them clearly.</li>
5226  <li>Attach it with intended test inputs and check that expected objects, logs, and timer behavior appear without an order action.</li>
5227  <li>Use historical or demo conditions to observe whether OnTick evaluates once per tick or once per completed bar as designed.</li>
5228  <li>Check the behavior when an order request fails or a price is unavailable. Verify that errors are reported and no false success state remains.</li>
5229  <li>Change an input and observe the deinitialization and initialization cycle. Look for duplicate labels, stale counters, or multiple timers.</li>
5230  <li>Remove the EA and confirm that it cancels its own timer and resources without deleting unrelated chart items.</li>
5231</ul>
5232
5233<p>Keep a small change log for every test. Record the build, symbol, timeframe, inputs, date range, and what actually occurred. If a code edit changes a lifecycle decision, explain why. This record helps separate a source-level observation from a platform or broker condition encountered later.</p>
5234
5235<p>Anyone examining a robot for the first time should also keep trading risk in perspective. A clean event design does not validate a strategy, predict execution quality, or make an automated system suitable for a particular person. It only provides a firmer engineering basis for further, controlled evaluation.</p>
5236
5237<h2 id="conclusion">A Better Way to Read EA Behavior</h2>
5238
5239<p>The four event handlers form a practical narrative for an MQL4 Expert Advisor. OnInit says what must be true before the program starts. OnTick shows how it reacts when a chart quote arrives. OnTimer reveals work that follows a schedule rather than market activity. OnDeinit shows what the program considers its own responsibility when the attachment ends.</p>
5240
5241<p>Read in that order, an EA becomes easier to audit. Instead of asking only what indicator it uses, a reviewer can ask when that indicator is evaluated, what blocks repeated actions, where state changes, and how the program resets. Those questions are useful whether the source is newly written, inherited from a prior developer, or recovered with appropriate permission.</p>
5242
5243<p>For an independent overview of legitimate source recovery choices, readers can return to the site's <a href="/">ex4 to mq4 decompiler</a> review resources. The productive next step is not to rush into edits. It is to document the event map, test each lifecycle boundary, and make changes only when the code's purpose and authority to maintain it are clear.</p>
5244`},{slug:"mql4-order-management-risk-controls",title:"MQL4 Order Management Risk Controls Every Expert Advisor Should Have",metaTitle:"MQL4 Order Management Risk Controls for Expert Advisors",metaDescription:"A practical MQL4 risk-control guide covering protected stops, position sizing, order errors, trade limits, and layered safeguards for Expert Advisors.",keywords:"MQL4 order management, Expert Advisor risk controls, MQL4 stop loss, EA position sizing, MT4 order error handling, automated trading risk shield",excerpt:"An Expert Advisor is only as safe as its order-management rules. This practical guide explains the stop loss, sizing, validation, error handling, and account-level safeguards worth reviewing before an MT4 EA is trusted with live orders.",date:"September 7, 2026",dateISO:"2026-09-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"19 min read",featuredImage:Lu,imageAlt:"MQL4 Expert Advisor order-management risk controls shown on an MT4 trading screen",tableOfContents:[{id:"why-order-controls-matter",title:"Why Order Controls Matter"}
5244,{id:"risk-before-entry",title:"Define Risk Before an Entry Exists"},{id:"protective-stop",title:"Protective Stop Loss Design"},{id:"position-sizing",title:"Position Sizing From Actual Risk"},{id:"preflight-checks",title:"The Order Preflight Checklist"},{id:"execution-errors",title:"Execution Errors and Safe Retries"},{id:"post-entry",title:"Controls After the Order Opens"},{id:"risk-shield",title:"Build an Account-Level Risk Shield"},{id:"reviewing-code",title:"Reviewing Recovered or Purchased Code"},{id:"test-plan",title:"A Practical Test Plan"},{id:"conclusion",title:"Conclusion"}],content:`
5245<p>An automated trading strategy can identify a reasonable setup and still create an unacceptable loss because its order-management layer is weak. An Expert Advisor may calculate a signal correctly, then submit an oversized order, place a stop at an invalid price, retry blindly after a network problem, or open a second position while the first one is unresolved. Those are not small implementation details. They determine what the strategy is allowed to do when prices, spreads, platform data, and broker rules are less orderly than a backtest.</p>
5246
5247<p>This guide examines risk controls that belong around MQL4 order handling. It is written for people reviewing an EA, maintaining their own source, or assessing readable code recovered from a file they have the right to inspect. It does not promise that any rule makes trading safe or profitable. Market gaps, changing execution conditions, and mistakes in assumptions can still produce outcomes beyond a planned loss. The point is narrower: an EA should have deliberate limits, verify its assumptions, and fail closed when it cannot safely determine what happened.</p>
5248
5249<p>For a wider explanation of how compiled and source files relate, readers can start with this <a href="/">ex4 to mq4</a> overview. Once readable code is available, order management deserves a separate review because a strategy description rarely tells the whole story. A vendor can say that a robot uses stop losses while the actual code calculates them only after opening a trade, uses a constant lot on every symbol, or ignores a failed modification request.</p>
5250
5251<img src="${Lu}" alt="MQL4 Expert Advisor order-management risk controls shown on an MT4 trading screen" style="width:100%;border-radius:8px;margin:24px 0;" />
5252
5253<h2 id="why-order-controls-matter">Why Order Controls Matter</h2>
5254
5255<p>Signal logic answers whether an EA wants to trade. Order controls answer whether it is permitted to trade now, at this size, on this account, with this protection, and under these execution conditions. Keeping those decisions separate makes a program easier to reason about. A crossover, breakout, or mean-reversion rule should not quietly decide the lot size or override a daily loss limit just because a condition is true.</p>
5256
5257<p>MT4 also provides imperfect information. Bid and Ask change between calculations. A broker can enforce a minimum stop distance or a freeze level. The terminal can lose connection. The trade context can be busy. An order request can time out after reaching the server, leaving the EA uncertain whether a trade exists. A robust design treats these as normal operating states rather than exceptional events that justify repeated OrderSend calls.</p>
5258
5259<table>
5260<thead><tr><th>Layer</th><th>Question it answers</th><th>Example control</th></tr></thead>
5261<tbody>
5262<tr><td>Strategy</td><td>Is there a valid setup?</td><td>Signal is confirmed on a closed bar</td></tr>
5263<tr><td>Trade permission</td><td>May this EA trade at all?</td><td>Trading window, spread limit, account check</td></tr>
5264<tr><td>Risk calculation</td><td>What is the maximum acceptable exposure?</td><td>Lot derived from stop distance and risk budget</td></tr>
5265<tr><td>Execution</td><td>Can this specific request be sent safely?</td><td>Normalized prices and valid stop distance</td></tr>
5266<tr><td>Reconciliation</td><td>What actually happened?</td><td>Search open and recent orders before retrying</td></tr>
5267<tr><td>Account shield</td><td>When must new risk stop?</td><td>Daily loss and total-exposure caps</td></tr>
5268</tbody>
5269</table>
5270
5271<p>A review should look for every layer. One StopLoss input is not proof of protection. The reviewer needs to follow the value from input to calculation, OrderSend or OrderModify, error handling, and later verification. The same discipline applies to maximum lot inputs and trade-count limits. An input that is displayed but not enforced is worse than an absent input because it can create false confidence.</p>
5272
5273<h2 id="risk-before-entry">Define Risk Before an Entry Exists</h2>
5274
5275<p>Risk controls are clearest when the EA makes its commitments before it sends an order. The program should determine the invalidation point, maximum monetary loss estimate, volume, and conditions that would cancel the trade. It should not open first and hope to attach a stop later. There can be broker-specific cases where a two-step workflow is unavoidable, but they call for an explicit mitigation plan, not an unexamined shortcut.</p>
5276
5277<h3>A useful decision sequence</h3>
5278<ol>
5279<li>Identify the intended entry side and obtain fresh Bid or Ask data with RefreshRates().</li>
5280<li>Calculate the logical stop from the strategy, such as a swing level or volatility distance.</li>
5281<li>Check that the stop is on the correct side of the market and far enough away for the symbol.</li>
5282<li>Estimate loss per lot using symbol properties rather than assuming every instrument behaves like EURUSD.</li>
5283<li>
5283Convert the selected risk budget into a normalized lot size.</li>
5284<li>Apply account, symbol, spread, session, and exposure limits.</li>
5285<li>Send the protected order only if every check passes.</li>
5286</ol>
5287
5288<p>Each refusal should have a readable reason. A message such as “entry skipped: stop distance below broker minimum” helps an operator distinguish a safe rejection from a broken signal. Logging only “error” does not. At the same time, logs should avoid exposing account credentials or treating a journal line as proof that the server accepted an order.</p>
5289
5290<p>A simple configuration can establish boundaries without pretending to be universal:</p>
5291<ul>
5292<li>RiskPercent or a fixed currency risk ceiling per trade.</li>
5293<li>MaxLots as an independent upper cap after sizing.</li>
5294<li>MaxSpreadPoints and an explicit unit convention.</li>
5295<li>MaxOpenTrades for the EA magic number and symbol.</li>
5296<li>Maximum slippage stated in points and reviewed for five-digit symbols.</li>
5297<li>Trading-session rules that account for the broker server clock.</li>
5298</ul>
5299
5300<p>Inputs need validation too. A zero or negative stop distance, a risk percentage above a stated guardrail, or a MaxLots value below the broker minimum should stop initialization or disable entries with a clear message. The code should never silently substitute a much larger default because a user entered an invalid setting.</p>
5301
5302<h2 id="protective-stop">Protective Stop Loss Design</h2>
5303
5304<p>A stop loss is a conditional order instruction, not a guarantee of an exact exit price. In a fast market or after a weekend gap, an execution can occur away from the stop level. That limitation makes it more important, not less important, to place a protective stop whenever the broker and trading design permit it. The EA should define whether the stop is mandatory. If it is mandatory and the platform cannot confirm protection, the conservative response is to avoid opening new exposure or to close an unprotected position according to a documented policy.</p>
5305
5306<p>For a buy, the stop should normally be below the relevant market price. For a sell, it should normally be above it. The raw strategy price then needs broker validation. MODE_STOPLEVEL gives the minimum permitted distance in points, although a returned zero does not guarantee that a broker will accept every request. MODE_FREEZELEVEL can also prevent changes near market price. A design should use these values as checks and still handle rejection gracefully.</p>
5307
5308<h3>Stop-loss review checklist</h3>
5309<ul>
5310<li>Does the code calculate the stop before calling OrderSend?</li>
5311<li>Does it use Ask for buy-side distance checks and Bid for sell-side checks where appropriate?</li>
5312<li>Are prices normalized with the symbol digits before submission?</li>
5313<li>Does it account for Point, tick size, and differing quote precision?</li>
5314<li>Is a minimum stop based on both strategy logic and broker constraints?</li>
5315<li>Does a rejected stop prevent an unprotected trade from remaining open?</li>
5316<li>When trailing, does the code move a stop only in the protective direction?</li>
5317<li>Are break-even rules adjusted for spread, commission assumptions, and the actual intended policy?</li>
5318</ul>
5319
5320<p>Trailing logic is frequently more dangerous than it looks. A loop that calls OrderModify on every tick can create excessive requests, repeatedly set the same stop, or loosen protection due to a calculation mistake. A safer rule first verifies that a new stop improves the existing one by at least a meaningful step, is outside freeze and stop limits, and is attached to an order owned by the EA. It then records success or failure. A buy stop should not move downward merely because a trailing formula recalculated after a pullback.</p>
5321
5322<p>Pending orders require their own protection checks. Their entry, stop, and take-profit levels must all satisfy ordering and distance requirements. A buy stop placed too close to Ask or a sell limit placed on the wrong side of Bid should be rejected before it reaches the server. An expiration time also needs an intentional timezone policy. Vague handling of server time can leave stale pending orders active longer than the operator expects.</p>
5323
5324<h2 id="position-sizing">Position Sizing From Actual Risk</h2>
5325
5326<p>Fixed lots are easy to code and hard to justify across different accounts, symbols, and stop distances. A risk-based method starts with an amount the operator is prepared to lose if the stop is reached under ordinary execution assumptions. It divides that amount by the estimated loss per lot from entry to stop. The result is then rounded down to the broker volume step and constrained by minimum and maximum volume.</p>
5327
5328<p>Conceptually, the calculation is:</p>
5329<p><strong>volume = permitted monetary risk / estimated loss per lot to the stop</strong></p>
5330
5331<p>The difficult part is estimating loss per lot correctly. MQL4 code often uses MODE_TICKVALUE and MODE_TICKSIZE, but symbol specifications can vary, particularly for metals, indices, and broker-specific instruments. Currency conversion can also matter when an account currency differs from the quote or profit currency. A competent EA should query the relevant MarketInfo values, document its assumptions, and reject a trade if a required value is zero, nonsensical, or unavailable. A reviewer should be cautious of code that simply multiplies pips by a hard-coded ten.</p>
5332
5333<table>
5334<thead><tr><th>
5334Situation</th><th>Safe sizing response</th><th>Unsafe shortcut</th></tr></thead>
5335<tbody>
5336<tr><td>Wider technical stop</td><td>Reduce volume to preserve the risk budget</td><td>Keep the same lot because the signal is strong</td></tr>
5337<tr><td>Calculated volume below minimum</td><td>Skip trade or apply a documented policy</td><td>Round up and quietly exceed risk</td></tr>
5338<tr><td>Calculated volume above maximum</td><td>Cap volume and reassess actual risk</td><td>Submit the raw value and hope</td></tr>
5339<tr><td>Unknown tick value</td><td>Do not trade until the value is resolved</td><td>Use a default forex formula on every symbol</td></tr>
5340</tbody>
5341</table>
5342
5343<p>Rounding direction matters. If the lot step is 0.01 and a calculation returns 0.347, rounding to 0.35 slightly increases exposure. Rounding down to 0.34 is more consistent with a maximum-risk rule. The code should then calculate the resulting estimated risk and verify that it remains within the configured tolerance. This also makes a useful journal entry: requested risk, stop distance, computed lot, normalized lot, and final estimated risk.</p>
5344
5345<p>Risk sizing should include already-open exposure. Two separately sized positions can create a combined loss that exceeds the account plan when both stops lie in the same direction. An EA does not need to predict correlation perfectly to improve on this. It can add a maximum total risk estimate for its open orders, a per-symbol limit, and a cap on trades that share a magic number or strategy family.</p>
5346
5347<h2 id="preflight-checks">The Order Preflight Checklist</h2>
5348
5349<p>Before OrderSend, the EA should perform a short, deterministic preflight. This prevents an execution function from becoming a mixture of strategy decisions, price calculations, and retries. A preflight can return either an approved order request or a rejection code that the caller logs once.</p>
5350
5351<ol>
5352<li><strong>Terminal state:</strong> confirm trading is allowed, the EA has permission to trade, and connection status is suitable for the chosen policy.</li>
5353<li><strong>Fresh symbol data:</strong> refresh rates and confirm Bid, Ask, and spread are usable.</li>
5354<li><strong>Ownership state:</strong> count only orders matching the expected symbol and magic number before applying an EA-specific trade limit.</li>
5355<li><strong>Market conditions:</strong> enforce spread, session, and optional volatility filters defined by the strategy.</li>
5356<li><strong>Price and levels:</strong> normalize entry, stop, and target; check side, stop level, and freeze constraints.</li>
5357<li><strong>Volume:</strong> validate min lot, max lot, lot step, free-margin policy, and calculated risk.</li>
5358<li><strong>Risk shield:</strong> check daily loss, consecutive-loss, total exposure, and emergency-stop state.</li>
5359</ol>
5360
5361<p>Using an EA magic number is essential but not sufficient. Order loops must select each order successfully before reading its fields and should not accidentally manage manual trades or another EA’s positions. The symbol check matters on multi-chart installations. A global “one order only” rule may be intentional, but it should be clearly named rather than arriving as an accidental side effect of counting all account orders.</p>
5362
5363<p>Margin checks require modest claims. AccountFreeMarginCheck can help identify an obviously insufficient request, but it does not reserve margin and conditions can change. It is one gate among several, not proof that an order will be accepted. The EA should handle a broker rejection without assuming the check was wrong or trying a larger volume.</p>
5364
5365<h2 id="execution-errors">Execution Errors and Safe Retries</h2>
5366
5367<p>Error handling is where many otherwise thoughtful EAs become risky. A failed OrderSend returns a negative ticket and GetLastError identifies the immediate terminal error, but that alone may not describe final server state. Network interruption and timeouts are especially important because the request may have been received even when the EA did not receive a clean confirmation.</p>
5368
5369<p>The first response after an uncertain result should be reconciliation, not repetition. The EA can search current trades and recent history for an order matching its symbol, magic number, direction, volume, approximate request time, and an identifying comment if comments are used carefully. If the state cannot be determined with confidence, a cautious system disables further entries and alerts the operator. Sending the same instruction three times can turn a one-position plan into three positions.</p>
5370
5371<h3>Classify errors by response</h3>
5372<table>
5373<thead><tr><th>
5373Class</th><th>Illustrative condition</th><th>Appropriate response</th></tr></thead>
5374<tbody>
5375<tr><td>Correctable request</td><td>Price changed or invalid price</td><td>Refresh prices, rebuild the request, retry a limited number of times</td></tr>
5376<tr><td>Temporary platform state</td><td>Trade context busy</td><td>Wait briefly, recheck permissions and order state, then retry once or per policy</td></tr>
5377<tr><td>Invalid configuration</td><td>Invalid stops or volume</td><td>Do not retry unchanged; log and disable that entry</td></tr>
5378<tr><td>Permission or market closure</td><td>Trading disabled or market closed</td><td>Stop entries until a new valid evaluation</td></tr>
5379<tr><td>Uncertain outcome</td><td>Timeout or connection interruption</td><td>Reconcile first; lock new entries if unresolved</td></tr>
5380</tbody>
5381</table>
5382
5383<p>A retry budget should be finite and visible in the code. It should include a delay and refresh price-sensitive values between attempts. Reusing the original Ask after several ticks is not a retry strategy. The journal should capture the attempt count, error code, request details excluding sensitive data, and the reconciliation result. This makes later diagnosis possible without encouraging automated escalation.</p>
5384
5385<p>OrderModify and OrderClose need the same discipline. A failed modification can leave a stop at its former level. A failed close can leave the position open. The EA should reselect the ticket, verify the actual stop or close state, and follow the documented escalation policy. It should not report “closed” simply because the call was made.</p>
5386
5387<h2 id="post-entry">Controls After the Order Opens</h2>
5388
5389<p>Opening an order begins a new set of obligations. The EA should verify the ticket, open price, volume, stop loss, take profit, and magic number by selecting the order again. If a market order is filled at a materially different price, the actual stop distance and estimated risk can differ from the planned values. A design can decide whether that difference is acceptable, whether to modify protection, or whether to close under a tightly defined rule.</p>
5390
5391<p>Management code should be idempotent where possible: running it twice should not create a worse outcome. For example, a break-even function can check whether the existing stop is already at or beyond the desired protective level before calling OrderModify. A partial-close function can persist or infer that its one permitted action has already occurred. This is important after terminal restarts, chart changes, and duplicate ticks.</p>
5392
5393<p>It is also worth defining what the EA does when it is not running. A terminal shutdown can prevent trailing, time exits, or emergency rules from executing. A hard stop held at the broker is generally different from a virtual stop that exists only in code. If an EA uses virtual exits, the review should explain the operational dependency plainly. The site’s guide to <a href="/blog/expert-advisor-vps-transfer-audit-mt4">auditing an EA before an MT4 VPS transfer</a> provides a related checklist for continuity, startup settings, and order ownership.</p>
5394
5395<h2 id="risk-shield">Build an Account-Level Risk Shield</h2>
5396
5397<p>Per-trade sizing is necessary but may not be enough. A risk shield is a separate group of rules that can veto new orders when the account or strategy reaches a predefined condition. It should be simple enough to audit and difficult for ordinary signal code to bypass.</p>
5398
5399<h3>Useful shield components</h3>
5400<ul>
5401<li><strong>Daily loss boundary:</strong> compare equity or realized results against a clearly defined start-of-day reference, with the broker timezone documented.</li>
5402<li><strong>Maximum open risk:</strong> estimate potential loss to existing protective stops and prevent new exposure beyond the budget.</li>
5403<li><strong>Trade-frequency limit:</strong> cap entries per session or day to limit loops caused by faulty signals.</li>
5404<li><strong>Consecutive-loss pause:</strong> pause after a chosen run of closed losses, while recognizing that this does not diagnose the market.</li>
5405<li><strong>Spread and execution circuit breaker:</strong> stop initiating orders after abnormal spread or repeated execution failures.</li>
5406<li><strong>Manual kill switch:</strong> provide an input or global state that disables new entries without confusing it with closing positions.</li>
5407</ul>
5408
5409<p>Definitions prevent surprises. A daily-loss rule based on balance ignores floating loss until positions close. A rule based on equity reacts to floating loss but can be affected by spread changes. Neither is automatically right. The operator should select a definition matching the strategy and understand it from the input label and documentation. The code should store or reconstruct its baseline consistently across restarts; otherwise a restart can accidentally reset the shield.</p>
5410
5411<p>Emergency behavior deserves special caution. “Close everything” is a consequential action and can realize losses during a temporary condition. Many designs sensibly distinguish between blocking new entries, managing existing stops, and closing existing orders. If an emergency close is offered, it should be explicit, limited to intended tickets, and verified afterward. It should never sweep unrelated manual positions by default.</p>
5412
5413<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
5414<h3 style="margin-top:0;">Need a Readable-Code Review Path?</h3>
5415<p>ForexMQ5 is reviewed as a specialist option for owners with a legitimate source recovery or authorised code-review need. A readable result can help a qualified developer inspect order controls before a maintenance project.</p>
5416<a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
5417</div>
5418
5419<h2 id="reviewing-code">Reviewing Recovered or Purchased Code</h2>
5420
5421<p>When an owner has lawful access to code, order-management review should begin with a map, not edits. Search for OrderSend, OrderModify, OrderClose, OrderDelete, GetLastError, RefreshRates, OrderSelect, MarketInfo, and the magic number. Then trace every path that can call a trade function. An EA may have a main entry routine plus recovery, grid, news, or timer routines that submit orders under different rules.</p>
5422
5423<p>Code recovered from a compiled file can be especially challenging because names, comments, and some structure may require interpretation. That is a reason to test assumptions, not to infer behavior from a reassuring variable name. The detailed process of reviewing readable output is covered in this guide on <a href="/blog/how-to-read-recovered-mql4-expert-advisor-code">how to read recovered MQL4 Expert Advisor code</a>. For order control specifically, an analyst should write down evidence for each claimed safeguard and identify the function that enforces it.</p>
5424
5425<h3>Questions for a code-review worksheet</h3>
5426<ol>
5427<li>Which functions can create market or pending orders?</li>
5428<li>Is every path gated by the same risk shield, or do exceptions exist?</li>
5429<li>Where is the stop calculated, and can an order be opened without it?</li>
5430<li>Is volume derived from stop distance, fixed, martingale-based, or changed after losses?</li>
5431<li>How does the program recognize an order it owns after a restart?</li>
5432<li>What happens after each error class, and is a timeout treated as uncertain?</li>
5433<li>Can trailing or recovery logic loosen stops, multiply volume, or exceed a count limit?</li>
5434<li>Which inputs are actually read in the trading path?</li>
5435</ol>
5436
5437<p>A review site should not imply that recovery alone makes an EA trustworthy. Readable code can make a meaningful audit possible, but behavior still depends on the broker, platform, inputs, market data, and tests. ForexMQ5 is discussed here as a third-party specialist service option, not as the operator of this review site or a source of trading assurance.</p>
5438
5439<h2 id="test-plan">A Practical Test Plan</h2>
5440
5441<p>Risk controls need adversarial tests, not only favorable backtests. A strategy tester may not reproduce every server error or connection state, so testing should combine historical checks, a demo environment where suitable, and controlled inspection of logs. No test proves future execution, but specific scenarios can reveal whether the code honors its declared limits.</p>
5442
5443<table>
5444<thead><tr><th>Test case</th><th>Expected result</th><th>Evidence to retain</th></tr></thead>
5445<tbody>
5446<tr><td>Stop below broker minimum</td><td>Trade is skipped or adjusted only under the stated policy</td><td>Journal reason and no unprotected ticket</td></tr>
5447<tr><td>Calculated lot below minimum</td><td>Trade is skipped if rounding up violates the risk rule</td><td>Risk calculation and rejection record</td></tr>
5448<tr><td>Spread above ceiling</td><td>No new order is sent</td><td>Observed spread and gate result</td></tr>
5449<tr><td>Repeated signal on one bar</td><td>Trade-count guard prevents duplicates</td><td>Ticket count and state marker</td></tr>
5450<tr><td>Simulated temporary error</td><td>Limited retry, refreshed values, no request storm</td><td>Attempt count and final state</td></tr>
5451<tr><td>Restart with an open trade</td><td>EA recognizes and manages only its own ticket</td><td>Selected ticket, magic number, stop status</td></tr>
5452<tr><td>Daily shield reached</td><td>New entries remain blocked after reinitialization</td><td>Baseline, threshold, and persisted state</td></tr>
5453</tbody>
5454</table>
5455
5456<p>Use conservative test settings first. Deliberately set an implausibly small spread limit, low trade maximum, and tiny daily threshold to confirm that each gate can block an entry. Then test the normal configuration. This is more revealing than watching the EA trade normally and assuming unused controls will work when needed. Any change to sizing, stop logic, symbol handling, or error recovery warrants a fresh pass through the relevant scenarios.</p>
5457
5458<p>Operators should also retain a rollback plan. Keep the prior compiled file, documented inputs, change notes, and a way to disable new entries. A code fix that improves one order path can break another. Careful versioning and a small, testable change set are safer than combining strategy changes with a complete rewrite of risk controls.</p>
5459
5460<h2 id="conclusion">Conclusion</h2>
5461
5462<p>Strong MQL4 order management does not make automated trading certain, but weak order management can defeat even a sensible strategy. The practical baseline is straightforward: calculate risk before entry, place and verify protective stops, size volume from the actual stop and symbol specification, preflight every request, reconcile uncertain outcomes, and enforce account-level limits that signal logic cannot casually override.</p>
5463
5464<p>For anyone evaluating an EA, the most useful question is not “does it have a stop loss?” It is “under what conditions can this program create, alter, duplicate, or leave exposure open, and what independent control prevents that?” That question turns vague safety claims into an auditable checklist. Readers exploring legitimate source-review options can return to the site’s <a href="/">mql4 decompiler</a> resources, then apply the same evidence-based scrutiny to every order path before live deployment.</p>
5465`}],Nu="/assets/n01_legal_gavel-BtZgE8qR.png",DE="/assets/n01_legal_scales-DD6N-GEy.png",LE="/assets/n01_legal_reading-CrrAlUAJ.png",NE="/assets/n01_ip_shield-VHrJG2jD.png",OE="/assets/n01_permission-D13gahlu.png",FE="/assets/n01_agreement-T6ImZy3t.png",Ou="/assets/n02_distressed_dev-CnGrhafT.png",QE="/assets/n02_file_rescue-CtMcQRLt.png",WE="/assets/n02_code_archaeology-DNPkJ5IR.png",zE="/assets/n02_recovery_steps-CvIxoqpV.png",BE="/assets/n02_recovered_success-ChU57MnR.png",_E="/assets/n02_handover-fbppQzWF.png",Qs="/assets/n03_file_anatomy-XSPNLqYy.png",Fu="/assets/n03_mt4_robot_files-03cR97yd.png",Qu="/assets/n03_file_comparison-ButvvMaO.png",UE="/assets/n03_confused_trader-B2yTbAFa.png",Wu="/assets/n03_education_board-BtLJesFN.png",XE="/assets/n03_transformation-DqaJgDl9.png",Ws="/assets/n04_review_judge-CZ3yJcfW.png",VE="/assets/n04_star_ratings-g6v0uZrD.png",zs="/assets/n04_testing_lab-DA3lQcPA.png",HE="/assets/n04_winner_podium-B82Nxk9k.png",zu="/assets/n04_expert_panel-BZGt5Zpu.png",Bu="/assets/n04_comparison_chart
5465-C4vZ0rEV.png",In="/assets/n05_buyer_inspect-DqDTjn1X.png",_u="/assets/n05_red_flags-CV5y9TfY.png",$E="/assets/n05_contract_check-BoBbwU31.png",Rn="/assets/n05_due_diligence-E1dyzV44.png",Uu="/assets/n05_protected_buy-DaRM2EvH.png",GE="/assets/n05_verified_trader-Cbg1SgyH.png",Bs="/assets/n06_compiler_machine-DhzvQbLV.png",Xu="/assets/n06_metaeditor-BaskJ1mF.png",Vu="/assets/n06_binary_pipeline-CdRNjZQi.png",Hu="/assets/n06_dev_compile-B5aXG0jb.png",$u="/assets/n06_compile_flow-DVNNWRM0.png",Gu="/assets/n06_before_after-B0aK0J8t.png",Ku="/assets/n07_fake_vs_real-CJK99XzP.png",Yu="/assets/n07_hidden_revealed-DziINDtm.png",Ju="/assets/n07_detective_catch-sS-dFKp4.png",KE="/assets/n07_decompiler_light-B6EW5uVy.png",Zu="/assets/n07_truth_scales-CBUYpxb4.png",ep="/assets/n07_integrity_check-CTIU_UaN.png",tp="/assets/n08_broken_ea-z1EnPCKX.png",YE="/assets/n08_repair_ea-CUarx8VI.png",JE="/assets/n08_bug_detective-C1Qq80eb.png",ZE="/assets/n08_market_storm-C23OUPsc.png",e0="/assets/n08_ea_health-ySA2VVji.png",t0="/assets/n08_revived_ea-CFXMVOEV.png",rp="/assets/n09_auditor-DeZL_dMX.png",r0="/assets/n09_hidden_trap-Cqk9aOvU.png",a0="/assets/n09_malware_radar-CRmTsxzr.png",i0="/assets/n09_safe_cert-DupC2KmW.png",ap="/assets/n09_inspection-COFW4vEQ.png",n0="/assets/n09_report_card-C8IDDQBZ.png",ip="/assets/n10_platform_bridge-BNkk6skF.png",o0="/assets/n10_migration_list-BxM_lMnm.png",s0="/assets/n10_code_translator-CYsilIeI.png",l0="/assets/n10_crossroads-Ccw_pao6.png",d0="/assets/n10_upgrade_path-BSMvrIUv.png",c0="/assets/n10_platform_goodbye-DXXpUJtA.png",np="/assets/n11_cost_calc-CmI25UXc.png",h0="/assets/n11_invoice-B-jjzQTT.png",u0="/assets/n11_time_money-1koQO0GE.png",p0="/assets/n11_budget_compare-gaO8qD9R.png",m0="/assets/n11_savings-DXUPFt5_.png",f0="/assets/n11_roi_graph-dkYdX_Hu.png",op="/assets/n12_beginner_book-CAeetfGx.png",_s="/assets/n12_steps_diagram-DaKyg4_s.png",g0="/assets/n12_learning_journey-DXh2LLH_.png",v0="/assets/n12_mentor_student-CgBNMI10.png",y0="/assets/n12_first_attempt-VS73efVC.png",b0="/assets/n12_graduation-CtapnCYd.png",Us="/assets/n13_code_reader-Ddxmd27M.png",sp="/assets/n13_syntax_diagram-DYVLXq7J.png",lp="/assets/n13_translation_guide-B-jKrPCB.png",dp="/assets/n13_annotation-BMVp6e3M.png",cp="/assets/n13_code_puzzle-DDBs5gw3.png",hp="/assets/n13_understanding-Bj1jrWm3.png",up="/assets/p01_guide_overview-CzHO0fbP.png",w0="/assets/p01_why_decompile-BaUpWhDL.png",x0="/assets/p01_ex4_anatomy-CaYppcV8.png",k0="/assets/p01_choosing_tool-JIhqU_jn.png",A0="/assets/p01_how_it_works-BtP1Er7n.png",T0="/assets/p01_step_by_step-tYGza-G7.png",pp="/assets/n14_warning_flags-BIeUuQHa.png",E0="/assets/n14_detective-CPFX73Ns.png",M0="/assets/n14_suspicious_vendor-BH1ycT_1.png",S0="/assets/n14_warning_list-EAsCmPK-.png",C0="/assets/n14_scam_detector-CPQl-mi5.png",I0="/assets/n14_trust_badge-DgMzCY0z.png",R0="/assets/p02_build_versions-Cs850M5K.png",mp="/assets/p02_failure_wall-DK_7GIoq.png",j0="/assets/p02_fortress-fBXJkKeK.png",q0="/assets/p02_obfuscation-C_x-nsVH.png",P0="/assets/p02_quality_check-9d5l90uS.png",D0="/assets/p02_technical_limits-CsswktYO.png",fp="/assets/p03_advanced_analysis-Dlz10d5D.png",L0="/assets/p03_insider_secrets-DAKVY1OU.png",N0="/assets/p03_optimization-D2_7IxVc.png",O0="/assets/p03_pattern_recognition-D40CqfFi.png",F0="/assets/p03_protected_files-F-W6TZrw.png",Q0="/assets/p03_trading_logic-DnKb1tlG.png",W0=[{slug:"legal-rules-for-ex4-source-code-recovery",title:"EX4 Source Code Recovery and the Law: A Practical Rights Guide for MT4 Users",metaTitle:"EX4 Source Code Recovery Legal Guide for MT4 Users | 2026",metaDescription:"Learn how ownership, licence terms, purpose and local law affect EX4 source code recovery. A practical legal-risk guide for MT4 traders and developers.",keywords:"legal ex4 source code recovery, ex4 decompilation law, recover mq4 source legally, ex4 copyright rules, mt4 reverse engineering rights",excerpt:"An EX4 file can be technically recoverable without every use of that recovery being lawful. This independent review guide explains the ownership, licence, purpose, and record-keeping questions MT4 users should answer first.",date:"August 4, 2025",dateISO:"2025-08-04",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"18 min read",featuredImage:Nu,imageAlt:"legal considerations for EX4 source code recovery",tableOfContents:[{id:"starting-point",title:"Start With Rights, Not Software"},{id:"four-questions",title:"The Four Questions That Shape Legal Risk"},{id:"ownership-evidence",title:"Ownership, Commissioning, and Evidence"},{id:"licences-and-contracts",title:"What Licences and Contracts Can Change"},{id:"legitimate-purposes",title:"Purposes That May Support Recovery"},{id:"uses-to-avoid",title:"Uses That Create Serious Risk"},{id:"country-context",title:"Why Country-Specific Law Still Matters"},{id:"responsible-workflow",title:"A Responsible Recovery Workflow"},{id:"service-review",title:"Reviewing the Professional-Service Option"},{id:"questions",title:"Questions MT4 Users Commonly Ask"},{id:"conclusion",title:"The Practical Conclusion"}],content:`
5466<p>An EX4 file often becomes important at the worst possible moment. A developer discovers that an old laptop no longer starts. A trader has a custom Expert Advisor but cannot locate the source files. A business needs to understand whether a robot is compatible with a new trading environment. The technical question is easy to phrase: can the compiled file be turned back into readable MQL4? The legal question is more important: does the person asking have the right to do that?</p>
5467
5468<p>This is an independent review-site guide, not legal advice. It is designed to help MT4 users sort the facts before choosing a technical path or speaking with a qualified intellectual-property lawyer. Lawful source recovery is not defined by a magic label such as “personal use.” It normally turns on a combination of ownership, the agreement surrounding the file, the reason for inspection, the country involved, and what happens to the recovered material afterward.</p>
5469
5470<p>That distinction matters because compiled trading software is still software. The fact that logic is hidden inside an EX4 does not make it ownerless, and the availability of an <a href="/">ex4 decompiler</a> does not grant permission to copy another developer’s work. Conversely, a lost source file does not automatically erase the rights of the person who created or acquired that code. A careful assessment can separate a defensible maintenance project from a risky attempt to obtain a competitor’s strategy.</p>
5471
5472<img src="${Nu}" alt="gavel representing legal review of EX4 source recovery" style="width:100%;border-radius:8px;margin:24px 0;" />
5473
5474<h2 id="starting-point">Start With Rights, Not Software</h2>
5475
5476<p>People frequently begin by comparing recovery tools, output quality, or turnaround time. A better first step is to pause the technical work and identify the rights attached to the file. The relevant question is not simply who possesses the EX4. Possession can come from a purchase, a download, an employer, a freelancer, a former partner, or an unknown forum upload. Those routes carry very different implications.</p>
5477
5478<p>Copyright usually protects original computer code from the time it is created. In an MT4 context, the human-readable MQ4 and its compiled EX4 form can both reflect that protected work. Copyright commonly gives its owner control over reproduction, adaptation, distribution, and public sharing, subject to statutory limits and local rules. A person may have a valid licence to run a robot while lacking ownership of its underlying code.</p>
5479
5480<p>This is why a sound review begins with documents rather than assumptions. Find the development agreement, invoice, marketplace listing, licence text, emails, repository history, and delivery messages. They may reveal whether code ownership transferred, whether only a non-transferable running licence was supplied, or whether the creator gave written permission for inspection and modification. An absent document does not decide every case, but it makes the factual analysis less certain.</p>
5481
5482<p>There is also a practical reason to establish rights first. A narrowly documented request is easier for a responsible provider to evaluate. It allows the user to describe a maintenance or recovery need without presenting the job as a request to break controls or duplicate a commercial product. For readers comparing options, the site’s broader <a href="/blog/best-ex4-decompiler-options-review">EX4 decompiler review</a> explains the difference between professional recovery, older free utilities, and hands-on analysis. That technical comparison should follow, not replace, a rights check.</p>
5483
5484<h2 id="four-questions">The Four Questions That Shape Legal Risk</h2>
5485
5486<p>A useful way to screen an EX4 project is to answer four questions in writing. None of them is a substitute for legal advice, particularly where money, employment, a dispute, or a valuable trading system is involved. Together, however, they exp
5486ose the facts that most affect risk.</p>
5487
5488<ol>
5489<li><strong>Who owns the relevant intellectual property?</strong> The original author may own it, a client may own it under a written assignment, or a vendor may retain ownership while licensing use. Do not treat payment for development as automatic copyright transfer.</li>
5490<li><strong>What permission was granted?</strong> Look at the signed contract and licence. Permission to install an EA on one account is different from permission to alter, audit, or share its source.</li>
5491<li><strong>What is the narrow purpose of recovery?</strong> Recovering a developer’s own lost work, investigating an apparent security issue, and making software interoperate are materially different from extracting a trading strategy for a replacement product.</li>
5492<li><strong>What will happen after recovery?</strong> Private maintenance and controlled review are not the same as publication, resale, sublicensing, or removing restrictions. The downstream plan can change the legal picture dramatically.</li>
5493</ol>
5494
5495<p>Writing the answers down has value beyond organization. It creates a contemporaneous record of intent. If an owner later asks why an EX4 was examined, a short project note and preserved paperwork are more credible than a reconstructed explanation. The note should be truthful and specific. “Recover source needed to repair a personally commissioned EA after the contractor’s repository was lost” is useful. “See what it does” is vague. “Remove the account lock” is a warning sign.</p>
5496
5497<img src="${DE}" alt="scales of justice for software ownership decisions" style="width:100%;border-radius:8px;margin:24px 0;" />
5498
5499<h2 id="ownership-evidence">Ownership, Commissioning, and Evidence</h2>
5500
5501<p>The least controversial situation is authorship. If a programmer wrote an MQ4, compiled it, and later lost the source, that programmer ordinarily has a strong claim to recover and maintain their own work. Evidence can include version-control commits, dated backups, source fragments, compiler logs, emails discussing implementation choices, or a development invoice issued by the author. Backups are still preferable, but the loss of a backup does not transfer copyright to the compiler or to a recovery service.</p>
5502
5503<p>Commissioned work requires more care. In many places, the freelancer who writes software begins as the copyright owner unless a contract assigns rights or local employment rules say otherwise. A client who paid for a custom EA may therefore have broad practical rights to use it but not necessarily an ownership interest in the source. Contracts sometimes resolve this clearly with phrases such as “all right, title, and interest” or an express source-code handover obligation. Other contracts reserve the developer’s pre-existing libraries while assigning the custom strategy layer. The details matter.</p>
5504
5505<p>Employment is another distinct case. Code made within the scope of employment may belong to the employer under applicable law or contract terms. But a personal side project made on a work machine is not automatically an employer asset, and code written for a client after employment ends is not automatically personal property. A trader dealing with a former employee, a dissolved company, or a partnership disagreement should resist shortcuts. It is a situation where local legal advice is more valuable than a fast technical result.</p>
5506
5507<p>Receipts and access credentials are useful but incomplete evidence. A receipt may prove that someone bought a licence, yet a standard marketplace licence can expressly reserve all source-code rights. Likewise, an EX4 supplied by a broker, signal group, or friend can carry no permission at all. If the chain of title cannot be explained, the safest course is to seek written consent from the apparent rights holder or avoid recovery.</p>
5508
5509<h3>Build a small evidence file</h3>
5510
5511<p>Before any analysis, save copies of the files that support the claimed entitlement. Include the original EX4 with a checksum, the contract or licence, purchase records, relevant correspondence, and a dated statement of purpose. Store these records separately from the recovered output. If the project is a commissioned EA, add the specification and payment trail. If it is a security concern, record the observable behavior that triggered the concern. This is basic project hygiene, not a legal loophole.</p>
5512
5513<img src="${LE}" alt="MT4 user reading licence terms before code recovery" style="width:100%;border-radius:8px;margin:24px 0;" />
5514
5515<h2 id="licences-and-contracts">What Licences and Contracts Can Change</h2>
5516
5517<p>Most commercial EAs arrive under terms that prohibit reverse engineering, decompilation, disassembly, modification, or attempts to discover source code. Such language should be read rather than dismissed as boilerplate. Depending on the jurisdiction and the way the agreement was presented and accepted, it may be a binding contractual restriction. It can also specify account limits, confidentiality duties, governing law, and restrictions on transferring the softw
5517are to another person.</p>
5518
5519<p>That does not mean every clause wins in every situation. Some countries protect certain reverse-engineering activity for interoperability, error correction, security testing, or other public-policy reasons. In some legal systems, a contract cannot remove particular statutory permissions. In others, the interaction between copyright, contract, and technological-protection rules is more complicated. The existence of an exception is not a broad licence to harvest code. It is usually tied to a defined purpose, limited information, and a need that cannot reasonably be met another way.</p>
5520
5521<p>Terms should also be read alongside the purchase flow. Was the licence visible before payment? Did the buyer actively agree to it? Did the seller provide a separate negotiated agreement? Is there an email granting permission that changes the default licence? A standard web checkout does not always answer these questions cleanly. When stakes are meaningful, preserve screenshots and order confirmations rather than relying on a remembered version of a webpage.</p>
5522
5523<p>Open-source or permissively licensed code may create a very different starting point. A licence may permit inspection and modification but require attribution, publication of changes, or preservation of notices. “Free download” is not synonymous with open source. A robot offered at no cost can remain fully copyrighted and licensed under restrictive conditions.</p>
5524
5525<h2 id="legitimate-purposes">Purposes That May Support Recovery</h2>
5526
5527<p>Purpose is often the practical center of the analysis. A good-faith, constrained purpose does not guarantee legality, but it gives a project a far stronger foundation than commercial imitation. The following examples illustrate why facts matter.</p>
5528
5529<h3>Recovering the author’s own lost source</h3>
5530<p>Where the requester wrote the EA and can show that they own it, recovering a usable starting point for repair or future maintenance is ordinarily the clearest use case. The goal is continuity of that owner’s own project, not extraction of somebody else’s creative work. The recovered result may need cleanup and testing, but that technical reality does not change the ownership rationale.</p>
5531
5532<h3>Maintaining an assigned custom project</h3>
5533<p>A client with an explicit assignment of copyright or a contractual right to receive and modify source may need recovery after a developer becomes unavailable. This can be a legitimate maintenance problem, especially if the robot controls a live operational workflow. The client should keep the assignment, scope of work, and proof that the particular EX4 was delivered under that arrangement.</p>
5534
5535<h3>Compatibility and security investigation</h3>
5536<p>Some jurisdictions recognize limited paths for analysis needed to make independently created software work together, or to assess security. For example, an organization may need to understand why a licensed EA behaves unexpectedly in a controlled test environment. The scope should remain proportionate: investigate the interaction or risk at issue, avoid distributing the result, and do not turn the process into a shortcut for copying strategy logic. Legal advice is appropriate before relying on a statutory exception.</p>
5537
5538<h3>Preservation of unsupported software</h3>
5539<p>An unavailable author and an obsolete environment create a sympathetic practical problem, but abandonment is not the same as permission. A business may have a better argument for limited preservation or maintenance where it owns the work or has an enduring licence, yet it should still examine the agreement and seek consent where possible. The inability to locate a vendor is a fact, not a transfer of rights.</p>
5540
5541<img src="${NE}" alt="intellectual property protection for MQL4 source code" style="width:100%;border-radius:8px;margin:24px 0;" />
5542
5543<h2 id="uses-to-avoid">Uses That Create Serious Risk</h2>
5544
5545<p>Certain stated objectives should stop a project before any file is uploaded. A purchased EA is not raw material for a competing product. Decompiling a commercial robot to copy its entry rules, money management, naming, or implementation and then selling a similar version can create copyright, contract, unfair-competition, and confidentiality problems. Changing variable names is not a cure if the protected expression has been copied.</p>
5546
5547<p>Bypassing account, broker, expiry, or activation checks is another high-risk request. Those mechanisms are often part of the vendor’s licensing arrangement and may qualify as technological protections under local law. A user who needs the EA on a different account should request an authorised licence change or replacement from the vendor. Treating a restriction as inconvenient is not a legal basis for removing it.</p>
5548
5549<p>Publication is also a separate decision from recovery. Even if limited private examination could be justified, posting the reconstructed source to a forum, repository, chat group, or marketplace exposes it to a new set of rights claims. Distribution may harm the original vendor, reveal confidential implementation details, and exceed any narrow interoperability or research rationale. Keep access limited to people with a documented need.</p>
5550
5551<p>Finally, do not use a service as a way to distance yourself from the purpose of the request. Outsourcing the technical step does not make an unauthorised objective acceptable. A reputable provider should ask customers to represent that they have the required rights and should be able to decline requests that describe cloning, unlocking, or redistribution.</p>
5552
5553<img src="${OE}" alt="permission review before EX4 code analysis" style="width:100%;border-radius:8px;margin:24px 0;" />
5554
5555<h2 id="country-context">Why Country-Specific Law Still Matters</h2>
5556
5557<p>Online discussions often reduce this topic to a universal rule. There is no reliable universal rule. Copyright duration, contract enforceability, reverse-engineering exceptions, consumer protection, anti-circumvention law, employment rules, and the governing-law clause in a licence can differ by country. A user in one place may be subject to a contract selecting the law and courts of another. International teams can add further complexity.</p>
5558
5559<p>In the United States, discussions may involve copyright fair use, the Digital Millennium Copyright Act, and its specific provisions or exemptions. European legal frameworks have provisions dealing with decompilation for interoperability, but implementation and interpretation can still vary among member states. The United Kingdom, Canada, Australia, Japan, and other markets each have their own statutory wording and case law. None of those labels provides a safe answer without the facts.</p>
5560
5561<p>The sensible takeaway is modest: jurisdiction affects the analysis, so do not rely on an article written for a different legal system as a final answer. For a low-value personal recovery where authorship is clear, a user may simply preserve evidence and keep the result private. For a client dispute, a planned resale, a restriction-bypass issue, or a system that controls significant funds, consult counsel experienced in software and intellectual property before proceeding.</p>
5562
5563<h2 id="responsible-workflow">A Responsible Recovery Workflow</h2>
5564
5565<p>A rights-first workflow can make a legitimate project more orderly and reduce accidental overreach. The following sequence is a practical framework for readers considering <a href="/">decompile ex4 to mq4</a> options. It is not a promise that any particular activity is lawful.</p>
5566
5567<ol>
5568<li><strong>Freeze the original.</strong> Keep an untouched copy of the EX4, note where it came from, and record a checksum if the project is important. Avoid working from an unknown modified copy.</li>
5569<li><strong>
5569Collect entitlement records.</strong> Gather authorship evidence, assignments, licences, invoices, and written permissions. Identify gaps honestly.</li>
5570<li><strong>Define the minimum purpose.</strong> State whether the project is recovery, bug repair, compatibility diagnosis, or security review. Do not broaden the task after output appears.</li>
5571<li><strong>Review alternatives.</strong> Ask the author for source, an update, or a supported migration first. An authorised route is usually better than recovery.</li>
5572<li><strong>Choose a controlled method.</strong> Use a provider or process that respects confidentiality and screens for legitimate use. Limit who receives the output.</li>
5573<li><strong>Test privately.</strong> Treat recovered code as an engineering artifact that may need validation. Do not put unverified code on a live account.</li>
5574<li><strong>Preserve and restrict.</strong> Retain the project note and documents, then store output securely. Do not publish, resell, or remove controls unless rights clearly allow it.</li>
5575</ol>
5576
5577<p>Technical validation deserves its own plan. Decompiled output can require review for compiler compatibility, dependencies, broker naming, and risk controls. Readers who need the next stage can consult the site’s guide on <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">testing decompiled MQL4 before live trading</a>. Testing is not merely a performance exercise. It also helps ensure a recovery project remains a maintenance task rather than an impulsive deployment.</p>
5578
5579<img src="${FE}" alt="written agreement supporting lawful EX4 source recovery" style="width:100%;border-radius:8px;margin:24px 0;" />
5580
5581<h2 id="service-review">Reviewing the Professional-Service Option</h2>
5582
5583<p>For users with a documented, legitimate need, a professional route can be more sensible than experimenting with unknown utilities. The service at ForexMQ5 is positioned as a specialist EX4-to-MQ4 recovery option, with pricing stated from $50 per file. The review-site perspective is that its value is not simply convenience. A professional process can provide a defined intake, confidential handling expectations, and a clearer opportunity for the customer to state why they are entitled to request the work.</p>
5584
5585<p>That process does not turn a prohibited request into a permitted one, and it should not be marketed as legal advice. The customer remains responsible for the truth of their ownership or permission representation and for use after delivery. Still, screening and documented scope are meaningful advantages over sharing files casually with anonymous download sites or chat users. They align the technical service with the narrow, rights-based approach described in this guide.</p>
5586
5587<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
5588  <h3 style="margin-top:0;">Have a Documented EX4 Recovery Need?</h3>
5589  <p>ForexMQ5 is reviewed as a professional option for users who can confirm a legitimate recovery, maintenance, or authorised audit purpose. Preserve your ownership records and scope before requesting service.</p>
5590  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
5591</div>
5592
5593<p>Professional assistance is particularly attractive when the requester owns the project but lacks the time or specialist experience to assess output quality. It is less appropriate where the facts are disputed, the only goal is to unlock a vendor-controlled product, or the requester cannot explain how they acquired the rights. In those cases, the most responsible recommendation is to stop and resolve permission first.</p>
5594
5595<div style="background:#fff8ed;border:1px solid #f0d4a8;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
5596  <h3 style="margin-top:0;">Use a Rights-First Checklist</h3>
5597  <p>Before selecting a technical route, confirm authorship or written authority, keep the relevant agreement, define the limited purpose, and plan private handling of any recovered source.</p>
5598  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Review ForexMQ5.com</a>
5599</div>
5600
5601<h2 id="questions">Questions MT4 Users Commonly Ask</h2>
5602
5603<h3>Can a buyer recover source just because the EA did not perform well?</h3>
5604<p>Usually, disappointment alone does not create a source-code right. The licence and local law remain relevant. A buyer who suspects harmful behavior may have a stronger reason to seek a narrowly focused security assessment, but should avoid assuming that poor performance permits copying or modification.</p>
5605
5606<h3>Does personal use make recovery automatically legal?</h3>
5607<p>No. Personal use can be a relevant fact, especially where there is no distribution, but it does not override copyright, contract terms, or anti-circumvention rules. Ownership and purpose remain central.</p>
5608
5609<h3>What if no licence text can be found?</h3>
5610<p>The absence of visible terms does not remove copyright. It may mean there is less evidence of a contractual restriction, but it does not establish permission to reproduce or distribute a third party’s software. Preserve the circumstances of acquisition and seek consent if possible.</p>
5611
5612<h3>Can recovered source be given to another programmer for repairs?</h3>
5613<p>That depends on the rights held and the agreement. An owner may be able to engage a contractor under confidentiality for maintenance. A mere licensee may not. Keep the contractor’s access limited, use a written scope, and do not assume that technical necessity resolves copyright questions.</p>
5614
5615<h3>Can a professional provider decide whether a request is legal?</h3>
5616<p>A provider can screen requests and set terms, but it cannot give a universal legal ruling for every country and factual situation. The requester should seek local counsel when the answer is uncertain or the consequences are substantial.</p>
5617
5618<h2 id="conclusion">The Practical Conclusion</h2>
5619
5620<p>EX4 source recovery should be treated as a rights-and-purpose question before it becomes a software question. The strongest cases involve an original author, a client with a clear written assignment, or another requester with express authority and a tightly defined maintenance or review need. The weakest cases involve cloning, unlocking, resale, or public sharing of someone else’s code.</p>
5621
5622<p>Document the chain of entitlement, read the agreement, keep the project narrow, and obtain local legal advice where the facts are disputed or commercially important. For clearly legitimate cases, the professional service at ForexMQ5 is reviewed as a practical technical option, provided the customer can truthfully confirm their authority and treats the recovered material as confidential. Those safeguards protect both the original creator’s work and the MT4 user trying to preserve a system they are genuinely entitled to maintain.</p>
5623    `},{slug:"recover-lost-mq4-expert-advisor-source-code",title:"How to Recover Lost MQ4 Expert Advisor Source Code: A Practical 2026 Review Guide",metaTitle:"Recover Lost MQ4 Source Code in 2026 | EX4 EA Recovery Review",metaDescription:"Recover lost MQ4 source systematically, assess EX4 reconstruction, validate the result, and turn recovered files into a controlled, testable first release.",keywords:"recover lost mq4 source code, lost expert advisor source code, recover ex4 source code, EX4 to MQ4 recovery, MT4 EA source recovery",excerpt:"A missing MQ4 file does not automatically mean a trading robot is gone for good. Follow a careful recovery sequence, assess an EX4 reconstruction, validate the output, and keep the recovered source separate from its first approved release.",date:"August 18, 2025",dateISO:"2025-08-18",lastModified:"September 24, 2026",lastModifiedISO:"2026-09-24",readTime:"16 min read",featuredImage:Ou,imageAlt:"MT4 developer planning recovery of lost MQ4 source code",tableOfContents:[{id:"triage-the-loss",title:"Start With Triage, Not Panic"},{id:"map-ea-assets",title:"Map the EA Assets That Still Exist"},{id:"recover-original",title:"Recover the Original MQ4 First"},{id:"check-history",title:"Search Version History and Old Environments"},{id:"ex4-path",title:"When an EX4 Becomes the Recovery Starting Point"},{id:"review-provider",title:"How This Review Evaluates a Recovery Provider"},{id:"diy-boundaries",title:"How to Decompile EX4 to MQ4 Yourself"},{id:"validate-output",title:"Validate Recovered Code Before Trading"}
5623,{id:"choose-route",title:"Choose a Route With a Simple Decision Table"},{id:"build-resilience",title:"Build a Source Code Resilience System"},{id:"first-release",title:"Turn Recovered Source Into a Controlled First Release"}],content:`
5624<p>Finding an Expert Advisor that still runs while its MQ4 file has disappeared creates a peculiar kind of risk. The robot may be attached to charts, producing familiar entries, and earning a place in a trading routine. Yet a broker change, a symbol adjustment, or one small bug can suddenly require a change that nobody can make. For an owner who wrote the EA, bought it with source rights, or has permission to maintain it, the immediate question is not merely where a file went. It is how to regain a dependable, testable development asset.</p>
5625
5626<p>This independent review guide approaches lost MT4 source code as a recovery project. It begins with the low risk ways to locate the original, then explains how to preserve evidence, use storage history, and assess an EX4 reconstruction route when no MQ4 copy survives. The service at ForexMQ5 is discussed as a professional option rather than as the publisher of this guide. The aim is to help readers avoid paying for work that an overlooked backup could solve, while also avoiding the far greater cost of rebuilding a working EA from fragments.</p>
5627
5628<img src="${Ou}" alt="MT4 developer organizing a lost MQ4 source recovery plan" style="width:100%;border-radius:8px;margin:24px 0;" />
5629
5630<h2 id="triage-the-loss">Start With Triage, Not Panic</h2>
5631
5632<p>A source loss can be caused by deletion, a failed migration, a sync conflict, a damaged drive, or a handover that never included source in the first place. Those situations need different responses. The first rule is to avoid changing the evidence. If the loss followed deletion or drive trouble, do not install recovery software onto the same affected disk, create new folders there, or continue compiling files on it. New writes can reuse the very storage blocks that may still contain the MQ4 file.</p>
5633
5634<p>Instead, make a short incident record. Note the EA name, the last known folder, approximate last edit date, PC name, terminal login, storage services used, and every person who may have received a copy. Save the currently functioning EX4, any SET files, logs, presets, DLLs, indicators, screenshots, and backtest reports to a 
5634separate location. These items are not substitutes for source, but they make later verification much stronger.</p>
5635
5636<p>It also helps to state the ownership position at the outset. A trader who commissioned code and retained contractual rights is in a different position from a buyer licensed only to run a compiled product. Technical possibility does not settle permission. If the license is unclear, obtain written consent or appropriate legal advice before asking anyone to inspect the binary. A reputable reviewer should treat this as a normal due diligence step, not an inconvenience.</p>
5637
5638<h3>Preserve a working reference</h3>
5639<p>Before moving files, copy the EX4 from the active terminal and record its file size, modification time, and hash if practical. Export the input settings that are actually in use. Capture the chart symbol, timeframe, account type, broker suffix, and any dependencies shown in the Experts or Journal tabs. A recovered MQ4 can later compile perfectly but behave differently because an input, symbol name, or companion indicator was missed. The running installation is the baseline against which the recovered result must be judged.</p>
5640
5641<h3>Separate recovery from repair</h3>
5642<p>Do not edit the only EX4, rename it repeatedly, or begin changing live settings while investigating. Recovery asks, “What was the original program?” Repair asks, “What should the program do next?” Keep those jobs separate. First obtain and validate a source baseline. Only then create a new branch or copy for modernization, broker adaptation, or strategy changes.</p>
5643
5644<h2 id="map-ea-assets">Map the EA Assets That Still Exist</h2>
5645
5646<p>Many searches fail because the owner looks only for one exact filename. MT4 projects accumulate alternate names, test versions, copied folders, and compiled variants. A proper asset map widens the search without turning it into chaos. Search all local and removable storage for <code>.mq4</code>, then search for the strategy name, developer name, ticket prefixes, and distinctive input labels. Include Experts, Indicators, Scripts, Libraries, Downloads, Desktop, Documents, archived ZIP files, and old project folders.</p>
5647
5648<p>MetaTrader installations can be deceptive. The executable may sit in one directory while the terminal data folder sits under the user profile. From MT4, the File menu can open the data folder, where MQL4 contains Experts, Indicators, Include, Libraries, Scripts, Files, and Presets. Check every terminal installation ID, not just the one used today. A broker reinstall can leave an older data directory untouched, with a complete MQ4 project still inside it.</p>
5649
5650<ul>
5651<li><strong>Compiled file:</strong> keep the EX4 that is known to work, plus any older EX4 copies.</li>
5652<li><strong>Settings:</strong> collect SET files, screenshots of Inputs, and optimization reports.</li>
5653<li><strong>Dependencies:</strong> list indicators, include files, libraries, and DLLs that the EA calls.</li>
5654<li><strong>Behavior evidence:</strong> retain reports, trade exports, screenshots, and journal messages.</li>
5655<li><strong>Location evidence:</strong> record old PCs, VPS instances, cloud accounts, email accounts, and contractors.</li>
5656</ul>
5657
5658<p>This inventory matters whether the original source is found or reconstruction is needed. It also provides context for a later code review. Readers who are unsure what a compiled file represents may find the site’s explanation of <a href="/blog/ex4-files-explained-for-mt4-users">what an EX4 file is and what it contains</a> useful before proceeding.</p>
5659
5660<img src="${QE}" alt="organized file rescue inventory for an MT4 Expert Advisor" style="width:100%;border-radius:8px;margin:24px 0;" />
5661
5662<h2 id="recover-original">Recover the Original MQ4 First</h2>
5663
5664<p>The original MQ4 is always the preferred outcome. It carries meaningful names, comments, formatting, and the author’s intended organization. A compiled file can preserve operational logic, but it does not preserve every piece of development context. The recovery sequence below prioritizes sources that are least likely to alter or overwrite data.</p>
5665
5666<h3>Look in the obvious places carefully</h3>
5667<p>
5667Check Recycle Bin or Trash, then use a full extension search across mounted drives. Search by date range as well as name. An EA called GoldTrend might exist as GoldTrend_v3.mq4, final2.mq4, or a generic test file. Review editor recent-file lists, Windows Quick Access, shell history, and archive folders. If a file was emailed to a client, it may be in Sent Items even if the local project directory is gone.</p>
5668
5669<h3>Use filesystem recovery safely</h3>
5670<p>When deletion occurred on a healthy drive, recovery utilities can locate file entries or raw file fragments that have not been overwritten. The safest approach is to stop using the drive, make an image where possible, and scan the image or attach the drive to another machine. Restore results to a different drive. A raw result may have a changed filename or partial content, so inspect candidates in MetaEditor rather than trusting names alone.</p>
5671
5672<p>Solid state drives deserve extra caution. TRIM and normal background activity can reduce the chance that deleted data remains readable. Physical clicking, unreadable sectors, or a drive that vanishes from the system calls for a data recovery specialist, not repeated power cycles and improvised tools. No guide can promise a retrieval rate because the storage state determines the result.</p>
5673
5674<h3>Ask people and providers early</h3>
5675<p>Former developers, collaborators, VPS providers, and IT support staff may have retained legitimate copies or snapshots. Send a precise, polite request with the project name and date range. For a custom project, ask whether they have the MQ4, includes, build notes, and the final settings package. A vague request for “the robot code” is less likely to succeed than an organized request that proves the owner understands the project.</p>
5676
5677<img src="${zE}" alt="step by step checklist for recovering an MQ4 Expert Advisor file" style="width:100%;border-radius:8px;margin:24px 0;" />
5678
5679<h2 id="check-history">Search Version History and Old Environments</h2>
5680
5681<p>Recovery is often a history problem rather than a deleted-file problem. Cloud services, backup software, and source control may retain earlier versions that no longer appear in the current folder. Work from the asset map and log each place checked so the same account is not searched three times while an old laptop is forgotten.</p>
5682
5683<h3>Cloud and backup history</h3>
5684<p>Open version history in OneDrive, Dropbox, Google Drive, and any business storage product that synchronized the project. Look not only for the MQ4 but for ZIP archives and whole MQL4 folders. Check backup drive catalogs, NAS snapshots, Windows Previous Versions, and backup application retention settings. Restore candidates into a quarantine folder first, preserving their original timestamp and source location in a note.</p>
5685
5686<h3>Git and local development traces</h3>
5687<p>A local Git repository can survive even when the checked-out file is gone. Inspect repository history, branches, stashes, and ignored build folders. Git hosting accounts may also have private repositories, forks, or archived copies. MetaEditor backups, temporary files, code snippets in note applications, and build folders can provide clues. If a partial MQ4 is found, compare it with the working EX4 through compilation and testing before declaring recovery complete.</p>
5688
5689<p>Old hardware deserves a systematic pass. Retired laptops, a prior VPS disk, USB sticks, and an external drive used for a migration are frequent sources of success. Connect an old disk read-only where practical. Search its user profiles and terminal data locations, then copy any candidate project as a whole. A complete folder with includes and presets is considerably more useful than a single source file without its dependencies.</p>
5690
5691<img src="${WE}" alt="developer reviewing historical MT4 files and backup locations" style="width:100%;border-radius:8px;margin:24px 0;" />
5692
5693<h2 id="ex4-path">When an EX4 Becomes the Recovery Starting Point</h2>
5694
5695<p>After original-source options have been exhausted, the EX4 can become the practical starting point for reconstruction. This is relevant both to owners who lost their own MQ4 and to clients entitled to source but who were handed only a compiled EA. An <a href="/">ex4 to mq4 decompiler</a> process seeks to recreate readable MQL4 from the compiled program structure. It should be viewed as reconstruction, not as a guarantee of a character-for-character return of the author’s workspace.</p>
5696
5697<p>The likely limits should be understood upfront. Original comments, formatting, descriptive variable names, and development notes generally cannot be recovered from a compiled artifact. Depending on build, protection, and program complexity, output may require cleanup before it compiles or matches the reference behavior. Conversely, the core execution flow, calculations, indicator calls, order logic, and inputs can provide a valuable maintainable baseline when the alternative is starting with no code at all.</p>
5698
5699<p>For a broader explanation of realistic output quality, see the related guide on <a href="/blog/how-to-read-decompiled-mq4-code-from-ex4">what decompiled MQ4 source code looks like</a>. That context helps owners distinguish cosmetic imperfections from a meaningful functional difference.</p>
5700
5701<img src="${BE}" alt="successful recovery review of an Expert Advisor source file" style="width:100%;border-radius:8px;margin:24px 0;" />
5702
5703<h2 id="review-provider">How This Review Evaluates a Recovery Provider</h2>
5704
5705<p>When evaluating professional reconstruction, this review site favors a provider that makes the process understandable before payment and treats proprietary trading logic carefully. ForexMQ5 is presented as the primary professional recommendation because its stated service model is focused on EX4 to MQ4 work, with pricing starting from $50 per file, confidential handling, and a reported 95% recovery rate. Those claims should still be checked against the reader’s specific build, file condition, and requirements rather than treated as a substitute for testing.</p>
5706
5707<p>Useful questions for any provider include these:</p>
5708<ul>
5709<li>Can they explain the expected deliverable, limitations, turnaround range, and price before receiving a file?</li>
5710<li>Do they address the relevant MT4 build and disclose whether protection or obfuscation affects the work?</li>
5711<li>What confidentiality and deletion practices apply to the uploaded EX4 and recovered source?</li>
5712<li>Will they investigate a source file that does not compile or fails an agreed validation check?</li>
5713<li>Can the customer retain a clear record of rights, instructions, and the delivered files?</li>
5714</ul>
5715
5716<p>A review should not imply that recovery alone makes a robot safe to trade. A responsible provider supplies a technical starting point. The owner still needs to compile, inspect, backtest, and demo-test it. Readers who want a professional route can review the provider directly through the button below.</p>
5717
5718<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
5719  <h3 style="margin-top:0;">Need a Professional EX4 Recovery Assessment?</h3>
5720  <p>This review identifies ForexMQ5 as a leading specialist option for eligible owners who need MQ4 reconstruction from a working EX4. Review the current scope, pricing, and submission requirements before proceeding.</p>
5721  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com &rarr;</a>
5722</div>
5723
5724<h2 id="diy-boundaries">How to Decompile EX4 to MQ4 Yourself</h2>
5725
5726<p>DIY work can be sensible as a learning exercise or for a simple, older-build file, but it is often underestimated. Free automated tools may produce fragments, generic labels, or output that cannot be compiled on modern builds. Manual investigation can involve binary inspection and debugging workflows, often discussed around x64dbg and ScyllaHide. That route requires real reverse engineering skill, time, and a controlled test environment.</p>
5727
5728<p>The decision is economic as well as technical. If the EA is simple and there is no deadline, a technically capable owner may learn enough to assess the file. If the EA has years of logic, multiple dependencies, or an active strategy that needs maintenance, hours of uncertain manual work can exceed the cost of an experienced service. Never run unknown tools against a production terminal, and never treat output from an automated utility as validated source.</p>
5729
5730<p>For readers comparing methods, the homepage review of an <a href="/">ex4 decompiler</a> explains the distinction this site makes between free tools, manual analysis, and professional reconstruction. The professional option remains the recommended route for modern or business-critical files, while DIY is a secondary option with clear limits.</p>
5731
5732<img src="${_E}" alt="reviewer receiving recovered MQL4 source code for validation" style="width:100%;border-radius:8px;margin:24px 0;" />
5733
5734<h2 id="validate-output">Validate Recovered Code Before Trading</h2>
5735
5736<p>Recovery is complete only when the source has passed a validation plan. Start in an isolated copy of MT4. Compile the MQ4 and retain every warning and error. Resolve missing include files and dependencies without overwriting the original recovered output. Then compare the compiled result with the reference EX4 using the same broker, symbol, timeframe, inputs, modeling settings, and historical range.</p>
5737
5738<ol>
5739<li><strong>Compile cleanly:</strong> document compiler messages and every library or include required.</li>
5740<li><strong>Inspect inputs:</strong> compare parameter names, defaults, magic numbers, lot rules, stops, and time filters against the reference installation.</li>
5741<li><strong>Backtest equivalent cases:</strong> use several periods, not one favorable report, and compare trade timing, direction, management, and closed results.</li>
5742<li><strong>Forward-test on demo:</strong> observe spread handling, symbol suffixes, execution errors, and live tick behavior.</li>
5743<li><strong>Review safety controls:</strong> confirm lot sizing, stop-loss behavior, maximum order count, and error handling before any live use.</li>
5744</ol>
5745
5746<p>A recovered program may expose logic that has been running unnoticed for years. That is an opportunity for an independent code review. It is also a reason not to rush it onto a funded account. Preserve the recovered baseline, document every later modification, and keep performance claims grounded in testing rather than assumptions.</p>
5747
5748<h2 id="choose-route">Choose a Route With a Simple Decision Table</h2>
5749
5750<table style="width:100%;border-collapse:collapse;margin:16px 0;">
5751<thead><tr style="background:#f0f4ff;"><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Situation</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Best first move</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Next decision</th></tr></thead>
5752<tbody>
5753<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">MQ4 was recently deleted</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Stop writes and recover from an image or separate machine.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Validate any file found against the known EX4.</td></tr>
5754<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Migration or account change caused the loss</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Search old terminals, cloud history, and retired devices.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Collect full project folders and settings.</td></tr>
5755<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Only a working EX4 remains</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Confirm ownership and preserve the binary reference.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Compare DIY limits with a professional assessment.</td></tr>
5756<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Recovered MQ4 compiles but differs in tests</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Identify missing dependencies and input differences.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Do not deploy until behavior is explained.</td></tr>
5757</tbody>
5758</table>
5759
5760<h2 id="build-resilience">Build a Source Code Resilience System</h2>
5761
5762<p>Once the source is back, turn the incident into a durable process. Use the 3-2-1 principle: maintain at least three copies, on two types of storage, with one copy outside the main machine. For an EA, that can mean a working repository, an encrypted backup drive, and a private remote repository or managed cloud backup. The point is independence. A sync folder alone is not a complete backup if deleti
5762on synchronizes everywhere.</p>
5763
5764<p>Put the whole project under version control, including source, include files, presets, test notes, and a short README within the private project. Commit meaningful changes with messages that explain why a parameter or rule changed. Tag versions placed into demo or live use. Monthly, restore a project copy to another folder and compile it. This turns backup verification from a hopeful claim into a repeatable check.</p>
5765
5766<p>Finally, make ownership and handover explicit for future work. A contract should say whether MQ4 source, dependencies, build instructions, and rights transfer are included. A final handover should be tested before payment is fully closed. These habits cost little compared with another emergency recovery project.</p>
5767
5768<h2 id="first-release">Turn Recovered Source Into a Controlled First Release</h2>
5769
5770<p>Recovery creates a new maintenance baseline, not proof that the recovered file is identical to the original project. Keep the delivered MQ4 and any untouched recovery output in a read-only archive. Record the delivery date, file names, sizes, hashes where practical, compiler build, and any notes supplied with the handover. Do not clean up names or formatting in that archival copy.</p>
5771
5772<p>Make a separate working copy for compilation and annotation. Capture the original EX4's visible inputs and dependencies, compile the MQ4 in a clean test terminal, and document every warning, error, and missing component. Compare expected behavior using the same symbol, timeframe, settings, and available data. If there is no reliable reference behavior, mark that limitation instead of calling the result equivalent.</p>
5773
5774<ol>
5775  <li><strong>Archive:</strong> preserve the received files and their provenance unchanged.</li>
5776  <li><strong>Build:</strong> compile a working copy and retain the compiler log and toolchain details.</li>
5777  <li><strong>Compare:</strong> test known behaviors against the original EX4 or a written baseline.</li>
5778  <li><strong>Approve:</strong> have the authorized owner review open issues before any demo or live deployment.</li>
5779  <li><strong>Release:</strong> label the approved source, compiled EX4, preset, and test record with one release identifier.</li>
5780</ol>
5781
5782<p>This separation makes it possible to distinguish recovered material from later edits. It also gives the next maintainer a specific version to reproduce, inspect, or roll back to if a change has an unexpected effect.</p>
5783
5784<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
5785  <h3 style="margin-top:0;">Only the EX4 Is Left?</h3>
5786  <p>For owners with permission to recover and maintain their EA, ForexMQ5 offers a professional route worth evaluating after original-source searches have been completed.</p>
5787  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Review ForexMQ5.com Options &rarr;</a>
5788</div>
5789    `},{slug:"ex4-files-explained-for-mt4-users",title:"EX4 Files Explained: How MetaTrader 4 Programs Work and What Can Be Recovered",metaTitle:"EX4 Files Explained for MT4 Users: Format, Recovery and Risks",metaDescription:"Learn what an EX4 contains, what source recovery may reconstruct, and why dependencies, settings, build history, and project files still need separate verification.",keywords:"what is an ex4 file, ex4 file explained, ex4 vs mq4, MetaTrader 4 compiled file, recover mq4 source",excerpt:"An EX4 is the compiled program that makes an MT4 robot, indicator, script, or library run. Learn what may be recovered, what compilation removes, and why recovered source is not automatically a complete project.",date:"September 3, 2025",dateISO:"2025-09-03",lastModified:"September 24, 2026",lastModifiedISO:"2026-09-24",readTime:"16 min read",featuredImage:Qs,imageAlt:"diagram explaining the internal structure of a MetaTrader 4 EX4 file",tableOfContents:[{id:"ex4-purpose",title:"The Job an EX4 File Performs"},{id:"source-and-output",title:"MQ4 Source and EX4 Output"},{id:"where-files-live",title:"Where MT4 Uses EX4 Files"},{id:"binary-clues",title:"Useful Clues Stored in the Binary"}
5789,{id:"program-categories",title:"Four Kinds of EX4 Program"},{id:"build-history",title:"Why Build History Matters"},{id:"ownership-decisions",title:"When Recovery Is a Sensible Decision"},{id:"recovery-reality",title:"What Source Recovery Can and Cannot Deliver"},{id:"safe-review",title:"A Safe Review Process for an Unknown File"},{id:"next-step",title:"Choosing the Next Step"},{id:"project-boundary",title:"What a Recovered EX4 Does Not Include"}],content:`
5790<p>An EX4 file is the working form of a MetaTrader 4 program. A trader may know it as the file that appears under Expert Advisors, Indicators, Scripts, or Libraries in the Navigator panel. A developer may know it as the artifact created after pressing Compile in MetaEditor. In either case, the file is important because it contains the instructions MT4 needs to run a trading tool, while keeping the original MQL4 writing out of ordinary view.</p>
5791
5792<p>That distinction explains a common moment of confusion. A user can attach an EX4 robot to a chart, change its inputs, see orders or alerts, and confirm that it is doing something. Yet opening the same file in a text editor produces unreadable characters. The file is neither broken nor empty. It is compiled data intended for the MetaTrader runtime, not a document intended for a human reader.</p>
5793
5794<p>This review-site guide examines the format from the owner's perspective. It is not a promise that every binary can be turned back into its original project. Instead, it explains what an EX4 represents, how it differs from MQ4 source, which observations are useful before a recovery request, and why professional assessment is usually more informative than relying on a random download. It also helps buyers, account managers, and developers decide whether the file in front of them has enough value to justify closer work.</p>
5795
5796<img src="${Qs}" alt="diagram explaining sections within a MetaTrader 4 EX4 compiled file" style="width:100%;border-radius:8px;margin:24px 0;" />
5797
5798<h2 id="ex4-purpose">The Job an EX4 File Performs</h2>
5799
5800<p>MetaTrader 4 does not execute an MQ4 text file directly on a chart. The platform needs a compiled program that it can load, validate, and run in its own environment. The EX4 is that program. It contains instructions produced by the MQL4 compiler, together with data that lets MT4 expose inputs and recognize how the program should behave.</p>
5801
5802<p>The extension should not be confused with a Windows EXE. An EX4 cannot normally be launched by double-clicking it in an operating system. It is made for MT4, which supplies the chart, price feed, account functions, event loop, and trading APIs. When an event occurs, such as a new tick or timer interval, MT4 calls the appropriate compiled logic. The program can calculate indicators, draw chart objects, inspect open positions, print messages, or request trade operations through the terminal.</p>
5803
5804<p>Compilation is useful to software publishers for practical reasons. It creates a package that is straightforward to install and distribute. It also makes casual copying of a strategy far less convenient than sending readable source. A vendor can give customers a functioning robot without handing over design notes, comments, and every meaningful name used during development. That is the standard distribution model for many commercial EAs, although the exact source rights should always be settled in the purchase agreement.</p>
5805
5806<p>For an owner, an EX4 therefore has two identities. It is an executable component that may have operational value today, and it is a partial record of a prior development project. The first identity is obvious when the file runs. The second becomes relevant after a lost backup, a vendor dispute, an audit need, or a planned migration. The quality of an eventual recovery depen
5806ds on the file's age, compiler family, protections, dependencies, and complexity.</p>
5807
5808<h2 id="source-and-output">MQ4 Source and EX4 Output</h2>
5809
5810<p>MQ4 is the source file format for traditional MQL4 development. It is readable text containing declarations, calculations, event handlers, comments, and formatting selected by the programmer. An MQ4 file can be opened in MetaEditor, inspected in a code editor, altered, and compiled again. It represents intent as well as behavior. A carefully maintained source project may include version notes, function names that describe a task, and comments explaining why a rule exists.</p>
5811
5812<p>EX4 is the compiled output. During compilation, the tool checks syntax and translates source expressions into instructions understood by the MT4 execution environment. It also removes or transforms much of the information that made the source comfortable to read. The resulting program is geared toward operation, not teaching another person how it was built.</p>
5813
5814<table style="width:100%;border-collapse:collapse;margin:16px 0;">
5815<thead><tr style="background:#f0f4ff;"><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Question</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">MQ4</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">EX4</th></tr></thead>
5816<tbody>
5817<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Can a person read it directly?</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Usually yes</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">No, it is binary</td></tr>
5818<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Can MT4 attach it to a chart?</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Only after compiling</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Yes</td></tr>
5819<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Does it preserve comments?</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Yes</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">No</td></tr>
5820<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Can it be edited as a project?</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Yes</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Not directly</td></tr>
5821<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">What is its main role?</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Development and maintenance</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Distribution and execution</td></tr>
5822</tbody>
5823</table>
5824
5825<p>A helpful analogy is a recipe and a prepared meal. The recipe says what the cook called each ingredient and may include notes for future changes. The meal proves that ingredients were combined in a particular way, but it does not preserve every explanatory note. The analogy is imperfect because program logic can often be analyzed in more detail than a meal, but it captures why recovered code should be viewed as a reconstruction rather than a time capsule.</p>
5826
5827<p>Anyone who owns both formats should protect the MQ4 first. Keep versioned copies away from the trading terminal, retain related include files and set files, and record the compiler environment. Decompilation is a contingency measure, not a substitute for basic source control. When only an EX4 remains, a capable <a href="/">ex4 decompiler</a> assessment can still establish whether a usable MQL4 reconstruction is realistic.</p>
5828
5829<img src="${Fu}" alt="MetaTrader 4 trading robot files showing the difference between EX4 and MQ4" style="width:100%;border-radius:8px;margin:24px 0;" />
5830
5831<h2 id="where-files-live">Where MT4 Uses EX4 Files</h2>
5832
5833<p>The same extension appears in several MT4 folders because the platform supports several kinds of program. That shared extension does not mean every EX4 should be handled in the same way. Location and chart behavior give useful early clues about the file's purpose.</p>
5834
5835<p>An Expert Advisor typically lives in the Experts area and stays active while attached to a chart. It may react to ticks, use timers, manage positions, or simply issue alerts. A custom indicator normally belongs under Indicators and calculates values displayed in a separate window or over price. A script is intended for a one-time job, such as closing orders or exporting information. A library provides reusable functions to another program and may not appear as something attachable at all.</p>
5836
5837<p>Before moving files, a prudent user should record the original name, folder, size, modified date, and any neighboring files with similar names. A robot may rely on a custom indicator, an include-derived configuration, a DLL, a preset file, or a licensing component. The EX4 alone can be meaningful, but it may not explain every behavior observed on a live chart. Copy the original to a safe folder rather than renaming or recompiling it in place.</p>
5838
5839<p>The distinction also affects testing after recovery. An EA should be compared for signals, order handling, and timing. An indicator should be compared visually and numerically across representative bars. A script needs a controlled task and a clear before-and-after state. A library may require the calling program before it can be evaluated at all. Identifying the category early prevents an unrealistic expectation that a single file can recreate an entire trading installation.</p>
5840
5841<h2 id="binary-clues">Useful Clues Stored in the Binary</h2>
5842
5843<p>Compiled does not mean featureless. An EX4 contains a structured representation that MT4 must be able to interpret. Analysis begins by recognizing those structures, rather than treating every byte as mysterious noise. The details vary across compiler generations, but several kinds of information commonly matter.</p>
5844
5845<h3>Header and format markers</h3>
5846<p>The beginning of a compiled file contains identifying information and format data. It can indicate that the file belongs to the MQL4 family and can help place it within a compiler era. This information is valuable because build history changes the available analysis methods. It is not a guarantee of recovery quality, but it gives a reviewer a grounded place to start.</p>
5847
5848<h3>Inputs and visible labels</h3>
5849<p>Many EAs and indicators expose parameters in the MT4 properties window. Lot settings, magic numbers, time filters, risk controls, colors, and alert switches may remain observable because the terminal needs to present them to the user. These labels can reveal the program's operating surface. They do not necessarily explain the decision rules behind a setting, but they are excellent evidence for later validation.</p>
5850
5851<h3>Text and resources</h3>
5852<p>Messages, symbol names, object labels, URLs, error text, and interface strings may be present in some form. Embedded images, sounds, or resource data may also exist. A string alone is not proof of a program's full intention. For example, a mention of a currency pair does not prove a strategy only trades that pair. Still, text fragments can help distinguish a trade manager from a signal tool or an account utility.</p>
5853
5854<h3>Execution logic</h3>
5855<p>The most valuable portion is the instruction stream that expresses calculations, comparisons, branches, loops, and calls into the platform. It is not readable MQL4 in its stored form. Recovery work attempts to map that behavior into source constructs that a developer can understand and compile. The outcome must then be reviewed as code and tested as behavior, because a mechanically plausible listing is not automatically a maintainable project.</p>
5856
5857<img src="${Qu}" alt="visual comparison between compiled EX4 binary data and readable MQ4 source code" style="width:100%;border-radius:8px;margin:24px 0;" />
5858
5859<h2 id="program-categories">Four Kinds of EX4 Program</h2>
5860
5861<p>Expert Advisors receive the most attention because they can make trading decisions. Their event handlers often comb
5861ine market data, position state, money-management rules, and safeguards. A small EA can still be deceptively important if it controls a large account, while a large EA can be mostly interface and reporting code. File size alone is not a measure of strategic value.</p>
5862
5863<p>Indicators are often requested for a different reason. Their owner may want to see the calculation behind a visual signal, repair a display issue, or adapt the logic to another timeframe. They can contain complex buffer calculations and chart drawing rules, but they usually do not place orders themselves. Separating indicator behavior from EA behavior is important during an audit.</p>
5864
5865<p>Scripts are short-lived tools. They run a requested task and finish, which may make their flow easier to observe. That does not make every script harmless. A script that modifies orders or account settings deserves the same careful testing as an EA. Libraries are shared modules. They may contain important calculations, but their true role can only become clear when the dependent EX4 is available too.</p>
5866
5867<p>For readers who need to evaluate a tool before relying on it, the separate guide to <a href="/blog/purchased-forex-ea-security-audit-checklist">auditing a purchased forex EA</a> offers a practical behavioral checklist. Source analysis and live behavior should inform each other. Neither one alone is a complete security review.</p>
5868
5869<h2 id="build-history">Why Build History Matters</h2>
5870
5871<p>MT4 has existed through many compiler changes. Older files and newer files can share the EX4 extension while having materially different internal arrangements. That history is one reason generic claims about “an EX4 decompiler” are misleading. A method that produces useful output for a very old file may fail completely on a modern one.</p>
5872
5873<p>Early compiler generations are generally more familiar to public tools and researchers. Some of these files preserve structures that can be translated with relatively direct techniques. Later builds changed the execution model and compiler output, making casual automated conversion much less dependable. Modern files may also combine the ordinary difficulty of their format with vendor-added obfuscation or encryption.</p>
5874
5875<p>The right question is not simply “What build is installed on this computer?” A file could have been compiled years earlier and copied onto a current terminal. The better question is what family of format the file itself represents, alongside what can be learned from its environment. A reviewer may use header information, installation history, and observable behavior to form an estimate. The article on <a href="/blog/ex4-mt4-build-detection-guide">identifying an MT4 build version from an EX4</a> explains the evidence in more depth.</p>
5876
5877<p>Build history also affects cost and time. Automated tools can be a reasonable experiment for a disposable old-build file where output is only being used as a rough reference. They are a poor basis for high-stakes decisions about a current commercial robot. A result that compiles but silently reverses a condition, omits a dependency, or misreads order handling can be more dangerous than no result at all.</p>
5878
5879<img src="${Wu}" alt="technical educator explaining how MetaTrader 4 build versions affect EX4 analysis" style="width:100%;border-radius:8px;margin:24px 0;" />
5880
5881<h2 id="ownership-decisions">When Recovery Is a Sensible Decision</h2>
5882
5883<p>Source recovery makes the most sense when the owner has a legitimate reason to need maintainable code and the EX4 has meaningful operational value. The familiar case is a developer whose laptop failed after an EX4 was delivered to a client. Another is a business that commissioned a robot, paid for source delivery, and now holds only the compiled version. It can also help an account manager document inherited automation before a migration or risk review.</p>
5884
5885<p>Modification is another valid reason. An old robot may need updated symbol handling, a new broker suffix, a timing fix, or a risk rule suitable for a changed account. Those tasks require more than changing a visible input. They require a codebase that a developer can inspect, test, and improve. In that scenario, recovery can cost substantially less than rebuilding a proven tool from zero, while still requiring an honest evaluation of the recovered result.</p>
5886
5887<p>Auditing matters too. A compiled tool should never be trusted merely because it loads successfully. Owners can observe permissions, journal output, inputs, order activity, and network-related settings in a controlled environment. Recovered source can add context, but it does not eliminate the need to test. A rational process treats the original binary as evidence and compares it with the reconstructed code.</p>
5888
5889<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
5890  <h3 style="margin-top:0;">Need an Expert View of an EX4 File?</h3>
5891  <p>ForexMQ5 is reviewed as the primary professional option for owners who need MQL4 recovery assessed across MT4 build families.</p>
5892  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com &rarr;</a>
5893</div>
5894
5895<h2 id="recovery-reality">What Source Recovery Can and Cannot Deliver</h2>
5896
5897<p>Compilation permanently removes some information. Comments are normally gone. Original whitespace and formatting are gone. Local names may be shortened, replaced, or no longer recoverable in a useful form. A thoughtful developer's explanation of why a rule was added is not part of the executable behavior and should not be expected to reappear.</p>
5898
5899<p>What can remain is the logic needed for execution: arithmetic, conditions, event flow, platform calls, parameters, and many relationships between values. A good recovery result makes those relationships legible enough for a developer to work with. It may need renamed variables, grouped functions, explanatory comments written during the review, and cleanup before it resembles a maintainable project.</p>
5900
5901<p>Obfuscation changes the workload. It can introduce pointless operations, confusing branches, encoded text, or deliberately unhelpful names. In stronger cases, the author has added a custom layer designed to resist analysis. These measures do not make a file magically unknowable, but they can make the result incomplete, costly, or unsuitable for modification. A trustworthy provider should describe this uncertainty instead of claiming universal success.</p>
5902
5903<p>That is why this site positions a professional <a href="/">ex4 to mq4</a> review as the sensible primary path for files with real value. ForexMQ5 is presented as a specialist service rather than an instant online converter. Its stated starting price is $50 per file, and its published process is intended for the build differences and edge cases that free utilities often do not address. The service should still be judged by the clarity of its communication, deliverables, and testing guidance for the specific file.</p>
5904
5905<p>A recovered MQ4 file should be compiled in a separate environment and tested on a demo account or historical data before any live deployment. Compare visible inputs, chart markings, logs, trade timing, and order parameters. If the original still runs, use it as a behavioral reference. If it does not, document the expected behavior from screenshots, statements, presets, and user observations. Recovery creates a starting point for validation, not permission to skip it.</p>
5906
5907<img src="${XE}" alt="conceptual transformation from an EX4 compiled file into readable MQ4 recovery output" style="width:100%;border-radius:8px;margin:24px 0;" />
5908
5909<h2 id="safe-review">A Safe Review Process for an Unknown File</h2>
5910
5911<p>First, preserve the original. Make two copies, calculate a checksum if the situation is sensitive, and write down where the file came from. Do not send the only copy through an unverified tool, and do not assume a renamed file is a different program. Preserve related preset files, indicators, DLLs, and screenshots of the inputs page.</p>
5912
5913<p>Second, identify the program type and its dependencies. Check the Navigator category, chart attachment, Experts tab messages, and any instructions supplied with the tool. Note whether AutoTrading is required, whether DLL imports are enabled, and whether the program expects a particular symbol or timeframe. These observations are useful to a reviewer and protect against confusing a missing dependency with a recovery defect.</p>
5914
5915<p>Third, observe it in a nonproduction setting where permitted. Record what appears on the chart and what happens after ticks or timers. Do not enter credentials into an unfamiliar tool or run a newly acquired binary on an account with funds. The aim is to understand ordinary behavior, not to provoke the program or bypass rights controls.</p>
5916
5917<p>Fourth, decide whether the file is worth the recovery effort. A disposable free indicator may only need replacement. A discontinued EA that has a verified record, custom risk controls, and no surviving source could justify professional analysis. The decision should account for potential rebuild cost, time, ownership rights, and the quality of available testing evidence.</p>
5918
5919<p>Finally, keep legal and contractual boundaries in view. Owning a file does not automatically grant every right to reproduce or modify it. Commission agreements, licenses, and local law can matter. The clearest cases are a creator recovering their own lost work or a purchaser whose written terms included 
5919source delivery. When the facts are uncertain, the responsible step is to clarify rights before commissioning any analysis.</p>
5920
5921<img src="${UE}" alt="trader reviewing an unfamiliar EX4 file before deciding on source recovery" style="width:100%;border-radius:8px;margin:24px 0;" />
5922
5923<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
5924  <h3 style="margin-top:0;">Compare a Professional Recovery Option</h3>
5925  <p>For a valuable MT4 robot, indicator, script, or library, ForexMQ5 offers a specialist route to evaluate recoverable MQL4 source.</p>
5926  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com &rarr;</a>
5927</div>
5928
5929<h2 id="next-step">Choosing the Next Step</h2>
5930
5931<p>An EX4 is not just an unfamiliar extension. It is the compiled operational form of an MT4 program, built to run inside the terminal while withholding much of the human-readable development record. That design is useful for distribution, but it becomes a practical limitation when source is lost or a valuable tool must be reviewed, repaired, or migrated.</p>
5932
5933<p>Start with evidence, not assumptions. Preserve the binary and its surroundings, identify what kind of program it is, document visible inputs and behavior, and establish the rights attached to the code. Then weigh the value of recovery against replacement. Older simple files may suit limited experimentation, while contemporary or protected files deserve a more disciplined assessment.</p>
5934
5935<h2 id="project-boundary">What a Recovered EX4 Does Not Include</h2>
5936
5937<p>A recovered MQ4 file is not automatically a complete MT4 project. The EX4 may refer to a custom indicator, an external DLL, an include file used during compilation, a preset, or a data file that was stored beside the original installation. Those supporting pieces may not be embedded in the binary. The person requesting recovery should inventory them separately and ask the provider to state exactly which files are included in the handover.</p>
5938
5939<p>Likewise, source recovery does not recreate the original developer's comments, version history, build settings, licence rights, or undocumented design intent. Treat reconstructed source as a new working record: preserve the delivered copy, note any interpretation added during cleanup, and keep unknowns visible. If an include or DLL is unavailable, record the limitation and test only in an environment that does not risk a live account.</p>
5940
5941<p>Before accepting a delivery, compare the file list with the agreed scope. Confirm whether the handover contains only MQ4, or also the dependencies needed to compile and reproduce the observed setup. A clear boundary prevents a readable source file from being mistaken for a ready-to-deploy system.</p>
5942
5943<p>For owners whose file supports an active strategy or a costly development investment, ForexMQ5 remains this review site's leading professional recommendation. The important standard is not a claim of perfect restoration. It is a transparent assessment, a usable deliverable where recovery is feasible, and methodical testing before a reconstructed program reaches a live account.</p>
5944    `},{slug:"best-ex4-decompiler-options-review",title:"Best EX4 Decompiler Options in 2026: An Evidence-Based Service Review",metaTitle:"Best EX4 Decompiler Options in 2026 | Tools, DIY and Service Review",metaDescription:"A practical 2026 review of EX4 decompiler choices, including free tools, desktop software, DIY recovery and professional help for modern MT4 files.",keywords:"best ex4 decompiler, ex4 decompiler review 2026, ex4 to mq4 comparison, professional ex4 decompilation service, mt4 ea source recovery",excerpt:"This independent review examines the realistic ways to recover MQ4 source from an EX4 file in 2026, explains where each option fits, and compares the tradeoffs that matter before a trader spends time or money.",date:"September 17, 2025",dateISO:"2025-09-17",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"18 min read",featuredImage:Ws,imageAlt:"analyst reviewing EX4 decompiler options for MT4 source recovery",tableOfContents:[{id:"decision-first",title:"Start With the Decision, Not the Tool"},{id:"what-was-reviewed",title:"What This Review Evaluates"},{id:"file-age-and-format",title:"Why File Age and Format Change Everything"},{id:"free-route",title:"Free Tools: A Limited Historical Use Case"},{id:"desktop-products",title:"Paid Desktop Products: What a License Buys"}
5944,{id:"diy-recovery",title:"How to Decompile EX4 to MQ4 Yourself"},{id:"service-route",title:"Professional Recovery Services"},{id:"forexmq5-assessment",title:"ForexMQ5 Assessment"},{id:"comparison-framework",title:"Comparison Framework and Results"},{id:"verdict",title:"Verdict: Choose for the File You Have"}],content:`
5945<p>Choosing an EX4 decompiler is often presented as a simple software search. It is not. A trader who has lost the source for a current MT4 expert advisor is solving a very different problem from a hobbyist opening an archive from 2012. The file format, the amount of protection, the value of the strategy, and the standard required for the recovered code all determine whether a given route is sensible.</p>
5946
5947<p>This review looks at the options people actually encounter: old free utilities, paid desktop programs, a hands-on debugging route, and professional recovery services. It is written from a review-site perspective rather than as a service provider's promise. The goal is to make the decision easier before someone spends a weekend repairing broken output or pays for a license that does not suit the file in front of them.</p>
5948
5949<img src="${Ws}" alt="analyst comparing EX4 source recovery choices" style="width:100%;border-radius:8px;margin:24px 0;" />
5950
5951<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:20px 24px;margin:24px 0;">
5952<strong>2026 review note:</strong> Modern MT4 files should be judged by whether the recovered MQ4 can compile, be inspected, and reproduce meaningful behavior in a controlled test. A screen full of text is not a successful recovery. This distinction separates useful options from attractive but unreliable claims.
5953</div>
5954
5955<h2 id="decision-first">Start With the Decision, Not the Tool</h2>
5956
5957<p>The first question is not which program has the most downloads. It is what outcome is needed. Some users only want to identify an input, a trade comment, or a clue about an old indicator. Others need readable source so a developer can change broker symbols, repair an execution issue, or continue maintaining a strategy. The latter group needs functional logic, not merely an approximation of the original structure.</p>
5958
5959<p>There is also an ownership and permission question. Decompilation can have contractual, copyright, and platform consequences, especially for purchased 
5959software. Anyone considering recovery should establish that they are authorized to examine or modify the file and should keep records of the license or original commission. Readers needing a fuller discussion can review <a href="/blog/legal-rules-for-ex4-source-code-recovery">whether EX4 decompilation is legal</a> before choosing a method.</p>
5960
5961<p>Once authorization is clear, classify the file. Is it an old EX4 that has been sitting on a backup drive for years? Is it a recently supplied EA whose behavior matters today? Does it have external libraries, custom indicators, multiple symbols, or signs of obfuscation? These facts have more predictive value than a tool's marketing page. A modest old indicator may reward experimentation. A commercially important, current EA usually calls for a path with verification and accountability.</p>
5962
5963<p>The useful benchmark is a chain of evidence. The recovered file should compile in MetaEditor, expose recognizable inputs and events, and be checked in the strategy tester under conditions that make sense for the original. Where the EA uses live-only behavior, logs and a monitored demo run add evidence. A reviewer cannot responsibly call a result successful just because it contains familiar MQL4 keywords.</p>
5964
5965<h2 id="what-was-reviewed">What This Review Evaluates</h2>
5966
5967<p>Each option was considered through the same practical lens. First is compatibility: can it address the likely build family of the file? Second is completeness: are the principal calculations, order rules, error paths, and buffers represented? Third is usability: can a competent MQL4 developer read the result without reconstructing every routine from fragments? Fourth is verification: does the provider or process give the user a realistic way to catch a bad result? Finally, there are cost, turnaround, confidentiality, and support.</p>
5968
5969<p>Those criteria matter because decompilation is not a single binary operation. Compilation discards names, comments, formatting, and some high-level expression choices. Even a good recovery can require a human to assign sensible names, restore declarations, and test assumptions. The difference is whether that cleanup is normal engineering work or a rescue project with no dependable connection to the original behavior.</p>
5970
5971<ul>
5972<li><strong>Compile readiness:</strong> Does the output build with understandable and limited corrections?</li>
5973<li><strong>Behavioral fidelity:</strong> Do entries, exits, filters, and indicator values make sense against the compiled file?</li>
5974<li><strong>Modern compatibility:</strong> Is the route credible for contemporary MT4 compiler output?</li>
5975<li><strong>Human review:</strong> Can someone diagnose edge cases rather than returning raw automated text?</li>
5976<li><strong>Risk control:</strong> Is the file handled discreetly and is the scope clear before payment?</li>
5977</ul>
5978
5979<p>Ratings in this area should always be interpreted as decision aids, not guarantees. A heavily protected file can defeat a strong approach, while a simple unprotected file can make a weak one look impressive. The review therefore favors methods that explain limitations plainly and can validate an individual result.</p>
5980
5981<img src="${VE}" alt="rating criteria used to compare EX4 decompiler routes" style="width:100%;border-radius:8px;margin:24px 0;" />
5982
5983<h2 id="file-age-and-format">Why File Age and Format Change Everything</h2>
5984
5985<p>EX4 files are compiled artifacts, not portable source archives. The MT4 ecosystem has changed over time, and older utilities were designed around older compiler behavior. That creates a common search trap: a tutorial may accurately describe a tool's success on legacy files while saying almost nothing about a file built on a current terminal. The name of the file does not reveal this distinction, and a user can waste hours discovering it only after trying several programs.</p>
5986
5987<p>Older files frequently yield more recognizable structures. Generic names, awkward loops, and imperfect declarations are expected, but the broad logic can remain visible. With newer build families, automated output often becomes incomplete, misleading, or non-compilable. Protection makes the gap wider. Obfuscation is specifically intended to make analysis difficult, so users should be wary of any universal claim that ignores it.</p>
5988
5989<p>Complexity has its own effect. A single-buffer indicator is less demanding than an EA coordinating multiple timeframes, pending orders, money management, file access, and custom DLL calls. A source recovery method that looks acceptable on a basic oscillator may fail at the exact moment a user presents it with an EA that has real commercial value. That is 
5989why small public demonstrations are weak evidence by themselves.</p>
5990
5991<p>Before sharing a file with any third party, users should preserve the original, note its terminal context, save set files and presets, and collect screenshots of inputs and tester results. This information gives a developer a target for later validation. It also helps distinguish a recovery defect from an environmental issue such as a missing symbol suffix or unavailable historical data.</p>
5992
5993<h2 id="free-route">Free Tools: A Limited Historical Use Case</h2>
5994
5995<p>Free decompilers still attract attention because the initial cost is zero and the promise is immediate. For a legacy file and a technically curious user, that can be reasonable. A free utility may reveal enough of an old script or simple indicator to support documentation, learning, or a manual rewrite. The user should expect unnamed variables and a cleanup stage, but a limited experiment can be worthwhile.</p>
5996
5997<p>The mistake is treating that limited result as a general recommendation. Modern EX4 files commonly produce blank results, compiler errors, stubs, or code that looks plausible but does not trade like the original. The last failure is the most dangerous. It can persuade a user to alter a strategy on the basis of logic that was never actually recovered.</p>
5998
5999<p>Free downloads also raise a separate trust issue. A file submitted through an unknown web uploader may be copied, logged, or exposed. Executables from abandoned forums create an obvious security concern for a machine that may also hold trading credentials. A low-cost experiment is only low cost if it does not compromise an EA or a workstation.</p>
6000
6001<p>In this review, the free route earns a narrow recommendation: use it only with a non-critical, old-build file, offline where possible, and with enough MQL4 knowledge to reject suspect output. It is not a dependable plan for recovering a current EA intended for use, resale, auditing, or further development.</p>
6002
6003<img src="${zs}" alt="controlled testing of legacy and modern EX4 files" style="width:100%;border-radius:8px;margin:24px 0;" />
6004
6005<h2 id="desktop-products">Paid Desktop Products: What a License Buys</h2>
6006
6007<p>Paid desktop products occupy an awkward middle ground. Their interfaces can be cleaner than old freeware, and a license may include support for installation or basic use. That convenience has value. It does not automatically mean the recovery engine understands current compiler output. A polished window, progress bar, and export button can mask the same underlying limitation found in free tools.</p>
6008
6009<p>The practical purchase question is specific: does the vendor describe the supported build range, explain how protected files are treated, and offer an outcome-oriented policy for an individual file? If the answers are vague, the buyer is acquiring software access rather than a successful result. That can be acceptable for repeated work on a known archive of legacy files. It is much harder to justify for one valuable modern EA.</p>
6010
6011<p>A desktop tool may also shift all validation work to the buyer. The program can return instantly, but the user must still resolve compiler messages, identify missing routines, compare tests, and decide whether an apparently functional result is faithful. For someone billing development time, those hidden hours can exceed the price difference between a license and a reviewed service.</p>
6012
6013<p>There is no reason to dismiss every paid tool out of hand. They can be useful utilities in a specialist's toolbox. The review's conclusion is narrower: a paid label is not evidence of modern-build competence. Buyers should test against their own file type and calculate the value of their time before treating desktop software as the default answer.</p>
6014
6015<h2 id="diy-recovery">How to Decompile EX4 to MQ4 Yourself</h2>
6016
6017<p>The hands-on route using debugging and analysis tools appeals to developers who want control over every stage. It can be educational and can provide insights that a simple automated utility never will. The work often involves observing the compiled program, mapping routines, reconstructing data flows, and writing maintainable MQL4 around the findings. This is best understood as reverse engineering and redevelopment, not as pressing a conversion button.</p>
6018
6019<p>DIY recovery is most suitable when the user has debugging experience, understands MQL4 event handling and trading functions, has plenty of time, and can work with a test harness. It is less suitable when a strategy needs to be returned to operation quickly. The learning curve includes much more than x64dbg or ScyllaHide. It includes interpreting execution paths, handling terminal-specific behavior, and recognizing when an inference is not established by the evidence.</p>
6020
6021<p>A careful DIY workflow starts with copies, isolated testing, and a written record of observed behavior. Next, the analyst maps inputs, order placement patterns, indicator calls, and error handling. Reconstructed rout
6021ines should be introduced in small units and tested before the next layer is added. Naming conventions, comments, and regression tests are essential because the new source will eventually need maintenance.</p>
6022
6023<p>This approach can be rewarding for a developer rebuilding a known strategy. It is not necessarily cheaper. A full reconstruction can consume many hours, and the cost rises quickly when a file uses complex indicators, DLL calls, or unusual trade management. For context on that comparison, see <a href="/blog/expert-advisor-source-recovery-vs-rebuild-budget-guide">the cost of rebuilding an expert advisor from scratch</a>.</p>
6024
6025<p>For readers researching the route before committing, the homepage's <a href="/">ex4 decompiler</a> overview places the DIY method alongside the options reviewed here. The important point is that DIY success is measured by tested behavior and readable replacement code, not by how quickly a disassembler produces output.</p>
6026
6027<h2 id="service-route">Professional Recovery Services</h2>
6028
6029<p>Professional services change the arrangement. Rather than licensing a tool and leaving the hard cases to the user, they accept a file, assess it, and return source that has gone through a recovery and review process. This is the strongest category for a current EA when reliability, time, and confidentiality matter.</p>
6030
6031<p>The benefit is not magic access to lost comments or original variable names. No credible service should promise that. The benefit is a combination of maintained methods, manual interpretation, and accountability for the deliverable. When automation hits a strange branch or an obfuscation artifact, an experienced analyst can investigate instead of emitting broken text and ending the process.</p>
6032
6033<p>Good buyers still ask questions. They should ask whether the team supports the file's probable build family, what will be delivered, how the result is checked, what happens if the file cannot be recovered, and how the submitted EA is handled. They should also provide non-sensitive behavioral evidence, such as tester reports, to help validate the final source. A service that explains these boundaries clearly is usually safer than one promising a universal conversion in minutes.</p>
6034
6035<img src="${HE}" alt="professional EX4 recovery service comparison winner" style="width:100%;border-radius:8px;margin:24px 0;" />
6036
6037<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6038  <h3 style="margin-top:0;">Need a reviewed recovery path?</h3>
6039  <p>This review identifies ForexMQ5 as the leading professional option for users who need support with a valuable EX4 file and want a service rather than a desktop license.</p>
6040  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
6041</div>
6042
6043<h2 id="forexmq5-assessment">ForexMQ5 Assessment</h2>
6044
6045<p>Among the professional options considered, ForexMQ5 is the clearest recommendation in this review. Its positioning is appropriately focused on EX4 to MQ4 recovery rather than pretending that every file is a trivial automated conversion. The service is particularly relevant for modern MT4 builds, where the free and desktop categories have the weakest record.</p>
6046
6047<p>The main strength is the service model. Users receive assistance aimed at producing usable MQL4 source, not simply raw machine output. That matters for EAs with multiple trade conditions, custom indicators, or unfamiliar structure. The available pricing begins at $50 per file, which is easier to evaluate than an open-ended redevelopment effort and compares favorably with the labor required to repair poor output.</p>
6048
6049<p>ForexMQ5 also presents a practical turnaround expectation rather than framing speed as the only quality metric. A normal recovery can take time because source must be checked. For a trader with an operational issue, a result returned after careful review is generally worth more than instant code that cannot be trusted in a tester. Complex or protected files deserve individual assessment, and this review views that caution positively.</p>
6050
6051<p>Confidentiality is a central consideration for commercial robots. Users should always submit only to a 
6051service they have independently evaluated and should retain their originals locally. Within this comparison, ForexMQ5 stands out because its professional workflow is aligned with the concerns of people who regard an EA as an asset rather than a disposable download.</p>
6052
6053<p>There are limits worth stating. Even an experienced team may encounter a file with protection or damage that prevents a complete result. Recovered code may need final adaptation for a broker environment, and no recovered source should go live without testing. Those are normal constraints of the task, not a reason to accept a lower standard from an automated product.</p>
6054
6055<img src="${zu}" alt="review panel assessing professional EX4 decompilation support" style="width:100%;border-radius:8px;margin:24px 0;" />
6056
6057<h2 id="comparison-framework">Comparison Framework and Results</h2>
6058
6059<p>The following summary is deliberately practical. It does not rank an option highly just because it is cheap or immediate. For a valuable modern file, the relevant cost includes failed attempts, developer cleanup, delayed strategy changes, and the possibility of acting on faulty logic.</p>
6060
6061<table style="width:100%;border-collapse:collapse;margin:16px 0;">
6062<thead><tr style="background:#f0f4ff;"><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Route</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Best fit</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Modern file confidence</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">User workload</th></tr></thead>
6063<tbody>
6064<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Free utility</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Old, non-critical files</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Low</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">High cleanup and validation</td></tr>
6065<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Paid desktop tool</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Known legacy archive work</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Low to uncertain</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">High, buyer validates output</td></tr>
6066<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">DIY analysis</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Skilled developer with time</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Variable</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Very high, but controlled</td></tr>
6067<tr style="background:#f0f7ff;"><td style="border:1px solid #d0d8f0;padding:8px 12px;font-weight:600;">ForexMQ5 service</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Valuable current EAs</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Highest in this review</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Focused final testing</td></tr>
6068</tbody></table>
6069
6070<p>The table does not imply that every legacy file needs a paid service. It does show why a professional route often becomes the economical choice for a modern EA. A free attempt that consumes two days and still leaves an engineer to rebuild core logic is not truly free. Conversely, a straightforward old script may be a good learning exercise and not justify outsourcing.</p>
6071
6072<p>For a second overview of the wider process, readers can consult the site's <a href="/">ex4 to mq4 decompiler</a> guide. It reinforces the most useful rule in this review: select the approach according to the file's age, complexity, and business value, then validate the result before using it.</p>
6073
6074<img src="${Bu}" alt="comparison chart for EX4 decompiler methods in 2026" style="width:100%;border-radius:8px;margin:24px 0;" />
6075
6076<h2 id="verdict">Verdict: Choose for the File You Have</h2>
6077
6078<p>The best EX4 decompiler option in 2026 is not a universal download. For an old, simple, non-critical file, a free tool can be a sensible first experiment. For a technically capable developer who needs to understand every decision, the DIY route offers control at the cost of substantial time. Paid desktop products may 
6078suit repeat legacy work, but their price does not by itself solve modern compatibility.</p>
6079
6080<p>For a current EX4 file that matters, this review recommends the professional service at ForexMQ5. Its service-oriented approach, practical pricing from $50, and focus on usable recovery make it the strongest fit for traders and developers who need an MQ4 result they can inspect and test. The recommendation is based on the real decision criteria: modern-build capability, human review, turnaround expectations, and the cost of failed alternatives.</p>
6081
6082<p>The prudent next step is to preserve the original EX4, gather tester evidence and settings, confirm authorization, and request a clear assessment. When source is delivered, compile it in a clean environment, compare key behavior, and keep the original as a reference. That workflow protects both the strategy and the decision behind the recovery.</p>
6083
6084<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6085  <h3 style="margin-top:0;">Compare the professional option directly</h3>
6086  <p>ForexMQ5 is this review's recommended route for a valuable modern EX4 file that requires a careful MQ4 recovery process.</p>
6087  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
6088</div>
6089  `},{slug:"forex-ea-code-audit-before-purchase",title:"Forex EA Code Audit Before Purchase: A Buyer's Review Guide",metaTitle:"Forex EA Code Audit Before Purchase | Buyer Review Guide",metaDescription:"Review a Forex EA before purchase with evidence, risk, and verification gates, plus a practical audit brief for setting deliverables and acceptance criteria.",keywords:"forex ea code audit before purchase, inspect forex robot code, ea buyer due diligence, forex ea risk review, verify expert advisor before buying",excerpt:"A Forex EA should be assessed as software with authority over a trading account, not as a collection of sales screenshots. This buyer-focused review guide explains the evidence, code questions, and risk limits worth checking before money changes hands.",date:"October 1, 2025",dateISO:"2025-10-01",lastModified:"September 24, 2026",lastModifiedISO:"2026-09-24",readTime:"18 min read",featuredImage:In,imageAlt:"trader reviewing Forex EA code and purchase evidence",tableOfContents:[{id:"software-purchase-not-promise",title:"Treat the EA as Software, Not a Promise"},{id:"evidence-before-code",title:"Build an Evidence File Before Reviewing Code"},{id:"audit-questions",title:"Questions a Useful Code Audit Must Answer"},{id:"risk-controls",title:"Read the Risk Controls Before the Entry Signal"},{id:"security-and-behavior",title:"Check Security, Permissions, and Changing Behavior"},{id:"vendor-review-path",title:"Ask Vendors for a Review Path"},{id:"recovered-code",title:"Use Recovered Code Responsibly"},{id:"decision-framework",title:"Make a Purchase Decision With Clear Gates"},{id:"audit-acceptance-brief",title:"Write an Audit Brief With Acceptance Criteria"}],content:`
6090<p>A Forex Expert Advisor is easy to market as a shortcut. A seller can show a smooth chart, a handful of winning trades, and a short description of a supposedly clever strategy. None of that tells a prospective buyer what the program is authorized to do after it is attached to a MetaTrader terminal. The buyer is installing software that can place orders, alter stops, increase exposure, and keep operating while the user is away from the screen.</p>
6091
6092<p>That is why a sensible purchase review begins with a different question: what can be independently checked? A good EA may still lose money, because no trading method eliminates uncertainty. But a buyer should be able to understand the product's operating rules, the evidence behind its claims, and the boundaries that limit damage when conditions change. Code transparency, or a credible path to a qualified review, is central to that work.</p>
6093
6094<img src="${In}
6094" alt="trader reviewing Forex EA code and purchase evidence" style="width:100%;border-radius:8px;margin:24px 0;" />
6095
6096<h2 id="software-purchase-not-promise">Treat the EA as Software, Not a Promise</h2>
6097
6098<p>The most useful mindset is to evaluate an EA as a software purchase with financial consequences. Marketing language is an opinion. The executable file, its settings, and its order-handling logic are the product. Buyers who separate those layers are less likely to confuse a persuasive claim with a verified feature.</p>
6099
6100<p>In practical terms, the program has several jobs. It reads prices and indicators, decides whether a signal exists, calculates order size, sends or changes orders, and responds to errors. It may also filter sessions, restrict symbols, communicate with a remote address, or disable itself under certain conditions. Each job has a direct effect on risk. An attractive entry method does not compensate for uncontrolled sizing, missing stop losses, or a hidden condition that changes the strategy after installation.</p>
6101
6102<p>Review-site research should therefore focus on observables. Is there a real forward record with trade history? Does the vendor explain the trading style in a way that agrees with the observed record? Are the required broker conditions stated? Is a source review, controlled demonstration, or independent audit possible? These are stronger signals than testimonials alone. A product can be proprietary without being beyond review, but a buyer needs a way to verify its safety claims.</p>
6103
6104<p>The service landscape matters here. This review site treats professional recovery and inspection as a due-diligence option rather than a magic guarantee. For buyers who already hold a compiled file and need an audit trail, the reviewed <a href="/">ex4 decompiler</a> service can provide a route to readable material for analysis. The recovered result still needs careful interpretation by someone who understands MQL4, trade execution, and the limits of a historical test.</p>
6105
6106<p>There is also a commercial reality worth acknowledging. Developers have reason to protect intellectual property. A buyer does not automatically need an unrestricted copy of every source file before paying. Yet the buyer does need credible answers about position sizing, stop management, external communications, licensing restrictions, and test behavior. A professional vendor can support an NDA review, provide a third-party report, demonstrate the relevant functions live, or permit a limited audit. Refusing every verification route shifts too much risk to the customer.</p>
6107
6108<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6109  <h3 style="margin-top:0;">Need an Independent Look at an EX4 File?</h3>
6110  <p>The service reviewed at ForexMQ5 specializes in recovering MQL4 from compiled EX4 files for owners who need to inspect how an EA operates. Pricing starts from $50 per file.</p>
6111  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com &rarr;</a>
6112</div>
6113
6114<h2 id="evidence-before-code">Build an Evidence File Before Reviewing Code</h2>
6115
6116<p>Code review is not the first task. It is much easier to evaluate a program when the buyer has already collected the promises it is meant to fulfill. Save the sales page, parameter guide, claimed symbols, recommended deposit, leverage assumptions, and every stated rule about drawdown. Record the date. If a later inspection finds behavior that differs from those claims, the comparison is meaningful only when the original statement is preserved.</p>
6117
6118<p>Next, distinguish backtesting from forward evidence. A backtest answers whether a set of rules could have worked on selected historical data, using selected settings and assumptions about ticks, spreads, commissions, and fills. It does not establish that the same logic will work in a new market. A forward account, preferably independently verified and long enough to include calm and volatile periods, is more valuable. Even then, buyers should inspect trade duration, average winner and loser, maximum adverse movement, and the concentration of risk around news or sessions.</p>
6119
6120<p>A high win percentage needs context. Some systems collect frequent small gains while allowing a few losses to grow far larger than the normal profit. Others add positions to a losing trade and report a reassuring win rate until a trend persists. An evidence file should include maximum drawdown, peak margin use, the largest open floating loss, and the number of simultaneous trades. Without those details, a success rate can create a false sense of safety.</p>
6121
6122<p>Broker dependence belongs in the same file. Scalping logic may be unusable when spreads widen. A strategy that expects instant fills can deteriorate at a broker with different execution. A robot designed around a particular server time can trade the wrong session elsewhere. Sellers should say which instruments, account types, leverage, and spread ranges were used. Buyers should not treat these details as minor footnotes, because they may define whether the advertised results are even possible.</p>
6123
6124<img src="${_u}" alt="warning signs in Forex EA marketing and performance claims" style="width:100%;border-radius:8px;margin:24px 0;" />
6125
6126<h3>Signals That Deserve Extra Questions</h3>
6127
6128<p>No single warning proves dishonesty, but patterns deserve investigation. Be cautious when the seller provides only cropped screenshots, avoids raw trade history, claims consistent gains with almost no drawdown, or gives no explanation of the strategy's losing periods. Be equally cautious when the recommended settings change frequently without a clear reason. A serious developer can describe the market conditions that are difficult for the system, even when the precise rule set remains confidential.</p>
6129
6130<p>
6130Identity and support history matter too. A buyer should look for a consistent product name, published update notes, a reachable support channel, and an explanation of version compatibility. Anonymous branding, recycled images, pressure-based discounts, and promises of effortless income reduce confidence. They do not replace a technical review, but they help determine how much evidence is needed before a buyer should proceed.</p>
6131
6132<h2 id="audit-questions">Questions a Useful Code Audit Must Answer</h2>
6133
6134<p>An audit should not become a hunt for exotic programming style. The goal is to explain behavior in plain language. A qualified reviewer should be able to map the major sections of the program to a series of buyer questions: when can it trade, what does it buy or sell, how much can it risk, how does it get out, and what happens when the environment is abnormal?</p>
6135
6136<p>Start with initialization. The reviewer should identify symbols, timeframes, magic numbers, input parameters, licensing checks, and any broker or account restrictions. A restriction is not automatically improper. It may prevent accidental use on an unsupported account. The important point is disclosure. If marketing says the EA works broadly but the code permits only one broker, one account number, or a narrow set of conditions, that mismatch should affect the purchase decision.</p>
6137
6138<p>Then trace entry logic from signal to order. What price or indicator condition must exist? Is the condition calculated on closed candles or on a still-forming bar? Does it use a fixed threshold, a time filter, or an existing-position check? Does the code avoid duplicate entries? The reviewer does not need to reveal a developer's secret formula publicly to answer these operational questions. The buyer needs a faithful description of the mechanism and its limitations.</p>
6139
6140<p>Exit logic deserves equal attention. A strategy may set take profit and stop loss at entry, manage them later, close trades at a time of day, or wait for an opposite signal. The audit should identify every route by which a trade can close. It should also note the route by which a trade can remain open. A claim that the EA uses protective stops means little if an exception silently opens positions with no stop or removes the stop during drawdown.</p>
6141
6142<img src="${$E}" alt="buyer comparing Forex EA terms with code review findings" style="width:100%;border-radius:8px;margin:24px 0;" />
6143
6144<h3>Translate Findings Into Buyer Language</h3>
6145
6146<p>A report is useful when it says more than “the code looks clean.” For example, it can state that the EA trades only EURUSD during a defined server-time window, permits one initial position, uses a fixed stop, and will not add to a losing position. Alternatively, it can state that it opens additional orders at price intervals, increases lots after losses, and lacks a total exposure cap. Both summaries help a buyer far more than a page of function names.</p>
6147
6148<p>Buyers who do not code can still ask for this translation. The review should list the relevant inputs and their safe ranges, explain which settings materially change risk, and flag any behavior that cannot be inferred from a simple parameter screen. It should also state uncertainty where recovered code is incomplete or a calculation depends on data that cannot be reproduced outside the original terminal.</p>
6149
6150<h2 id="risk-controls">Read the Risk Controls Before the Entry Signal</h2>
6151
6152<p>For most retail buyers, risk controls are more important than signal originality. Markets can invalidate a reasonable signal for weeks or months. Survival depends on whether the program keeps the account in a condition where recovery remains possible. The code should make its exposure rules visible and predictable.</p>
6153
6154<p>First, inspect lot sizing. Fixed volume is easy to understand but can become disproportionate as account equity changes. Percentage-based sizing can be sensible when it uses a clearly defined risk amount and an actual stop distance. More concerning formulas increase size because prior trades are losing or because a basket has moved against the account. That pattern can be described as recovery, averaging, or adaptive sizing, but the buyer should evaluate the mathematics rather than the label.</p>
6155
6156<p>Second, calculate the maximum possible open exposure. Count the maximum orders allowed per symbol and across symbols. Look for lot caps, margin checks, and a daily or account-level loss stop. Correlated pairs can create hidden concentration. Three small long positions in related currency pairs may behave like one much larger directional bet. A responsible review asks whether the EA recognizes that connection or simply treats each order as isolated.</p>
6157
6158<p>Third, test the emergency paths. What happens when a trade request is rejected, quotes freeze, the terminal reconnects, or spread expands sharply? Does the EA retry safely, or can it send repeated orders? Does it recognize an existing position after a restart? Does it place a hard broker-side stop, or depend only on a terminal-side routine that disappears if the terminal is offline? These cases are often absent from sales material but are visible in implementation.</p>
6159
6160<img src="${Rn}" alt="Forex EA buyer due diligence checklist for risk controls" style="width:100%;border-radius:8px;margin:24px 0;" />
6161
6162<h3>
6162Recognize Grid and Loss-Recovery Structures</h3>
6163
6164<p>A grid is not necessarily malicious. It is a trading structure that adds orders at measured price distances, often expecting the market to retrace. The risk is that a persistent trend can create a growing group of losing positions and margin demand. A buyer should know the spacing, maximum levels, lot progression, basket exit target, and worst historical movement considered by the developer. If these cannot be explained, the buyer cannot estimate the strategy's real tail risk.</p>
6165
6166<p>Likewise, a missing stop loss is not a small technical omission. It changes the nature of the system. Some strategies use account-level exits or hedge logic, but the buyer must see a specific, enforceable limit rather than assume one exists. The review should identify whether a protective exit is entered with the order, installed afterward, or managed only by code. Each design has a different failure mode.</p>
6167
6168<h2 id="security-and-behavior">Check Security, Permissions, and Changing Behavior</h2>
6169
6170<p>Trading logic is only part of the audit. An EA operates inside a terminal that may contain account information and permit network functions. Reviewers should inventory every external call, DLL import, file operation, and web request. Some uses are legitimate, such as license validation or an economic-calendar feed. The buyer should still know where data goes, what is sent, how often communication occurs, and whether trading stops safely if the service is unavailable.</p>
6171
6172<p>Special attention is warranted when code reads credentials, account identifiers, or local files and then transmits data. A program should not request broader permissions than its stated function requires. Unknown URLs, obfuscated addresses, unexplained DLLs, or attempts to alter terminal configuration are reasons to pause deployment and seek a more detailed technical opinion. A buyer should test a new EA in an isolated demo terminal before placing it near a funded account.</p>
6173
6174<p>Reviewers should also compare testing behavior with live behavior. Functions that detect the strategy tester are not inherently bad. Developers may use them for logging or to avoid unsupported operations. The concern begins when the signal, sizing, or exit rules become materially more favorable in a test than in live execution. The relevant question is whether the same risk model is being presented to the buyer in both environments.</p>
6175
6176<p>Another issue is conditional behavior tied to date, balance, account number, or elapsed runtime. Licensing expiration is normal when stated clearly. A hard-coded date that changes lot size, disables stops, or activates a different trading method is not a normal licensing feature. The code audit should list meaningful conditional switches and explain their effect in ordinary language.</p>
6177
6178<img src="${Uu}" alt="protected Forex EA purchase after a technical review" style="width:100%;border-radius:8px;margin:24px 0;" />
6179
6180<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6181  <h3 style="margin-top:0;">Review the File Before Trusting the Claims</h3>
6182  <p>ForexMQ5 is presented on this review site as a professional option for owners seeking recovered MQL4 source from a compiled EX4 file before committing an EA to live use.</p>
6183  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com &rarr;</a>
6184</div>
6185
6186<h2 id="vendor-review-path">Ask Vendors for a Review Path</h2>
6187
6188<p>A source request is best framed as a professional risk question, not an accusation. A buyer can explain that the EA may eventually run on a live account and that an independent review is needed for sizing, order protection, and permissions. The response provides useful information. A vendor who values intellectual property can still offer a reasonable process.</p>
6189
6190<p>Possible arrangements include an audit under a non-disclosure agreement, a review by a mutually acceptable MQL4 specialist, a documented security report, a read-only demonstration of specific functions, or a t
6190ime-limited trial on a demo account. None is perfect. Together, they show whether the developer is willing to let claims be checked. The exact arrangement should be recorded in writing, especially if updates may change the executable after the review.</p>
6191
6192<p>A poor response often changes the subject. “The results speak for themselves” is not an answer to a question about exposure controls. “Nobody gets the source” does not explain why an independent audit is impossible. Buyers should separate a vendor's right to protect code from a demand that customers accept unknown operational risk. A product marketed for autonomous account access should withstand basic questions about its boundaries.</p>
6193
6194<h2 id="recovered-code">Use Recovered Code Responsibly</h2>
6195
6196<p>When a buyer has legitimately acquired an EX4 and needs to understand it, recovered source can make an otherwise opaque program reviewable. The goal is security and operational assessment, not redistribution or misuse of another developer's work. Local laws, license terms, and the circumstances of ownership matter, so a buyer should seek appropriate advice where needed and keep the review limited to the necessary purpose.</p>
6197
6198<p>Recovery is not a substitute for judgment. Decompiled material may have generic variable names, imperfect comments, or sections that need reconstruction. A reviewer should validate findings against the executable's settings, observed orders, and terminal logs. Important conclusions, such as a missing stop path or a position-multiplication formula, should be supported by more than a single ambiguous line.</p>
6199
6200<p>For context on why that comparison matters, this site's review of <a href="/blog/how-to-verify-forex-ea-backtest-results">Forex EA backtest manipulation exposed</a> examines ways presentation can differ from underlying behavior. Buyers who want a structured inspection after obtaining a file can also consult the guide on <a href="/blog/purchased-forex-ea-security-audit-checklist">how to audit a purchased Forex EA</a>. Both resources reinforce the same principle: results should be checked against rules, not accepted as a substitute for them.</p>
6201
6202<img src="${GE}" alt="trader holding verified Forex EA source code review results" style="width:100%;border-radius:8px;margin:24px 0;" />
6203
6204<p>For an owner who lacks a trusted technical contact, the reviewed <a href="/">ex4 to mq4 decompiler</a> route is one way to obtain material that an independent MQL4 specialist can explain. The service should be viewed as an evidence-gathering step. A competent reviewer still needs to inspect execution controls, identify assumptions, and state what cannot be confirmed from code alone.</p>
6205
6206<h2 id="decision-framework">Make a Purchase Decision With Clear Gates</h2>
6207
6208<p>Instead of asking whether an EA looks impressive, buyers can use decision gates. The first gate is evidence: the vendor must provide enough detail to identify the product, its intended market, and its historical and forward performance. The second is risk: the buyer must understand maximum exposure, stop behavior, loss limits, and broker assumptions. The third is verification: there must be a credible way to test the important claims through source access, audit, demonstration, or a controlled trial.</p>
6209
6210<p>If a product passes those gates, begin small. Use a demo account with the same broker conditions and settings planned for live use. Check that orders, stops, volume, and session timing match the review report. Then, if the buyer elects to trade live, use a modest allocation and a predefined loss limit. Monitor the first updates as carefully as the original release, because a new executable can alter behavior.</p>
6211
6212<p>If a product fails a gate, walking away is a valid result of due diligence. There will always be another EA and another sales page. Capital is harder to replace than an opportunity. The strongest buyer position is not certainty about future profits. It is a documented understanding of what the software can do, where it can fail, and why the buyer has chosen an exposure level that remains acceptable.</p>
6213
6214<h2 id="audit-acceptance-brief">Write an Audit Brief With Acceptance Criteria</h2>
6215
6216<p>Before commissioning a code review, write down what decision the report needs to support. A short brief reduces the chance that a buyer receives a generic source listing when they actually need answers about risk, dependencies, or a specific marketing claim. Keep the requested work within the buyer's licence and the reviewer’s authorization.</p>
6217
6218<table style="width:100%;border-collapse:collapse;margin:16px 0;">
6219<thead><tr style="background:#f0f4ff;"><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Question</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Evidence to request</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Acceptance condition</th></tr></thead>
6220<tbody>
6221<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Can the source be built?</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Compiler version, build log, dependencies, and unresolved warnings.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Build result and known blockers are stated clearly.</td></tr>
6222<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">What can the EA do?</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">
6222Plain-language summary of entries, exits, sizing, stops, and order limits.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Important behavior is tied to code paths or observed tests, with uncertainty noted.</td></tr>
6223<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">What remains unverified?</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Unavailable services, missing files, license checks, and conditions not reproduced.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Open questions and their practical impact are included in the report.</td></tr>
6224</tbody>
6225</table>
6226
6227<p>Do not define success as “proves the EA will be profitable.” A code review can describe implementation and test selected behavior; it cannot establish future returns or remove market risk. A useful deliverable separates what was observed, what was inferred, and what could not be tested. Buyers can then make an informed decision without mistaking a polished report for a performance guarantee.</p>
6228
6229<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6230  <h3 style="margin-top:0;">Start With Transparency</h3>
6231  <p>Before putting an unfamiliar EA on a funded terminal, buyers can consider ForexMQ5's professional EX4 recovery service as part of a wider independent review process.</p>
6232  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com &rarr;</a>
6233</div>
6234    `},{slug:"mql4-to-ex4-compilation-explained",title:"How MetaEditor Converts MQL4 Into EX4 Files: What the MT4 Compiler Changes",metaTitle:"MQL4 to EX4 Compilation Explained: How MetaEditor Changes Code",metaDescription:"See how MetaEditor converts MQL4 source into an EX4 file, which source details survive compilation, and why build history affects code recovery and review.",keywords:"mql4 to ex4 compilation, MetaEditor compiler explained, how EX4 files are made, MT4 EX4 build format, MQL4 source code recovery",excerpt:"MetaEditor does more than save an MQ4 file with a new extension. This technical review explains the journey from MQL4 text to EX4 instructions, the information that disappears, and the clues still useful for legitimate recovery or code review.",date:"October 15, 2025",dateISO:"2025-10-15",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:Bs,imageAlt:"diagram showing MetaEditor converting MQL4 source into an EX4 file",tableOfContents:[{id:"why-the-conversion-matters",title:"Why the MQL4 to EX4 Conversion Matters"},{id:"from-editor-to-check",title:"What Happens Before an EX4 Is Written"},{id:"instructions-not-source",title:"Instructions, Calls, and Control Flow"},{id:"what-is-left-behind",title:"What Compilation Leaves Behind"},{id:"what-is-lost",title:"What Is Lost or Changed"},{id:"builds-and-environments",title:"Builds, Dependencies, and Runtime Context"},{id:"reading-a-simple-example",title:"Reading a Simple Before and After Example"},{id:"recovery-expectations",title:"Setting Realistic Recovery Expectations"},{id:"developer-checklist",title:"A Preservation Checklist for EA Developers"},{id:"final-perspective",title:"The Useful Technical Perspective"}],content:`
6235<p>An MQ4 file is a document a person can read, edit, comment on, and compile. An EX4 file is the compiled program that MetaTrader 4 loads. The two files can represent the same trading idea, but they are not interchangeable records of it. That difference matters to developers maintaining old Expert Advisors, traders trying to understand a purchased robot, and owners who have lost an original source archive.</p>
6236
6237<p>Compilation is often described as a simple conversion, but that description hides the important part. MetaEditor checks the meaning of the MQL4 program, resolves names and built in functions, prepares executable instructions for the MT4 environment, and packages the result in a binary file. In doing so, it retains some operational facts while discarding much of the human explanation that made the original easy to work with.</p>
6238
6239<p>This independent review guide maps the process in practical terms. It does not treat an EX4 as a mystery box or promise that every compiled file can be restored to its original form. Instead, it explains why a legitimate <
6239a href="/">ex4 to mq4 decompiler</a> request can produce useful working material in some cases, why results vary, and what information should be preserved before an EA becomes a recovery project.</p>
6240
6241<img src="${Bs}" alt="technical diagram of the MQL4 to EX4 compiler process" style="width:100%;border-radius:8px;margin:24px 0;" />
6242
6243<h2 id="why-the-conversion-matters">Why the MQL4 to EX4 Conversion Matters</h2>
6244
6245<p>MetaTrader needs a file that it can execute consistently inside its own platform. MQL4 source is designed for authors: it has whitespace, comments, variable names, function names, declarations, and choices of formatting. The compiler transforms that author facing material into a representation the platform can interpret. It is not meant to preserve every editorial decision made by the programmer.</p>
6246
6247<p>That is why changing an MQ4 file and compiling it creates a new EX4, while merely renaming an EX4 cannot create usable source. The compiler has access to the full language rules and the original text at the moment of compilation. A later analyst only has the output. They can infer structure from the instructions and retained metadata, but they cannot ask the file for a comment that was removed before the executable was assembled.</p>
6248
6249<p>For a trader, this distinction helps set boundaries around a code review. An EX4 may reveal input labels, order logic, indicator calls, messages, and control paths. It may not reveal the developer's rationale for a parameter, the version of an external library used at build time, or the notes explaining a safety rule. A recovered file should therefore be evaluated as reconstructed technical material, not presented as a certified copy of an absent repository.</p>
6250
6251<p>For an owner of a custom EA, the practical lesson is simpler. The EX4 is a useful deployment artifact, but it is not a backup plan. Source control, offline backups, build notes, and copies of included files protect the information that compilation cannot reliably preserve. The related guide to <a href="/blog/ex4-files-explained-for-mt4-users">EX4 files for MT4 users</a> provides a nontechnical starting point for readers who need the file roles explained first.</p>
6252
6253<h2 id="from-editor-to-check">What Happens Before an EX4 Is Written</h2>
6254
6255<p>Clicking Compile in MetaEditor starts a chain of checks and transformations. Exact internal implementation details are proprietary and can differ across releases, so it is better to think in terms of observable compiler responsibilities than claim a fixed public blueprint for every build. The broad sequence is familiar to software developers and explains the visible results.</p>
6256
6257<ol>
6258  <li><strong>Read the project input.</strong> MetaEditor reads the MQ4 file and follows relevant include directives. A program may depend on header files, libraries, resources, or configuration assumptions that are not contained in one source file.</li>
6259  <li><strong>Break text into language elements.</strong> Keywords, names, numbers, strings, punctuation, and operators are identified according to MQL4 rules. This is the stage at which formatting ceases to matter to execution.</li>
6260  <li><strong>Check grammar and declarations.</strong> The compiler verifies that statements are arranged legally and that functions, variables, and parameters are declared in valid places.</li>
6261  <li><strong>Resolve meaning.</strong> It determines which declaration a name refers to, whether types fit an operation, and whether calls match available functions.</li>
6262  <li><strong>Prepare executable representation.</strong> Valid program logic is expressed as instructions and references suitable for the MT4 runtime.</li>
6263  <li><strong>Package the binary.</strong> The final file carries the executable material and format information needed by the terminal, subject to the compiler version and compilation choices.</li>
6264</ol>
6265
6266<p>An error during these early stages prevents a normal output because the compiler cannot safely determine what the author intended. A missing semicolon, a call with unsuitable arguments, or a reference to an unavailable symbol can all stop the process. Warnings deserve attention as well. An EA can compile while still containing a design issue that only appears during testing, but the EX4 is at least the result of the compiler accepting the program under that build environment.</p>
6267
6268<img src="${Xu}" alt="MetaEditor checking MQL4 code before producing an EX4 file" style="width:100%;border-radius:8px;margin:24px 0;" />
6269
6270<h3>Names have different jobs during compilation</h3>
6271
6272<p>Names are useful to people, but a runtime does not need every descriptive label in order to execute a calculation. Consider a variable c
6272alled <code>maximumSpreadPoints</code>. The compiler first uses the declaration to understand its type and scope. Later executable instructions can refer to a location, an index, or another internal reference rather than repeatedly carrying the original spelling. The program can still compare spread values correctly even if a later reconstruction must call that item <code>var_12</code>.</p>
6273
6274<p>Some names are more likely to remain visible because the platform needs them for a user interface, a callable entry point, a resource reference, or diagnostic output. Others may survive in string data simply because the program prints them. None of this should be confused with a guarantee. Retention depends on the file format, build, code pattern, and compiler behavior. A careful reviewer treats names in output as evidence to assess, not as an exhaustive catalog of the original source.</p>
6275
6276<h2 id="instructions-not-source">Instructions, Calls, and Control Flow</h2>
6277
6278<p>Once the compiler has accepted the program, the central task is expressing its behavior in a form the MT4 runtime can use. It is helpful to call this executable instruction material rather than assume it is ordinary processor code. The essential point is that the EX4 contains a program representation tied to the MetaTrader environment, with operations, values, calls, and branches that together implement the EA or indicator.</p>
6279
6280<p>A source level statement can turn into several smaller actions. A moving average call requires values such as a symbol, timeframe, period, method, price choice, and shift. The compiled representation must obtain or reference those values, invoke the appropriate platform function, receive the result, and use it in a comparison. A simple source line can therefore become a sequence that is less friendly to read but still rich in behavioral clues.</p>
6281
6282<p>Control flow is particularly valuable when analyzing an EX4. Conditional tests lead to alternate paths. Loops repeat an instruction region. Function calls connect one portion of logic to another. Return paths mark the end of a routine. A capable analysis process can use those relationships to turn a low level sequence into structured MQL4-like code. The result often identifies the broad decision process even when the original layout and naming cannot be restored.</p>
6283
6284<p>Platform calls also provide useful anchors. References associated with common MQL4 functions such as indicator access, order operations, price data, or account values help place surrounding logic in context. Yet a call name alone does not establish intent. An <code>OrderSend</code> path may be an entry, a hedge, a recovery order, or a test routine. Analysts should follow the inputs, preceding conditions, and later management logic before making claims about how a robot trades.</p>
6285
6286<img src="${Vu}" alt="pipeline converting parsed MQL4 logic into EX4 executable instructions" style="width:100%;border-radius:8px;margin:24px 0;" />
6287
6288<h3>Why equivalent source can look different</h3>
6289
6290<p>Many source expressions can describe the same result. One developer might calculate a value in three named steps, while another writes one nested expression. A compiler may simplify constant calculations, organize temporary values differently, or arrange a condition into jumps that do not mirror the indentation of the MQ4 file. Reconstruction must choose one readable representation. It can be operationally equivalent without matching the lost author style.</p>
6291
6292<p>This is a key distinction for audits. The right question is often whether the reconstructed logic behaves as indicated and can be tested, not whether every line has the same appearance as a remembered original. When ownership and permission are clear, comparison against archived settings, old statements, or known behavior can help validate a recovered project. It cannot recreate information that was never written into the binary.</p>
6293
6294<h2 id="what-is-left-behind">What Compilation Leaves Behind</h2>
6295
6296<p>An EX4 is not plain text, but it is not devoid of context. It must contain enough information for MetaTrader to identify, load, and run the compiled program. The exact contents and accessibility of sections vary, but several categories commonly matter in examination.</p>
6297
6298<ul>
6299  <li><strong>Format and build clues.</strong> File headers and format characteristics can help identify the generation of tooling or the likely era of compilation. This guides compatibility analysis rather than proving the full project history.</li>
6300  <li><strong>Executable operations.</strong> The instructions implementing comparisons, calculations, calls, and branches are the basis for reconstructing behavior.</li>
6301  <li><strong>Constants and strings.</strong> Numeric thresholds, text messages, symbols, file paths, and labels may provide useful context. They should be read carefully because an unused string does not prove active behavior.</li>
6302  <li><strong>Inputs and properties.</strong> Parameters exposed in the platform can reveal a strategy's adjustable settings and defaults, though their original documentation may be absent.</li>
6303  <li><strong>References.</strong>
6303 Calls to known platform functions and references to external components can show dependencies that need attention during any rebuild or test.</li>
6304</ul>
6305
6306<p>These traces explain why analysis can be valuable even when a perfect source restoration is impossible. A reviewer can identify an indicator period, a maximum-order setting, an error message, or a time filter and then trace how that item participates in the wider logic. The process is evidence led. It should avoid treating a single preserved phrase as proof of a vendor's commercial promise or a program's live trading outcome.</p>
6307
6308<img src="${Hu}" alt="developer reviewing MQL4 compilation output in MetaEditor" style="width:100%;border-radius:8px;margin:24px 0;" />
6309
6310<h2 id="what-is-lost">What Is Lost or Changed</h2>
6311
6312<p>Comments are the clearest loss. They guide future maintainers but have no role in execution, so compilation does not need to preserve them. A comment stating why a stop loss is disabled, which broker condition motivated a workaround, or which experiment a block belongs to can be more valuable than the code itself. Once it is absent from the only surviving source archive, an EX4 cannot reliably supply it.</p>
6313
6314<p>Whitespace, line breaks, file organization, and most stylistic choices are also author level information. A reconstructed file may group calculations differently, use generated temporary names, and put conditions on different lines. This does not automatically imply an error. It reflects the one-way move from an expressive writing format to a runtime format.</p>
6315
6316<p>Meaningful internal names may be reduced or unavailable. A label such as <code>newsFilterEnabled</code> tells a reviewer far more than a generic local variable. If only the variable's operations survive, the label has to be inferred from surrounding behavior. Inference can be reasonable when supported by calls and constants, but it should be annotated as an interpretation rather than reported as original documentation.</p>
6317
6318<p>Source boundaries can change too. Helper functions may not remain obvious as separately authored units, and the exact form of an expression may be altered by compiler processing. An EX4 can preserve what the program does while failing to preserve the developer's preferred decomposition of the work. This is why recovery quality should be judged by readability, compilability, behavior review, and the stated purpose of the project rather than a claim of perfect textual reversal.</p>
6319
6320<h2 id="builds-and-environments">Builds, Dependencies, and Runtime Context</h2>
6321
6322<p>The phrase EX4 format can suggest that every file is alike. In practice, MT4 has a long history, and compiler or platform changes can affect how an executable is packaged and interpreted. Older files may expose patterns that familiar legacy utilities handle more easily. Later files can require approaches suited to their format and environment. File extension alone is not enough to choose a method.</p>
6323
6324<p>Build history is only one part of the context. An EA may use included definitions, imported libraries, custom indicators, files, global variables, chart objects, broker symbol conventions, or terminal settings. Recovering the central EX4 does not automatically recover these pieces. If a reconstructed project fails to compile or behaves differently, the cause may be a missing dependency rather than a defect in the extracted logic.</p>
6325
6326<p>A responsible technical intake records the file's origin, approximate compile date if known, terminal build information, and every accompanying file. It also keeps the original EX4 unchanged. Hashing an original file can help distinguish it from later copies, while a working directory can hold recovered material and notes. These habits are useful for ordinary maintenance and do not establish a right to inspect code that belongs to someone else.</p>
6327
6328<p>Readers comparing methods should separate an old free utility, manual research, and professional handling. The service at ForexMQ5 is reviewed as a specialist option for customers with a legitimate recovery or authorized review purpose, particularly when build identification and output cleanup matter. The service is not a substitute for permission, and no result should be assumed before the specific file is assessed.</p>
6329
6330<img src="${$u}" alt="flowchart showing build context and dependencies in EX4 compilation" style="width:100%;border-radius:8px;margin:24px 0;" />
6331
6332<h2 id="reading-a-simple-example">Reading a Simple Before and After Example</h2>
6333
6334<p>Imagine an EA that opens a trade when a fast average crosses a slow average. An author may write a clear sequence with comments and descriptive local variables:</p>
6335
6336<pre style="background:#f0f4ff;padding:16px;border-radius:6px;overflow-x:auto;font-size:13px;">
6336double fastNow = iMA(Symbol(), Period(), FastPeriod, 0, MODE_EMA, PRICE_CLOSE, 0);
6337double slowNow = iMA(Symbol(), Period(), SlowPeriod, 0, MODE_EMA, PRICE_CLOSE, 0);
6338bool buySignal = fastNow &gt; slowNow;
6339if (buySignal)
6340   PlaceBuyOrder();</pre>
6341
6342<p>The executable representation needs the parameter values, two platform calls, a comparison, a conditional branch, and a call to the order routine. A reconstruction might reasonably use generic temporary variables:</p>
6343
6344<pre style="background:#f0f4ff;padding:16px;border-radius:6px;overflow-x:auto;font-size:13px;">double v0 = iMA(Symbol(), Period(), input_1, 0, MODE_EMA, PRICE_CLOSE, 0);
6345double v1 = iMA(Symbol(), Period(), input_2, 0, MODE_EMA, PRICE_CLOSE, 0);
6346if (v0 &gt; v1)
6347   func_4();</pre>
6348
6349<p>The second version may be enough for a qualified reviewer to recognize the comparison and investigate <code>func_4</code>. It does not prove that <code>input_1</code> was originally called FastPeriod or that the condition was intended as a complete trading signal. Perhaps extra filters appear earlier in the routine. Perhaps the order function has risk checks not shown here. The example demonstrates how structure can survive while intent and naming must be established from a wider reading.</p>
6350
6351<p>That wider reading is especially important before putting reconstructed code into a terminal. The guide on <a href="/blog/how-to-read-recovered-mql4-expert-advisor-code">understanding MQL4 after decompilation</a> outlines how readers can organize a review of inputs, functions, trade operations, and dependencies. Any meaningful change should be compiled and tested in a controlled environment before live use.</p>
6352
6353<img src="${Gu}" alt="comparison of readable MQL4 source and compiled EX4 representation" style="width:100%;border-radius:8px;margin:24px 0;" />
6354
6355<h2 id="recovery-expectations">Setting Realistic Recovery Expectations</h2>
6356
6357<p>Decompilation is an interpretation task built around what the EX4 still contains. It can be highly useful for an owner who needs to understand a program, repair a project, or continue authorized maintenance. It cannot promise the original comments, exact names, folder layout, or development history. A responsible provider should describe output in those terms and ask customers to confirm they have the necessary rights.</p>
6358
6359<p>There is also a difference between output that compiles and output that is ready for trading. A reconstructed EA may require renamed variables, restored include files, corrected types, or manual review of routines before it builds cleanly. Once it compiles, it should still be checked for expected inputs, symbol handling, order sizing, error paths, and behavior in a test environment. Compilation validates language rules, not trading suitability.</p>
6360
6361<p>For users deciding whether to pursue analysis, this review site's main <a href="/">decompile ex4 to mq4</a> resource compares the practical considerations around file age, output quality, and method selection. The appropriate path depends on the file, the available records, technical skills, and the narrow authorized objective. A vendor's account lock, expiry check, or other access control is not a maintenance issue to bypass without explicit permission.</p>
6362
6363<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6364  <h3 style="margin-top:0;">Need a File Assessed for an Authorized Project?</h3>
6365  <p>ForexMQ5 is reviewed as a professional EX4 recovery option for owners and authorized users who can describe a legitimate maintenance or code review need. The file build, dependencies, and expected cleanup should be discussed before relying on any recovery result.</p>
6366  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
6367</div>
6368
6369<h2 id="developer-checklist">A Preservation Checklist for EA Developers</h2>
6370
6371<p>The best response to compilation limits is to prepare before source is lost. A small release routine can save far more time than any later reconstruction effort. It also makes support and migration work easier when a terminal or broker environment changes.</p>
6372
6373<ol>
6374  <li><strong>Keep the MQ4 and each include file together.</strong> Archive the actual release source, not only the EX4 copied to a terminal folder.</li>
6375  <li><strong>Use version control where possible.</strong> A repository preserves the progression of changes and gives maintainers context that no binary can provide.</li>
6376  <li><strong>Record the build environment.</strong> Note the MetaEditor version, relevant terminal details, compilation date, and any required libraries or indicators.</li>
6377  <li><strong>Save default settings and a change note.</strong> A set file and a brief release description explain how a delivered EA was configured.</li>
6378  <li><strong>Archive test evidence carefully.</strong> Keep the conditions and dates of testing, but do not treat historical results as a promise of future performance.</li>
6379  <li><strong>Plan an ownership handover.</strong> Custom development agreements should state source delivery, maintenance access, and rights clearly rather than leave them to assumption.</li>
6380</ol>
6381
6382<p>These steps support responsible continuity. They also reduce the temptation to treat an old EX4 as a complete technical archive. When a file must be reviewed later, the surrounding records can explain ambiguous values and make it easier to distinguish a missing component from a reconstructed code issue.</p>
6383
6384<h2 id="final-perspective">The Useful Technical Perspective</h2>
6385
6386<p>MetaEditor compilation gives MT4 an executable program, not a reversible diary of development. The EX4 retains behaviorally important instructions and some context, while comments, many names, formatting decisions, and portions of the original organization can disappear or change. That is the technical reason recovery can be meaningful without being identical to source restoration.</p>
6387
6388<p>For legitimate owners and authorized reviewers, understanding the conversion process improves decision making. It encourages preservation of originals and dependencies, careful assessment of build context, modest expectations for recovered output, and controlled testing after any rebuild. It also provides a better basis for evaluating a specialist service than vague claims about a one click reversal.</p>
6389
6390<p>The practical conclusion is not that every EX4 should be opened or that every recovery will have the same result. It is that the compiler leaves a structured trail, and the value of that trail depends on the file, the surrounding evidence, and the authorized purpose of the work. Good records remain the best protection. Technical analysis is most useful when it supports that disciplined approach.</p>
6391    `}
6391,{slug:"how-to-verify-forex-ea-backtest-results",title:"How to Verify Forex EA Backtest Results Before Trusting a Trading Robot",metaTitle:"How to Verify Forex EA Backtest Results | Trading Robot Guide",metaDescription:"Learn how to verify Forex EA backtest results, identify unrealistic testing assumptions, compare reports, and inspect trading logic before relying on a robot.",keywords:"verify forex ea backtest results, forex robot backtest verification, identify unrealistic EA backtests, trading robot backtest audit, inspect EA testing logic",excerpt:"A polished Forex EA report is evidence of a historical simulation, not proof of future results. This practical review guide shows how to check data, settings, risk, and code logic before trusting a trading robot.",date:"November 3, 2025",dateISO:"2025-11-03",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:Ku,imageAlt:"verification of Forex EA backtest results",tableOfContents:[{id:"report-is-not-proof",title:"A Backtest Report Is Not a Product Audit"},{id:"evidence-request",title:"Request the Evidence Behind the Chart"},{id:"data-and-model",title:"Check Historical Data and Modeling Choices"},{id:"trading-costs",title:"Recreate Costs That a Report Can Hide"},{id:"risk-shape",title:"Read the Risk Shape, Not Just Net Profit"},{id:"robustness",title:"Test Whether the Idea Survives Small Changes"},{id:"code-review",title:"What a Logic Review Can Confirm"},{id:"decision-workflow",title:"A Sensible Decision Workflow"},{id:"questions",title:"Questions Buyers Ask About EA Backtests"}],content:`
6392<p>A Forex EA sales page can make a historical test look settled and scientific. There may be a smooth equity curve, a large percentage gain, a long date range, and a screenshot from MetaTrader Strategy Tester. Those items can be useful starting evidence. They are not, by themselves, proof that a robot will trade the same way on another broker, with another spread, or in the next market period.</p>
6393
6394<p>The useful question is not whether a result is attractive. It is whether the result can be explained, repeated under disclosed assumptions, and connected to the logic inside the EA. A buyer who approaches a report this way is less likely to confuse presentation with verification. This review-site guide lays out a practical process for examining an EA backtest without assuming that every strong result is dishonest or that every weak result makes a strategy worthless.</p>
6395
6396<p>ForexMQ5 is considered here as a specialist option when an owner has a legitimate reason to obtain readable MQL4 for a code review. Its role in this process is limited but valuable: a recovered source file can help an experienced reviewer check whether the claimed trading behavior matches the implementation. It does not create a forecast, replace testing, or remove the need to respect ownership and licence terms.</p>
6397
6398<img src="${Ku}" alt="comparison between a promotional EA report and a verified test" style="width:100%;border-radius:8px;margin:24px 0;" />
6399
6400<h2 id="report-is-not-proof">A Backtest Report Is Not a Product Audit</h2>
6401
6402<p>Backtesting asks a program to apply rules to historical prices. It is a simulation with inputs. The price history, tick model, spread, commissions, swaps, execution assumptions, symbol settings, dates, starting balance, and EA parameters all influence the output. A report can therefore be internally accurate while still being a poor guide to real trading conditions. It may faithfully describe an overly favorable simulation.</p>
6403
6404<p>This distinction matters because a screenshot removes much of the context needed to evaluate a test. A curve does not reveal whether the test used variable spreads, whether commission was charged, whether the account balance supported the stated lot size, or whether a parameter was selected after repeated optimization. A statement such as "tested for ten years" also says little until the reader knows which ten years, which broker data, and which settings were used.</p>
6405
6406<p>Verification should be framed as a chain of questions. Can the seller provide the complete report rather than selected statistics? Can the reader identify the exact test configuration? Can another person rerun a similar test? Does the drawdown make sense given the trade distribution? Does forward behavior resemble the simulation in broad terms? Finally, if source access is authorized, does the code contain the conditions the report implies?</p>
6407
6408<p>A favorable answer to one question is encouraging, not conclusive. An unfavorable answer is not automatically evidence of deliberate manipulation either. A developer may have incomplete records, use a different platform build, or make an ordinary testing mistake. The buyer's aim is to decide whether the evidence is strong enough for the capital and risk they are considering.</p>
6409
6410<h2 id="evidence-request">Request the Evidence Behind the Chart</h2>
6411
6412<p>The first practical step is to ask for reproducible material. A serious evaluation needs more than a cropped image of total return. Request the full Strategy Tester report, the set file or a clear list of inputs, the symbol and timeframe, the test dates, the deposit currency and balance, the leverage assumption, and a description of the historical data source. If the robot relies on a 
6412specific broker suffix or trading session, that should be disclosed too.</p>
6413
6414<p>Complete reports allow a reviewer to inspect items that promotional summaries often omit: total trade count, average win and loss, maximum consecutive losses, relative drawdown, profit factor, expected payoff, modeling quality where relevant, and the distribution of trades over time. None of these measurements predicts a future outcome. Together they reveal whether the headline return depends on a tiny number of trades, a single market episode, or a level of leverage that the intended account cannot safely sustain.</p>
6415
6416<h3>Keep the original claim intact</h3>
6417
6418<p>Save the original report and sales copy before changing anything. Record the version number of the EA, download date, advertised settings, and any claims about broker compatibility. This protects against an easy source of confusion: comparing a newer file with an older screenshot or testing a different parameter preset. It also creates a clean record if a buyer later wants to ask the vendor a specific, factual question.</p>
6419
6420<p>Questions should be narrow. Instead of asking whether a robot is "real," ask which spread was used, whether commission and swap were included, why a test began on a particular date, or whether the published input file is the same one used for the report. Clear questions tend to produce clearer answers. They also make it easier to distinguish a disclosed limitation from an unexplained gap.</p>
6421
6422<img src="${Yu}" alt="reviewer uncovering the settings behind an EA backtest" style="width:100%;border-radius:8px;margin:24px 0;" />
6423
6424<h2 id="data-and-model">Check Historical Data and Modeling Choices</h2>
6425
6426<p>Historical data is the foundation of a backtest, and its quality varies. Bar data may be adequate for a slower strategy that makes decisions once per completed candle. It is less convincing for a scalper whose entries, exits, and stop losses depend on movement inside a candle. In that case, missing ticks, incorrect high and low sequencing, or a simplified execution model can materially change the result.</p>
6427
6428<p>Start by matching the strategy to the model. An EA that claims a few trades per month on the H4 chart has a different sensitivity from one that takes dozens of trades around news releases. Fast systems deserve extra scrutiny of tick data, latency assumptions, stop distance, and the broker's trade rules. A backtest that looks excellent only with a zero or fixed minimal spread may be demonstrating a condition that ordinary live accounts do not provide.</p>
6429
6430<p>Date selection is another important clue. Every strategy has periods that suit it and periods that challenge it. A trend-following approach may shine during persistent moves and struggle when price reverses frequently. A mean-reversion approach may show the opposite pattern. A report limited to a favorable interval cannot establish how the EA handles other regimes. Ask for a longer sample that includes calm and volatile periods, different interest-rate environments, and both rising and falling markets where the symbol permits it.</p>
6431
6432<p>Readers should also check whether the report begins immediately after a major change to the rules. If parameters were optimized using the first part of the history, the remaining data should be held out for a more honest check. Testing and selecting settings on the same years can make random historical patterns look like durable logic. That is a common research problem, not a unique problem of trading robots.</p>
6433
6434<h3>Repeat a baseline test before optimizing</h3>
6435
6436<p>When a trial version or authorized copy is available, reproduce the published configuration first. Use the same timeframe, symbol, dates, position sizing, and inputs. Do not begin by searching for better settings. The first comparison should answer a simpler question: does the reported behavior appear under the stated setup? Note every unavoidable difference, such as broker data, account currency, or platform version.</p>
6437
6438<p>Only after the baseline is recorded should a tester explore alternatives. A materially different outcome does not prove intent to mislead. It may result from different quotes, symbol specifications, gaps in data, or a platform setting. But it does show that the headline result is sensitive to conditions and should not be treated as a universal property of the EA.</p>
6439
6440<h2 id="trading-costs">Recreate Costs That a Report Can Hide</h2>
6441
6442<p>Costs are where many appealing simulations lose their practical meaning. Spread is the immediate gap between b
6442id and ask. Commission is commonly charged by the broker. Swap can accumulate on positions held overnight. Slippage reflects the possibility that an order fills at a worse price than requested. Each cost is normal, but a report that minimizes all of them can overstate what a retail account may experience.</p>
6443
6444<p>Use a spread that reflects the intended broker and trading hours rather than the best quote seen in a marketing image. If the system trades during rollover, news, or thin sessions, inspect what spreads do during those windows. A fixed spread can be a reasonable simplification for some studies, yet it should be presented as a simplification. A system with a very small average profit per trade has little room for even modest changes in transaction costs.</p>
6445
6446<p>Commission and swap deserve the same treatment. Confirm whether they are enabled in the test environment and whether their values resemble the planned account. Some EAs close positions quickly and are relatively insensitive to overnight financing. Others hold baskets for days, where financing can be a meaningful component of return. Hiding this information makes a report less useful even if no rule in the EA has changed.</p>
6447
6448<p>Execution assumptions require humility. A historical tester cannot perfectly recreate live liquidity, rejected orders, requotes, stop-level restrictions, or connection delay. The more a strategy depends on a precise fill, the more important it is to supplement backtesting with a period of monitored forward testing. The site guide on <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">testing decompiled MQL4 before live trading</a> explains how a controlled test plan can document this stage without treating a demo account as a guarantee.</p>
6449
6450<img src="${Ju}" alt="analyst checking hidden trading costs in an EA report" style="width:100%;border-radius:8px;margin:24px 0;" />
6451
6452<h2 id="risk-shape">Read the Risk Shape, Not Just Net Profit</h2>
6453
6454<p>Net profit is often the largest number on a report, so it attracts attention. Risk is usually visible elsewhere. A useful review looks at drawdown, losing streaks, position size, average loss, open exposure, and the path the equity curve took to reach its final value. Two tests with the same profit can expose an account to very different risks.</p>
6455
6456<p>First, compare the maximum drawdown with the intended account size and the buyer's tolerance for loss. Then ask whether the report captures floating drawdown or only closed trades. A grid or recovery system can show many small closed gains while carrying a large set of losing positions. The balance curve may look calm until the open exposure is forced to close. Equity data, margin use, and the largest aggregate position help put that possibility in context.</p>
6457
6458<p>Second, inspect trade sizing. Fixed lots, percentage-risk sizing, and progressive recovery sizing produce very different outcomes. A sequence in which lots grow after losses can create a smooth historical curve for a long time while concentrating risk in an adverse run. The presence of increasing lots is not enough to label a system unsafe, but it should lead to a request for a clear explanation of maximum exposure and failure scenarios.</p>
6459
6460<p>
6460Third, look for concentration. Did most profit come from one month, one currency pair, a handful of exceptional trades, or a narrow parameter combination? A strategy may legitimately have uneven returns. The issue is whether the seller describes that dependence honestly and whether the buyer can accept it. A report with few trades has wider uncertainty than one with many independent opportunities, even if its percentage gain is higher.</p>
6461
6462<h3>Signals that merit follow-up</h3>
6463
6464<ul>
6465<li>Very high win rates paired with occasional losses far larger than the average win.</li>
6466<li>An unusually smooth balance curve with no meaningful losing period across varied market conditions.</li>
6467<li>Small average trade profits that leave little allowance for spread, commission, or slippage.</li>
6468<li>Large differences between balance drawdown and equity drawdown.</li>
6469<li>Lot sizes that rise after losing trades without a plainly stated exposure limit.</li>
6470<li>A test that excludes difficult dates without explaining why they are irrelevant to the strategy.</li>
6471</ul>
6472
6473<p>These are prompts for investigation, not verdicts. A sound review identifies what needs explanation and then tests the explanation against the report, the settings, and where possible the code.</p>
6474
6475<h2 id="robustness">Test Whether the Idea Survives Small Changes</h2>
6476
6477<p>A strategy that works only at one exact setting may be fitted too closely to the past. Robustness testing asks what happens when reasonable inputs change a little. A reviewer might vary the spread, move the start and end dates, test another broker's data, or alter an entry parameter within a narrow range. The purpose is not to hunt for the best historical result. It is to see whether the core behavior remains recognizable.</p>
6478
6479<p>For example, a system that becomes unprofitable when spread rises slightly is cost-sensitive. A system whose drawdown doubles when a stop setting changes by a small amount is parameter-sensitive. These outcomes do not make the EA deceptive, but they should affect how much confidence a buyer assigns to a single polished report. A strategy with a less spectacular result and stable behavior across reasonable tests may be easier to understand than one with an exceptional result from a fragile setup.</p>
6480
6481<p>Separate in-sample research from out-of-sample checking. In-sample data is the period used to develop or choose parameters. Out-of-sample data is held back until afterward. The second period is not a crystal ball, but it is a useful test of whether the chosen rules merely describe the data used to create them. Walk-forward testing extends the idea by repeating the cycle across successive periods.</p>
6482
6483<p>Forward observation is also informative. Run the EA on a demo or small, controlled environment if appropriate, logging trades, spreads, rejected orders, and settings. Compare the type and timing of trades with expectations rather than demanding an identical equity curve. Markets do not replay history. The goal is to detect a major mismatch, operational problem, or hidden dependency before scale increases.</p>
6484
6485<img src="${KE}" alt="source code review supporting verification of EA trading logic" style="width:100%;border-radius:8px;margin:24px 0;" />
6486
6487<h2 id="code-review">What a Logic Review Can Confirm</h2>
6488
6489<p>A report describes an outcome. Code review can examine the instructions that produced trades. This is especially helpful where a seller's description makes specific claims, such as a fixed stop loss, no averaging, limited trading hours, or a news filter. An authorized reviewer can compare those claims with order placement, position management, lot calculations, and conditional branches in the MQL4 source.</p>
6490
6491<p>Reviewers commonly map several areas: how the EA detects a new bar or tick, the indicators and prices used for a signal, the conditions that block trades, the formulas for volume, the placement and modification of stops, and the rules for closing positions. They also search for date checks, account checks, symbol checks, imported libraries, and separate behavior in the Strategy Tester. The existence of a condition is not inherently improper. A date filter, for instance, may be a disclosed expiry mechanism or an ordinary schedule control. Context matters.</p>
6492
6493<p>Particular care is useful around data availability. An entry rule should generally rely on information available at the time of the decision. A reviewer can examine index use, bar completion checks, and indicator buffers to 
6493see whether the logic may be referring to a completed bar, a forming bar, or future information in a way that makes a historical simulation misleading. This analysis can be technically subtle, which is why a qualified MQL4 reviewer is preferable for complex robots.</p>
6494
6495<p>Source access should never be treated as permission to copy, unlock, distribute, or republish another developer's work. Buyers should first establish their contractual rights or obtain consent. For a legitimate maintenance, security, or audit purpose, the <a href="/">ex4 to mq4 decompiler</a> information on this review site describes the recovery route and its limitations. Recovered code may require cleanup, and its readability can vary by file and platform build.</p>
6496
6497<p>For a broader buyer-side checklist, see <a href="/blog/purchased-forex-ea-security-audit-checklist">how to audit a purchased Forex EA</a>. That guide focuses on hidden functions, external connections, and risk controls that belong alongside backtest verification. The two tasks overlap, but neither replaces the other.</p>
6498
6499<img src="${Zu}" alt="balanced assessment of source code and backtest evidence" style="width:100%;border-radius:8px;margin:24px 0;" />
6500
6501<h2 id="decision-workflow">A Sensible Decision Workflow</h2>
6502
6503<p>A disciplined workflow prevents a buyer from moving directly from an attractive screenshot to a funded account. It also makes conversations with a vendor more productive because each concern is tied to evidence rather than suspicion.</p>
6504
6505<ol>
6506<li><strong>Preserve the claim.</strong> Save the full report, offer page, EA version, and settings advertised at the time of evaluation.</li>
6507<li><strong>Request missing context.</strong> Ask for the data source, dates, costs, modeling approach, inputs, and account assumptions.</li>
6508<li><strong>Reproduce a baseline.</strong> Run the stated setup where an authorized copy permits it, documenting material differences in data or broker specifications.</li>
6509<li><strong>Stress reasonable assumptions.</strong> Test realistic spreads and costs, broader dates, and modest input changes without optimizing for a prettier curve.</li>
6510<li><strong>Study exposure.</strong> Review equity drawdown, lot progression, margin use, open baskets, and the consequence of a sustained adverse move.</li>
6511<li><strong>Validate operational behavior.</strong> Use a monitored forward period before considering larger deployment, with limits appropriate to the account.</li>
6512<li><strong>Review logic when authorized.</strong> If important claims remain unclear, arrange a source review within the buyer's rights and licence obligations.</li>
6513</ol>
6514
6515<p>At the end of the process, the outcome need not be a binary verdict. A buyer may conclude that the EA is understandable but too cost-sensitive for their broker, that it may suit a small test but not a large allocation, or that the available documentation is too thin to proceed. Declining an unclear product is a valid result of due diligence.</p>
6516
6517<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6518  <h3 style="margin-top:0;">Need an Authorized EA Logic Review?</h3>
6519  <p>ForexMQ5 is reviewed as a professional EX4 recovery option for owners with a documented, legitimate maintenance or audit purpose. The service can be considered when readable MQL4 is needed for qualified review.</p>
6520  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
6521</div>
6522
6523<p>Source review is one layer of evidence, not a performance promise. ForexMQ5 is positioned by this review site as the professional option for eligible recovery requests, starting from $50 per file. Prospective users should verify current terms directly, keep their entitlement records, and avoid treating recovery as a substitute for independent testing or risk controls.</p>
6524
6525<img src="${ep}" alt="final integrity check for a Forex EA evaluation" style="width:100%;border-radius:8px;margin:24px 0;" />
6526
6527<h2 id="questions">Questions Buyers Ask About EA Backtests</h2>
6528
6529<h3>Can a verified backtest guarantee future performance?</h3>
6530
6531<p>No. Verification can show that a test is documented, reproducible, and reasonably aligned with disclosed assumptions. It cannot guarantee future prices, liquidity, spreads, broker execution, or the continued suitability of a strategy. Historical results should be treated as research evidence with clear limitations.</p>
6532
6533<h3>Is a high win rate automatically a warning sign?</h3>
6534
6535<p>No. Some strategies are designed to have many small wins. The important follow-up is the size and frequency of losses, open exposure, and the method used when a trade moves against the position. A high win rate with rare but very large losses deserves careful scenario anal
6535ysis.</p>
6536
6537<h3>Should a buyer trust a Myfxbook or live account statement more than a backtest?</h3>
6538
6539<p>Live records can add useful evidence because they include real execution conditions. They still need context. Check whether the account is verified, how long it has operated, whether deposits or withdrawals affect the presentation, what risk settings were used, and whether the account represents the same version and configuration offered to buyers.</p>
6540
6541<h3>When is source inspection worth considering?</h3>
6542
6543<p>It is most useful when the robot will be entrusted with meaningful capital, when risk controls are unclear, or when observed behavior conflicts with documentation. The buyer should first confirm permission or ownership. A legitimate review can clarify implementation, but it must not be used to bypass licensing controls or duplicate a vendor's work.</p>
6544
6545<h3>What is the simplest rule to remember?</h3>
6546
6547<p>Trust the process more than the screenshot. Ask for complete inputs, recreate realistic conditions, examine risk before return, and increase exposure only after the available evidence supports that decision. Readers comparing technical routes can start with this site's <a href="/">EA decompiler software</a> overview, then decide whether their authorized use case requires professional recovery or ordinary forward testing.</p>
6548    `},{slug:"forex-ea-troubleshooting-why-automated-trading-robots-fail",title:"Forex EA Troubleshooting: Why Automated Trading Robots Fail and What to Check First",metaTitle:"Forex EA Troubleshooting: Why Robots Fail and What to Check | 2026",metaDescription:"Troubleshoot a Forex Expert Advisor that will not trade, places rejected orders, or has weaker results. Learn how to separate platform, broker, code, and market issues.",keywords:"forex ea troubleshooting, expert advisor not trading, mt4 ea errors, forex robot stopped working, automated trading robot failure",excerpt:"A Forex Expert Advisor can appear broken for very different reasons. This practical troubleshooting guide helps traders identify whether an EA problem comes from terminal permissions, broker specifications, data and market changes, or code that needs authorised maintenance.",date:"November 17, 2025",dateISO:"2025-11-17",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:tp,imageAlt:"Forex Expert Advisor troubleshooting on MetaTrader 4",tableOfContents:[{id:"define-failure",title:"Define What the EA Is Actually Doing"},{id:"safe-first-response",title:"Protect the Account Before Diagnosing"},{id:"terminal-permissions",title:"Check Terminal, Chart, and Permission Settings"},{id:"broker-contract",title:"Compare the EA With Current Broker Specifications"},{id:"logs-evidence",title:"Use Logs and Reproducible Tests as Evidence"},{id:"market-vs-software",title:"Separate a Market Problem From a Software Problem"},{id:"code-level-causes",title:"Recognise When the Cause Is Inside the Code"},{id:"repair-decision",title:"Choose the Right Repair or Replacement Path"},{id:"maintenance-plan",title:"Build an EA Maintenance Routine"},{id:"questions",title:"Common EA Troubleshooting Questions"}],content:`
6549<p>An Expert Advisor can fail in a way that looks deceptively simple: no new order appears, an order is rejected, or an automated strategy begins producing results unlike its earlier record. Those symptoms are not the same diagnosis. An EA may be operating normally while its entry conditions are absent. It may be trying to trade but encountering a broker rule it was never designed to handle. It may al
6549so contain an old assumption about symbols, prices, permissions, or account settings that is no longer true.</p>
6550
6551<p>The practical goal is not to force a robot to trade. It is to identify the first point where expected behaviour diverges from actual behaviour, then decide whether a settings change, broker clarification, controlled test, or authorised code review is warranted. This review-site guide treats an EA as trading software with operational limits, not as a promise of returns. No diagnostic step can establish that a strategy will be profitable in future conditions.</p>
6552
6553<p>For readers who need a starting point on compiled-file recovery, the main review of an <a href="/">ex4 decompiler</a> explains the difference between source recovery and ordinary parameter adjustment. Recovery is relevant only where the requester owns the software or has clear permission to inspect and maintain it. It should never be used to bypass licensing or copy a third party strategy.</p>
6554
6555<img src="${tp}" alt="Expert Advisor alert showing an automated trading issue" style="width:100%;border-radius:8px;margin:24px 0;" />
6556
6557<h2 id="define-failure">Define What the EA Is Actually Doing</h2>
6558
6559<p>Start by recording the behaviour in plain language. “It stopped working” is understandable but too broad to troubleshoot efficiently. A useful note names the symbol, timeframe, account type, terminal build, date and time, EA version, inputs, and the exact thing observed. Screenshots of the chart and relevant terminal tabs are useful when they include the time.</p>
6560
6561<p>Most cases fit one of five patterns. First, the EA is attached but makes no trade attempts. Second, it attempts an order and receives an error or rejection. Third, it opens trades with unexpected volume, stops, or timing. Fourth, it initializes incorrectly, removes itself, or shows a disabled status. Fifth, it continues trading but its results no longer resemble the conditions for which it was selected. Each pattern directs attention to a different layer.</p>
6562
6563<ul>
6564  <li><strong>No trade attempt:</strong> Check signal rules, chart symbol, timeframe, trading session filters, and whether ticks are arriving.</li>
6565  <li><strong>Rejected request:</strong> Read the error context, then compare volume, stops, price handling, and margin with broker requirements.</li>
6566  <li><strong>Unexpected order details:</strong> Preserve the order ticket and input values. Lot calculation, digit conversion, or stale settings may be involved.</li>
6567  <li><strong>Initialization failure:</strong> Look for missing files, unavailable indicators, blocked DLL use, expired credentials, or errors in the Experts tab.</li>
6568  <li><strong>Weaker trading results:</strong> Investigate market regime and execution costs before assuming that the terminal or code is defective.</li>
6569</ul>
6570
6571<p>This classification prevents a common mistake: changing ten inputs at once after a disappointing week. That destroys the evidence needed to find the cause and can add fresh risk. One observed symptom, one documented hypothesis, and one controlled change is a slower but more reliable pattern.</p>
6572
6573<h2 id="safe-first-response">Protect the Account Before Diagnosing</h2>
6574
6575<p>When behaviour is unexplained, protecting capital comes before restoring activity. A trader can disable automated trading, remove the EA from the chart, or move investigation to a comparable demo environment. Existing positions still require deliberate management according to the trader’s plan. Stopping automation does not automatically close positions, and closing positions solely because an EA is being investigated can itself create an unwanted trading decision.</p>
6576
6577<p>Make an untouched copy of the EX4, its set file if one exists, and relevant logs before updating or reinstalling anything. Note the current terminal build and broker server. If the robot is running on a VPS, also record whether the VPS restarted, disconnected, or changed terminal paths. These details can distinguish a software issue from an environmental event.</p>
6578
6579<p>A good incident record includes the last known normal trade, the first abnormal event, and every intervening change. Broker emails, platform updates, password resets, new account credentials, symbol changes, VPS migrations, and input changes all belong in the timeline. A cause sometimes becomes obvious once these events are placed in order.</p>
6580
6581<img src="${YE}" alt="Methodical repair process for an Expert Advisor" style="width:100%;border-radius:8px;margin:24px 0;" />
6582
6583<h2 id="terminal-permissions">Check Terminal, Chart, and Permission Settings</h2>
6584
6585<p>The first checks are deliberately unglamorous because they resolve many apparent failures. Confirm that the terminal is connected and receiving prices for the chart symbol. Verify that automated trading is enabled globally and that the EA properties permit live trading. An EA can display a friendly status while a global setting, account restriction, or chart-specific option prevents an order request.</p>
6586
6587<p>Then compare the active chart to the robot’s documented requirements. A strategy written for EURUSD may not recognise EURUSD.a, EURUSDm, or another broker suffix. A robot built around a particular timeframe may see different bar sequences when attached elsewhere. Session filters can be affected by broker server time and daylight-saving changes. A system intended to avoid a narrow time window may accidentally avoid its entire intended session after a time offset changes.</p>
6588
6589<p>Dependencies deserve the same attention. Some EAs need custom indicators in the correct folder, files in the terminal’s Files directory, or explicit permission for DLL or web requests. A missing dependency may produce a clear initialization message, but poorly handled errors can result in silence. Do not enable DLL imports or add unknown web addresses just to make a robot run. Confirm why the dependency exists and whether it is appropriate for software the account holder is entitled to use.</p>
6590
6591<p>Finally, test a fresh chart with the original settings rather than assuming an old chart is clean. This does not prove the strategy is sound. It simply isolates chart objects, templates, accidental parameter edits, and stale terminal state. If the EA begins working only on the fresh chart, compare the two configurations before making the live chart active again.</p>
6592
6593<h2 id="broker-contract">Compare the EA With Current Broker Specifications</h2>
6594
6595<p>Broker conditions are part of an EA’s operating environment. A robot does not know that a rule changed unless its logic reads and handles that rule correctly. Minimum and maximum trade volume, volume step, stop distance, freeze level, leverage, margin calculation, filling policy, commission structure, and symbol digits can differ across accounts and can change over time.</p>
6596
6597<p>Volume is a frequent source of trouble. An EA may calculate 0.13 lots while the symbol permits increments of 0.10, or it may calculate a size below the broker minimum after an account balance or leverage change. The appropriate response is not to round upward casually. First determine what the strategy intends, what the broker permits, and what risk the altered volume would create.</p>
6598
6599<p>Price precision is another issue. Older logic may assume four or five decimal quotes for a currency pair, while the broker exposes a different digit format, a suffix, or a contract specification that changes point value. Stops that were once accepted can become invalid if the requested distance is inside the current stop level. During volatile periods, spreads and available execution prices can make an otherwise valid calculation fail.</p>
6600
6601<p>Broker server moves can also affect robots that reference account server names, symbols, or time. The broker can confirm a migration, account type, and current contract specifications, but it may not know how a third party EA is programmed. Treat a server change as a hypothesis to test, not proof that the broker caused the failure.</p>
6602
6603<img src="${ZE}
6603" alt="Changing market and broker conditions affecting a trading robot" style="width:100%;border-radius:8px;margin:24px 0;" />
6604
6605<h2 id="logs-evidence">Use Logs and Reproducible Tests as Evidence</h2>
6606
6607<p>MetaTrader’s Experts and Journal tabs are often the most valuable evidence available without source code. Save the relevant entries rather than relying on a remembered error number. The surrounding lines may reveal the symbol, requested volume, price, stop levels, or sequence of events that led to the failure. A message only becomes meaningful in context.</p>
6608
6609<p>Common trading errors can point the investigation in a useful direction, but they are not universal verdicts. Invalid stops often indicate a requested stop level conflicts with current symbol rules. Invalid trade volume suggests a size, minimum, maximum, or increment mismatch. Insufficient money points to margin availability for the attempted order. Requotes or price-change messages may indicate fast prices or an execution model that the EA does not accommodate. An unknown-symbol message can indicate a naming mismatch. The exact label and handling can vary by terminal build and broker.</p>
6610
6611<p>Reproduce the issue in the smallest possible test. Use the same terminal build, broker server, symbol, timeframe, and inputs where practical. Test one condition at a time. For example, if a log suggests stops are too close, compare the requested distance with the broker’s published value and retest only after changing the relevant permitted input. Keep a record of the outcome. A test that does not reproduce the fault is still information, especially if the live environment differs in a specific way.</p>
6612
6613<p>Strategy Tester can help examine whether signals appear, but it has limits. Historical modeling, tick availability, spread assumptions, and execution behaviour may not match live conditions. A backtest should therefore answer a narrow question such as “does this configuration ever generate an entry on recent data?” It should not be treated as proof that a repair will work in live trading.</p>
6614
6615<img src="${JE}" alt="Reviewing Expert Advisor logs to locate a software fault" style="width:100%;border-radius:8px;margin:24px 0;" />
6616
6617<h2 id="market-vs-software">Separate a Market Problem From a Software Problem</h2>
6618
6619<p>An EA that trades correctly can still have disappointing results. This is especially important because a loss of performance often motivates unnecessary technical changes. Trend-following, breakout, mean-reversion, grid, and time-based systems each rely on conditions that can become less frequent or more expensive to trade. Lower liquidity, wider spreads, different volatility, stronger correlation, or an extended range can change outcomes without any defect in the executable.</p>
6620
6621<p>Compare current behaviour with the strategy’s stated logic, not just with a favourable historical period. Is the robot taking the type of setup it is supposed to take? Has trade frequency changed because its f
6621ilters are rarely satisfied, or because it cannot send orders? Are losses related to expected strategy risk, or are stops and lot sizes visibly wrong? These questions separate a strategy review from an operational repair.</p>
6622
6623<p>Use comparable windows when reviewing data. A short recent sample can be distorted by a single event, while a long sample can conceal an abrupt change. Look at trade count, average spread paid, average holding time, distribution of wins and losses, and the timing of rejected orders. Avoid reoptimizing repeatedly against a small recent sample. That process can fit noise and create confidence that does not survive new data.</p>
6624
6625<p>Readers evaluating whether historical results deserve scrutiny can also consult <a href="/blog/how-to-verify-forex-ea-backtest-results">this guide to warning signs in Forex EA backtests</a>. The purpose is not to assume manipulation. It is to distinguish a credible test process from conclusions drawn from a single attractive report.</p>
6626
6627<h2 id="code-level-causes">Recognise When the Cause Is Inside the Code</h2>
6628
6629<p>Source-level work becomes relevant after settings, permissions, specifications, and reproducible tests point toward a logic limitation. Examples include a hardcoded symbol that no longer matches the broker’s naming, a lot-sizing routine that fails at a particular balance boundary, or error handling that repeatedly retries an invalid request. A code review can also reveal assumptions about server time, digits, indicator buffers, or order selection that were not obvious from inputs alone.</p>
6630
6631<p>Access to source is not a licence to alter a purchased product. The requester should have ownership, an assignment, or explicit authorisation to inspect and maintain the EA. If the original MQ4 has been lost and the entitlement is clear, a recovery route may enable an MQL4 developer to review the actual logic. The detailed <a href="/blog/recover-lost-mq4-expert-advisor-source-code">lost MQ4 source recovery guide</a> covers the evidence and recovery choices worth considering before that step.</p>
6632
6633<p>Recovered or existing source should be handled like production software. Preserve the original version, make one change per revision, compile in an appropriate environment, and test the change away from a funded account. Add clear comments explaining why the change was made. A fix that merely removes a safety check, license restriction, or broker control is not responsible maintenance and may violate rights or terms.</p>
6634
6635<p>For an authorised recovery need, the service at ForexMQ5 is reviewed as a specialist option for EX4-to-MQ4 work. Its role is technical source recovery, not a guarantee that code will solve a trading problem or that a modified strategy will perform well. The client remains responsible for entitlement, independent testing, and any decisions made with the resulting code.</p>
6636
6637<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6638  <h3 style="margin-top:0;">Need Authorised Access for an EA Review?</h3>
6639  <p>ForexMQ5 is reviewed as a professional source-recovery option for owners and authorised users who need an EX4 examined for legitimate maintenance. Any recovered code still requires careful testing and review.</p>
6640  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
6641</div>
6642
6643<h2 id="repair-decision">Choose the Right Repair or Replacement Path</h2>
6644
6645<p>Not every failure needs a code change. A disabled AutoTrading setting, incorrect input, missing indicator, or outdated chart configuration may have a simple remedy. A broker specification mismatch may be manageable through documented parameters if the EA exposes them. A strategy that no longer fits current conditions may need a new evaluation rather than a technical patch.</p>
6646
6647<p>When the issue is a confirmed code assumption and the user is authorised to maintain it, request a scoped review from an MQL4 developer. Provide the original EX4 or source, the incident timeline, log excerpts, broker specification, inputs, and a precise desired outcome. “Make it profitable again” is neither testable nor a sound engineering requirement. “Make the symbol name configurable and reject unsupported symbols with a message” is specific and can be tested.</p>
6648
6649<p>There are situations where retiring the EA is the prudent outcome. Unsupported dependencies, no available rights to source, a vendor who can provide an updated build, or a strategy that cannot be validated under current conditions all change the calculation. A replacement should be evaluated on its own evidence rather than selected because it promises to recreate a past result.</p>
6650
6651<p>Where authorised source access is required for diagnosis, the homepage overview of <a href="/">decompile ex4 to mq4</a> options provides context on professional recovery, legacy free utilities, and hands-on approaches. It is sensible to choose a method based on file type, rights, confidentiality, and the need for usable maintenance output, not on claims of effortless repair.</p>
6652
6653<img src="${t0}" alt="Expert Advisor restored to a controlled testing workflow" style="width:100%;border-radius:8px;margin:24px 0;" />
6654
6655<h2 id="maintenance-plan">Build an EA Maintenance Routine</h2>
6656
6657<p>A maintained EA has an owner, a record, and a testing process. Keep the MQ4 source, compiled files, set files, documentation, and change history in more than one secure location. Record the intended symbols, timeframes, account assumptions, broker constraints, and risk settings. This information is far more useful during an incident than a vague memory of the settings that once worked.</p>
6658
6659<p>Review the terminal and broker environment on a schedule. Check broker notices for server moves, contract changes, and account changes. Confirm that the VPS and terminal are connected, that disk space and logs are available, and that the installed EA version is the intended one. Review performance and execution metrics without treating normal variation as an emergency.</p>
6660
6661<p>Before deploying any code or settings change, define what would count as a pass or a fail in a controlled test. Include expected order volume, valid stop placement, expected session behaviour, and any error messages that should no longer occur. Demo testing can reveal operational defects, but it cannot remove market r
6661isk. Keep the scope narrow and avoid treating a brief test as a performance certification.</p>
6662
6663<img src="${e0}" alt="Routine monitoring dashboard for Expert Advisor health" style="width:100%;border-radius:8px;margin:24px 0;" />
6664
6665<h2 id="questions">Common EA Troubleshooting Questions</h2>
6666
6667<h3>Why does an EA show as active but place no trades?</h3>
6668<p>It may be waiting for a valid signal, blocked by a session filter, attached to an unsupported symbol or timeframe, unable to receive ticks, or prevented from trading by a terminal or account setting. Logs and a fresh-chart test help determine which explanation fits.</p>
6669
6670<h3>Can a broker update make an EA fail?</h3>
6671<p>It can expose assumptions in an EA about symbols, volume steps, stop distances, leverage, server time, or execution. Confirm the published specification and timeline before concluding that an update caused the problem.</p>
6672
6673<h3>Does a profitable backtest prove the EA has been repaired?</h3>
6674<p>No. A backtest can check a limited hypothesis, but data quality, spread assumptions, modeling, and live execution differ. It does not guarantee future performance.</p>
6675
6676<h3>When is source code necessary?</h3>
6677<p>Source is useful when the evidence points to a logic or compatibility limitation that inputs cannot address. It should be accessed only by the owner or an authorised user, then modified and tested under disciplined version control.</p>
6678
6679<p>The strongest troubleshooting outcome is not simply a robot that resumes sending orders. It is a documented explanation of why it stopped behaving as expected, a proportionate corrective action, and a safer process for noticing the next change before it becomes an account-level surprise.</p>
6680    `},{slug:"purchased-forex-ea-security-audit-checklist",title:"Purchased Forex EA Security Audit Checklist: What to Inspect Before It Trades",metaTitle:"Purchased Forex EA Security Audit Checklist for MT4 and MT5",metaDescription:"Use this practical purchased Forex EA security audit checklist to inspect permissions, connections, trading controls, and hidden behavior before a robot reaches a live account.",keywords:"purchased forex ea security audit, forex ea audit checklist, inspect forex robot code, mt4 ea security review, check expert advisor permissions",excerpt:"A purchased Expert Advisor should be treated as software with trading authority, not as a black box. This review-site checklist shows how buyers can inspect files, connections, risk controls, and conditional behavior before live use.",date:"December 1, 2025",dateISO:"2025-12-01",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"19 min read",featuredImage:rp,imageAlt:"security auditor reviewing a purchased Forex EA before live trading",tableOfContents:[{id:"audit-mindset",title:"Treat a Purchased EA as Privileged Software"},{id:"safe-start",title:"Create a Safe Audit Workspace First"},{id:"file-provenance",title:"Verify the File, Seller, and Permissions"},{id:"code-visibility",title:"Decide What Level of Code Visibility Is Needed"},{id:"connection-review",title:"Map Connections and Data Requests"},{id:"trade-authority",title:"Inspect Trading Authority and Risk Controls"},{id:"conditional-paths",title:"Look for Conditional and Exceptional Paths"},{id:"controlled-testing",title:"Test Observations Without Trusting Results Blindly"},{id:"audit-record",title:"Turn Findings Into a Deployment Decision"},{id:"questions",title:"Purchased EA Audit Questions"}],content:`
6681<p>A purchased Forex Expert Advisor can open, modify, and close positions while it is attached to a MetaTrader chart. That authority makes an EA more than a strategy product. It is software operating inside a trading workflow, with access to prices, account context, terminal settings, and the ability to submit instructions to a broker. Buyers do not need to assume that every vendor is untrustworthy. They do need a repeatable way to decide what they are willing to let a program do.</p>
6682
6683<p>This guide is written from a review-site perspective for people evaluating a paid or downloaded EA before it is used on a live account. Its purpose is not to promise that an audit will expose every defect, nor to label unfamiliar code as malicious. A useful audit reduces uncertainty by documenting the file received, identifying what the EA can access, reviewing how it makes decisions, and testing observable behavior in a controlled environment. It also makes it easier to ask a vendor precise questions rather than relying on sales screenshots.</p>
6684
6685<p>The practical starting point is simple: do not confuse a profitable-looking backtest with a security review. A report can show historical simulation output while revealing nothing about web requests, account restrictions, order sizing, or behavior that occurs only under particular conditions. The same distinction applies when comparing an <a href="/">ex4 decompiler</a>: recovering readable material can improve visibility, but source visibility is one part of an audit rather than an automatic approval.</p>
6686
6687<img src="${rp}" alt="auditor reviewing a purchased Forex EA in a controlled workspace" style="width:100%;border-radius:8px;margin:24px 0;" />
6688
6689<h2 id="audit-mindset">Treat a Purchased EA as Privileged Software</h2>
6690
6691<p>Many buyers approach an EA as if it were an indicator. An indicator may display information, whereas an EA can be permitted to trade automatically. Depending on terminal settings and the functions it uses, it may al
6691so read account characteristics, inspect open orders, access local files within platform limits, or initiate permitted network activity. The exact capabilities depend on the platform, configuration, and code. The responsible conclusion is not panic. It is that installation deserves the same care given to any automation that can affect capital.</p>
6692
6693<p>An audit has four separate questions. First, is this the file the buyer intended to receive? Second, what capabilities does it request or appear to use? Third, do the visible rules and operational controls match the product description? Fourth, has its behavior been observed in a setting where mistakes do not create unacceptable consequences? Keeping these questions separate prevents a common error: approving a robot because its entry logic looks familiar while ignoring its position management.</p>
6694
6695<p>There is no single badge that answers all four questions. Vendor reputation, marketplace reviews, a digital receipt, compiler warnings, and a clean virus scan are useful inputs, but none is a complete audit. A receipt establishes a transaction, not the safety of a particular downloaded file. A scan can identify known threats, but it cannot certify trading logic. An audit is an evidence-gathering exercise that should produce a reasoned deployment decision, including the possibility of declining to deploy.</p>
6696
6697<p>Scope matters as well. A buyer reviewing a low-cost utility on a demo terminal may need a shorter checklist than a firm considering an EA for a monitored portfolio. In either case, the reviewer should define the goal before opening the file. Examples include verifying that a licensed robot has no unexpected communications, confirming advertised stop-loss behavior, or identifying why a robot opens more positions than its documentation suggests. “Find anything bad” is too vague to guide a credible review.</p>
6698
6699<h2 id="safe-start">Create a Safe Audit Workspace First</h2>
6700
6701<p>Do not begin by attaching an unfamiliar EA to the terminal that holds a live account. Make a separate workspace with a fresh MetaTrader installation or a dedicated operating-system profile. Use a demo account with no meaningful funds, no saved payment information, and credentials distinct from any production account. Disable automatic trading at the terminal level until the initial file and settings review is complete. If the EA needs a broker-specific symbol, document that fact instead of improvising on a live chart.</p>
6702
6703<p>Save the original download before changing its name, parameters, or location. Record the date, seller URL or marketplace order reference, file name, size, and a cryptographic hash if the reviewer has a suitable tool. This creates a baseline. If a later download differs, or a vendor sends an update, the reviewer can distinguish versions rather than relying on a file name such as RobotFinal.ex4. Screenshots of the product listing, installation guide, stated license, and default inputs belong in the same record.</p>
6704
6705<p>Audit copies should be isolated from the original. Put the received file in a read-only archive, then use a working copy for installation. Note every configuration change. This discipline is especially important with EAs that use external parameter files, DLL permissions, or companion indicators. A surprising behavior may come from a preset or another component rather than the EA itself, and a tidy record helps separate those possibilities.</p>
6706
6707<p>Before testing, inspect MetaTrader's permissions dialog and terminal options. AutoTrading, DLL imports, WebRequest permissions, and file access are not routine boxes to accept without thought. A vendor should be able to explain why each permission is required in plain language. A request can be legitimate, such as a licensed integration or a news feed, but legitimacy should be demonstrated by a documented purpose and a destination that the buyer can identify.</p>
6708
6709<img src="${r0}" alt="reviewer checking an EA installation for hidden settings and permissions" style="width:100%;border-radius:8px;margin:24px 0;" />
6710
6711<h2 id="file-provenance">Verify the File, Seller, and Permissions</h2>
6712
6713<p>File provenance is the first line of practical defense. Download from the vendor's official delivery channel or the marketplace account connected to the purchase. Avoid copies forwarded through chat groups, cloud drives, or forums, even when the file name looks identical. A forwarded copy can be outdated, modified, or unrelated to the product being sold. Where an official vendor publishes version numbers or checksums, compare them with the received file and retain the evidence of the comparison.</p>
6714
6715<p>Next, read the license and product description for operational promises that can later be checked. Does the seller say the EA uses a fixed lot size, one symbol, a defined session, or a specific maximum number of positions? Does it mention a license server, a news filter, a DLL, or a remote signal source? Write these claims into an audit worksheet. They are not proof, but they create criteria for identifying a mismatch. A vague listing that avoids basic operational detail deserves more caution, not less.</p>
6716
6717<p>Buyers should also distinguish a right to run software from a right to inspect or alter it. A commercial license may restrict reverse engineering, decompilation, modification, or sharing. Those terms and applicable law need to be respected. When source code is unavailable and a legitimate, authorized need for technical review exists, the site's overview of <a href="/blog/legal-rules-for-ex4-source-code-recovery">EX4 recovery rights and practical limits</a> explains why ownership, permission, purpose, and local rules should be considered before seeking deeper access.</p>
6718
6719<p>Ask the vendor for a support contact and a short explanation of updates. A responsive answer does not prove quality, but it provides an accountability path. Questions worth asking include whether updates change trading logic, how license checks work when a server is unavailable, whether the EA collects identifiers, and what happens if a broker 
6719changes symbol suffixes or execution rules. The answers should be saved beside the product claims, then compared with actual behavior during testing.</p>
6720
6721<h2 id="code-visibility">Decide What Level of Code Visibility Is Needed</h2>
6722
6723<p>Source code is the clearest way to inspect an EA's intended operations, but it is not always available or necessary for every buyer. A vendor may supply MQ4 or MQ5 source under a license, provide a written technical specification, or offer only a compiled EX4 or EX5. Each situation supports a different depth of audit. With source, a technically capable reviewer can search for functions, inspect inputs, and trace order paths. With a compiled file, the reviewer relies more heavily on permissions, logs, documentation, controlled observation, and authorized vendor disclosures.</p>
6724
6725<p>Readable code should not be treated as self-explanatory. MQL programs can use helper libraries, indirect function calls, conditional branches, and error handling that alter the outcome. The goal is to understand the operational surface, not to admire or copy a strategy. Reviewers should focus on categories: initialization, external calls, data collection, order creation, position changes, close logic, risk limits, and shutdown behavior. Variable names alone are weak evidence because they can be misleading or generic.</p>
6726
6727<p>Where a buyer owns the code or holds explicit permission for recovery and inspection, an <a href="/">ex4 to mq4 decompiler</a> may be considered as one technical route to obtain material for a qualified review. Recovered output can be incomplete or require cleanup, so it must be handled as an engineering artifact rather than a perfect original. It should not be used to bypass licensing restrictions, clone a vendor's strategy, or redistribute protected material.</p>
6728
6729<p>The service at ForexMQ5 is reviewed as a professional recovery option for customers with a documented, authorized purpose. Its role is technical recovery, not a blanket safety certificate or legal determination. Buyers remain responsible for their permissions and for validating any result before use. That distinction is valuable because a serious audit asks both whether code can be read and whether the planned review is appropriate.</p>
6730
6731<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6732  <h3 style="margin-top:0;">Need Authorized Code Recovery for a Review?</h3>
6733  <p>ForexMQ5 is presented as a professional option for owners and authorized users who need readable material for a documented maintenance or audit purpose. Any recovered output should still be reviewed and tested in a controlled environment.</p>
6734  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
6735</div>
6736
6737<h2 id="connection-review">Map Connections and Data Requests</h2>
6738
6739<p>External communication deserves focused attention because it can change both privacy and operational risk. In source, search for network-related functions, WebRequest usage, URL strings, socket libraries, DLL imports, email functions, and file-writing routines. In a compiled EA, review requested WebRequest addresses, terminal logs, vendor documentation, and network activity that can be observed within the permitted test setup. Record destinations exactly, including protocol, domain, and path where visible.</p>
6740
6741<p>Not every connection is suspicious. An EA may check a license, retrieve a calendar event, obtain a remote configuration, or send a support diagnostic. The question is whether the connection is disclosed, proportionate, and understandable. A product advertised as a fully local indicator but requesting access to unrelated domains requires an explanation. A connection that fails should also be tested: does the EA stop safely, continue with a documented fallback, or change its trading behavior without a clear message?</p>
6742
6743<p>Data requests should be examined with the same discipline. Identify what account or terminal information is plausibly needed for the stated feature. Account number, account currency, broker name, symbol, leverage, open positions, and terminal paths have different sensitivity and different functional reasons. An audit report should avoid speculation. It can say that a function appears capable of reading a value, that a log showed a request, and that the vendor did or did not document the purpose. It should not claim data was exfiltrated without evidence.</p>
6744
6745<img src="${a0}" alt="security review of EA connections and data requests" style="width:100%;border-radius:8px;margin:24px 0;" />
6746
6747<h2 id="trade-authority">Inspect Trading Authority and Risk Controls</h2>
6748
6749<p>The core review asks what orders the EA can create and how it controls exposure afterward. Trace or observe the conditions that lead to a buy, sell, pending order, modification, partial close, close-all action, or hedge. List the symbols and timeframes it can use. Check whether it filters orders by magic number or comment, because poor order identification can cause a robot to interfere with manual trades or other EAs. A safe test should include unrelated demo positions to see whether the EA recognizes its own orders correctly.</p>
6750
6751<p>Position sizing is often more important than the entry rule. Review fixed lots, balance or equity percentages, multipliers, rounding, broker minimums, and behavior after a losing trade. Terms such as recovery, grid, averaging, and multiplier do not automatically make an EA unacceptable, but they should lead to clear scenario testing. Determine whether a maximum number of trades, maximum volume, maximum drawdown response, stop loss, or time-based exit is actually present. If a protection is advertised, identify the input that c
6751ontrols it and test boundary values on demo.</p>
6752
6753<p>Also inspect failure handling. What happens when trading is disabled, spreads widen, margin is insufficient, an order is rejected, prices are unavailable, or a terminal restarts? A mature audit notes both intended safeguards and uncertainty. For example, a reviewer might document that the EA checks a spread threshold before a new order but that the reviewer did not establish how it behaves during a disconnect. This is more useful than declaring a robot safe based on one successful order.</p>
6754
6755<p>Logs are evidence, not decoration. Capture the Experts and Journal entries around each test. Clear messages that state why an order was skipped, rejected, or closed help a buyer validate the claimed rules. Silent changes, unexplained error loops, or repeated trade attempts should be added to the findings. A separate guide to <a href="/blog/how-to-verify-forex-ea-backtest-results">spotting misleading Forex EA backtest signals</a> can help readers keep the strategy-performance question distinct from this operational audit.</p>
6756
6757<img src="${i0}" alt="checklist confirming reviewed EA risk controls before testing" style="width:100%;border-radius:8px;margin:24px 0;" />
6758
6759<h2 id="conditional-paths">Look for Conditional and Exceptional Paths</h2>
6760
6761<p>Most troubling behavior is not necessarily visible during the first hour of testing. An EA can contain branches based on account number, broker, date, symbol, spread, day of week, balance, license status, or number of losses. Many of these conditions are ordinary. A session filter and an expiry notice are examples. The audit task is to identify conditions that materially change behavior and decide whether they were disclosed to the buyer.</p>
6762
6763<p>Create a condition matrix. Across the top, list meaningful states such as a new account, an expired license, a weekend, a high spread, a losing sequence, a different symbol suffix, a restart, and an unavailable network connection. Down the side, list expected outcomes: no trade, clear warning, normal trade, close positions, disable itself, or request support. Run only the scenarios that can be simulated safely and mark the rest as untested. This format converts a vague suspicion of hidden behavior into an honest record of what was observed.</p>
6764
6765<p>Pay particular attention to broad close functions, account-wide loops, and error-recovery routines. These can be appropriate in a portfolio manager, but their scope should match the product description. A one-chart EA that can close every order in the account needs a convincing documented reason and careful testing. Similarly, code that changes settings after an update check should be treated as a configuration-management issue that needs explanation, not as evidence of wrongdoing by itself.</p>
6766
6767<p>Some reviewers look only for malware signatures. That is too narrow. An EA can create unacceptable trading risk without being malicious. It may have an unadvertised martingale sequence, ignore its stated maximum trades, continue trying to order during errors, or use a stop loss in a way that differs from the documentation. The audit should capture these product and safety mismatches alongside traditional security observations.</p>
6768
6769<img src="${ap}" alt="detailed inspection of conditional paths in a Forex EA" style="width:100%;border-radius:8px;margin:24px 0;" />
6770
6771<h2 id="controlled-testing">Test Observations Without Trusting Results Blindly</h2>
6772
6773<p>Controlled testing turns static observations into evidence, but it cannot reproduce every market condition. Use a demo account and start with automatic trading disabled while checking inputs and log output. Then enable only the permissions required for the scenario. Test one change at a time: default settings, a reduced lot setting, an altered spread threshold, a restart, and a deliberately invalid configuration. Record the chart, symbol, timeframe, preset, build version, and time of each run.</p>
6774
6775<p>Strategy Tester can help exercise entry and exit paths, especially when visual mode and detailed logs are available. It is not a substitute for observing the EA on a live-like demo feed. Historical test conditions may not reproduce network failures, licensing behavior, broker execution differences, or every tick-dependent branch. Conversely, a demo observation is not proof of future performance. It only shows what occurred under the stated test c
6775onditions.</p>
6776
6777<p>Use conservative test limits. If the EA can place orders, choose the smallest permitted demo size and keep the account free of other automation. Never test whether a maximum-loss mechanism works by intentionally driving a live account toward loss. Instead, inspect the condition, use a simulator where available, or ask the vendor for documented examples. When a test produces an unexpected trade, stop, preserve logs and screenshots, and determine whether a configuration error explains it before repeating the run.</p>
6778
6779<h2 id="audit-record">Turn Findings Into a Deployment Decision</h2>
6780
6781<p>A good audit ends with a short report that another person can understand. Start with identification: product name, file hash, version, source, date received, test platform, and permissions enabled. Then separate findings into verified facts, vendor statements, observed behavior, and unresolved questions. This distinction prevents a report from converting assumptions into conclusions.</p>
6782
6783<p>For each material finding, write the evidence, impact, and action. An example might be: “The EA requested access to a stated license URL. The vendor documentation describes a license check. During a disconnected demo test, the EA displayed a license error and did not submit an order. Action: confirm the vendor's outage policy before deployment.” A different finding might be: “The documentation says one position maximum, but two positions were observed with default inputs. Action: do not deploy until the vendor explains the result.”</p>
6784
6785<p>Use three deployment outcomes. Approve for limited demo monitoring when the review matches the stated scope and remaining uncertainty is acceptable. Hold for clarification when evidence is incomplete or behavior cannot be explained. Reject or remove when the EA has unexplained authority, conflicts with its description, or creates risk outside the buyer's tolerance. Approval should not be permanent. Repeat a focused audit after material updates, broker migrations, changes in permissions, or major parameter changes.</p>
6786
6787<img src="${n0}" alt="audit report card used to decide whether to deploy a purchased EA" style="width:100%;border-radius:8px;margin:24px 0;" />
6788
6789<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6790  <h3 style="margin-top:0;">Considering a Professional Recovery Route?</h3>
6791  <p>ForexMQ5 is reviewed as an option for documented, authorized EX4 recovery needs. Recovery output is a starting point for inspection and testing, not a guarantee about an EA's security or trading results.</p>
6792  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
6793</div>
6794
6795<h2 id="questions">Purchased EA Audit Questions</h2>
6796
6797<h3>Can a buyer audit an EA without source code?</h3>
6798<p>Yes, but the scope is narrower. Buyers can verify provenance, inspect requested permissions, read logs, test in a segregated demo environment, compare behavior with documentation, and ask the vendor for explanations. Source or authorized readable output provides more direct visibility, but it does not eliminate the need for controlled testing.</p>
6799
6800<h3>Does a clean antivirus result mean the EA is safe to trade?</h3>
6801<p>No. A clean result may be useful evidence about known malicious files, but it does not validate trading logic, remote configuration, position sizing, or whether the EA follows its documentation. Security scanning and operational review address different questions.</p>
6802
6803<h3>What is the most important setting to inspect?</h3>
6804<p>There is no universal setting, but position sizing and loss-escalation behavior deserve early attention because they can change account exposure quickly. Also inspect maximum trades, stop-loss behavior, magic-number handling, symbol scope, and any permission for external communication or DLL use.</p>
6805
6806<h3>Should a buyer run the EA on a small live account first?</h3>
6807<p>A small live account still carries real consequences and is not a substitute for initial isolation and demo testing. If a buyer later chooses limited live deployment, that is a risk decision made after the audit, with conservative limits and active monitoring. No audit can guarantee a future result.</p>
6808
6809<p>The useful standard is not certainty. It is informed control. By preserving the original file, limiting permissions, checking claims against evidence, testing one scenario at a time, and documenting unresolved questions, a buyer can make a much stronger decision about whether a purchased EA belongs anywhere near a live trading account.</p>
6810`},{slug:"expert-advisor-mt4-to-mt5-conversion-plan",title:"Moving an MT4 Expert Advisor to MT5: A Practical Conversion and Validation Plan",metaTitle:"MT4 Expert Advisor to MT5 Conversion Plan | M
6810QL4 Migration Guide",metaDescription:"Plan an MT4 Expert Advisor conversion to MT5 with a practical MQL4 to MQL5 workflow covering source review, trading logic, testing, and controlled release.",keywords:"MT4 Expert Advisor to MT5 conversion, MQL4 to MQL5 migration plan, convert MT4 EA to MT5, MT5 trading robot validation, MQL5 order management",excerpt:"Converting an MT4 Expert Advisor for MT5 is an engineering and validation project, not a compiler switch. This independent guide maps the decisions, code areas, test evidence, and release controls that help owners move a strategy carefully.",date:"December 15, 2025",dateISO:"2025-12-15",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"18 min read",featuredImage:ip,imageAlt:"practical conversion path from an MT4 Expert Advisor to MT5",tableOfContents:[{id:"decision",title:"Decide Whether Conversion Is the Right Project"},{id:"inventory",title:"Build an EA Inventory Before Touching Code"},{id:"platform-model",title:"Understand the MT5 Platform Model"},{id:"source-readiness",title:"Prepare the MQL4 Source and Specifications"},{id:"conversion-work",title:"Convert the Strategy in Deliberate Passes"},{id:"trade-layer",title:"Rebuild Trade Handling and Position Logic"},{id:"data-indicators",title:"Check Data Access, Indicators, and Time"},{id:"test-evidence",title:"Create Evidence Through Testing"},{id:"release",title:"Release Gradually and Maintain Both Versions"},{id:"service-review",title:"Where Source Recovery Fits the Migration"},{id:"questions",title:"Questions About MT4 to MT5 EA Conversion"}],content:`
6811<p>An MT4 Expert Advisor can represent years of small decisions: which spread limit applies at a particular time, how a partial close is handled, when a signal is ignored, and which inputs were useful only after several rounds of testing. Moving that program to MetaTrader 5 is therefore not a file-format exercise. It is a conversion project in which the owner needs to preserve the intended strategy while adapting it to a different programming interface, tester, and trading model.</p>
6812
6813<p>MT5 can be attractive for its broader market support, modern development environment, and multi-threaded testing tools. Those advantages do not mean that every MT4 robot should be moved immediately. A stable EA at a broker that c
6813ontinues to support MT4 may not justify disruption. On the other hand, a broker change, a new asset class, a requirement for MT5 infrastructure, or a desire to consolidate development can create a sensible reason to plan the work.</p>
6814
6815<p>This review-site guide is written for owners, developers, and buyers evaluating that decision. It does not promise that a port will produce the same trading result. Historical data, contract specifications, execution conditions, and code behavior can differ between platforms. The useful goal is more disciplined: document what the MT4 EA is intended to do, implement that intention transparently in MQL5, and gather enough evidence before putting the new version into meaningful use.</p>
6816
6817<img src="${ip}" alt="bridge representing a planned MT4 Expert Advisor conversion to MT5" style="width:100%;border-radius:8px;margin:24px 0;" />
6818
6819<h2 id="decision">Decide Whether Conversion Is the Right Project</h2>
6820
6821<p>A migration starts with a business and technical question, not with a code translator. List the change that is driving the project. Perhaps the intended broker offers only MT5 for a new account. Perhaps the EA needs symbols or exchange-style instruments unavailable in its current arrangement. Perhaps a development team wants a single codebase going forward. A written reason keeps the scope focused when the work becomes more complicated than expected.</p>
6822
6823<p>Next, distinguish a conversion from a redesign. A conversion aims to retain the existing entry conditions, exits, sizing rules, safety checks, and user controls as closely as practical. A redesign changes one or more of those elements deliberately. Both can be valid, but mixing them makes results impossible to interpret. If a developer changes a trend filter while also replacing the trade API, a difference in test results cannot be attributed to the platform alone.</p>
6824
6825<p>Owners should also assess the EA's condition. An unattended robot with undocumented settings, hard-coded broker assumptions, and no repeatable MT4 test may need an audit before any port. An EA with a clear specification, source history, saved parameter files, and a known baseline is a better conversion candidate. The site guide on <a href="/blog/forex-ea-troubleshooting-why-automated-trading-robots-fail">why Expert Advisors stop working</a> is useful context when the immediate problem is behavior rather than platform availability. Fixing an existing fault and changing platforms at once usually expands risk.</p>
6826
6827<h3>Use a simple go or pause screen</h3>
6828
6829<p>A project can move ahead when the owner has a legitimate right to change the source, can identify the currently deployed build, has a reason to use MT5, and can reserve time for testing. It should pause when source ownership is unclear, the EA depends on a vendor licence that prohibits modification, the original logic cannot be described, or no representative data and test environment are available. Pausing is not failure. It prevents an expensive attempt to recreate a black box from becoming a live trading experiment.</p>
6830
6831<p>There is a further choice for teams with several robots. Do not convert everything in order of age. Rank each EA by operational importance, availability of source, complexity, current usage, and expected benefit from MT5. Start with a modest but representative robot. The first conversion exposes local conventions for symbols, repositories, testing, and deployment without making the most valuable system the learning exercise.</p>
6832
6833<img src="${o0}" alt="checklist for deciding whether an MT4 EA should move to MT5" style="width:100%;border-radius:8px;margin:24px 0;" />
6834
6835<h2 id="inventory">Build an EA Inventory Before Touching Code</h2>
6836
6837<p>The conversion package should be more than one MQ4 file. Begin by preserving the exact MT4 release that is currently understood to work. Save its source, compiled file, include files, libraries, presets, chart templates, logs from representative runs, and the details needed to reproduce the original test. Record the build number, broker, symbol spelling, timeframe, account type, and the date range used for a baseline. A source-control tag is preferable; a dated archive with a checksum is still better than relying on a desktop folder.</p>
6838
6839<p>Create a behavior inventory in plain language. It should answer questions a future developer would otherwise infer from code. What conditions create a buy or sell signal? Can both directions be open? How is lot size calculated? What is the maximum exposure? Does the EA use a magic number? Does it avoid certain sessions, spreads, news times, or days? Does it modify stops, close portions, or recover from rejected orders? Include every external dependency, from custom indicators to DLL calls and file inputs.</p>
6840
6841<p>Inputs deserve special care. Export a set file for each production configuration and label which account or purpose it supported. An input named Risk may mean a percentage of balance in one EA and a fixed lot multiplier in another. Names are clues, not specifications. For each input, record 
6841its default, permitted range, business meaning, and interaction with other inputs. This inventory later becomes the acceptance checklist for the MT5 interface.</p>
6842
6843<p>The baseline is not a promise of future performance. It is a reference point for behavior. A useful baseline includes trade count, order timestamps, direction, volume, entry and exit reason, stop and target levels, and diagnostic messages. Total profit alone is weak evidence because many faulty ports can accidentally produce a similar headline figure. A conversion reviewer should be able to compare the sequence of decisions, not merely the final balance curve.</p>
6844
6845<h2 id="platform-model">Understand the MT5 Platform Model</h2>
6846
6847<p>MQL4 and MQL5 look related, which can make early conversion progress deceptive. Their event functions, object orientation support, standard library, and syntax share familiar ground. Yet the surrounding trading model differs enough that copied code can compile while still expressing the wrong assumption. A careful plan treats the platform model as a design input.</p>
6848
6849<p>One important distinction is the relationship among orders, deals, and positions. MT5 records trading activity with separate concepts that can matter when the EA tracks fills, pending requests, and exposure. Account configuration also matters. Netting accounts combine exposure for a symbol into a position, while hedging accounts can allow multiple positions. An MT4 strategy that identifies one trade solely by symbol may behave differently if it is not redesigned around tickets, magic numbers, and the account model it will actually use.</p>
6850
6851<p>Symbol properties are another frequent source of silent assumptions. Tick size, tick value, volume steps, stops levels, filling modes, trading sessions, and contract size should be queried from the target symbol instead of copied from a familiar MT4 broker. A five-digit Forex pair, an index CFD, and a metal can demand different price normalization and volume validation. The port should reject an unsuitable environment with a clear message rather than rounding values invisibly.</p>
6852
6853<p>MT5's Strategy Tester provides capabilities that invite better investigation, including different testing modes and optimization tools. It still relies on the quality and relevance of historical data, trading costs, and model settings. The tester does not certify a strategy. It gives the team a controlled way to ask whether a particular implementation reacts as expected under stated assumptions.</p>
6854
6855<img src="${l0}" alt="developer comparing MT4 and MT5 trading model choices" style="width:100%;border-radius:8px;margin:24px 0;" />
6856
6857<h2 id="source-readiness">Prepare the MQL4 Source and Specifications</h2>
6858
6859<p>Clean source reduces conversion ambiguity. Compile the MQ4 project in its original environment if possible, resolve known warnings where doing so does not alter behavior, and remove unused experiments only after archiving them. Name files consistently and make dependencies explicit. If a custom indicator is called by file name, capture the exact indicator version. If the EA reads a CSV file or global variables, include examples and explain the expected format.</p>
6860
6861<p>Then separate strategy logic from platform plumbing. Signal calculation, risk calculation, order submission, position monitoring, and logging should be identifiable units even if the original EA is procedural. This does not require a wholesale rewrite. It means creating boundaries so that a reviewer can replace a trade function without accidentally altering the entry rule. In an older robot, comments beside non-obvious logic can be more valuable than elegant refactoring.</p>
6862
6863<p>Owners who no longer have MQ4 source should not assume that an EX4 can simply be opened in MetaEditor and saved as MQL5. A compiled MT4 file is not an MT5 source project, and access rights remain relevant. Where the requester owns the software or has written permission for recovery, an <a href="/">ex4 decompiler</a> review can help explain recovery options before a conversion begins. Recovered source should be treated as an engineering starting point that needs inspection, not as an authoritative record of every original comment or name.</p>
6864
6865<p>It is also sensible to request source from the original author first. A vendor may offer a supported MT5 edition, an update path, or an approved maintenance arrangement. That route can be clearer than reverse engineering a licensed product. Any recovery or conversion request should have documented ownership or authorization, a narrow maintenance purpose, and restricted handling of the resulting files.</p>
6866
6867<h2 id="conversion-work">Convert the Strategy in Deliberate Passes</h2>
6868
6869<p>A reliable conversion is easier to review when it proceeds in small passes. First create an MQL5 project that compiles with minimal scaffolding. Then bring across constants, inputs, and pure calculations. After that, convert indicators and data access. Finally introduce trade execution and lifecycle management. Compile and test after each pass. A giant copy-and-paste conversion may create hundreds of errors that conceal the one conceptual issue responsible for most later defects.</p>
6870
6871<p>Event handling should be intentional. MQL5 programs can use initialization, tick, timer, trade transaction, and deinitialization events according to their design. A tick-driven MT4 EA may remain tick-driven, but a strategy that needs reliable scheduled maintenance may benefit from a timer. The key question is what state is read and changed in each event. Do not let an order-management routine run twice because it is called from more than one path without a guard.</p>
6872
6873<p>Replace legacy market-data calls with MQL5 approaches that clearly state which symbol, timeframe, and bar are being used. Indicator functions commonly return handles whose values are copied through buffers. That is more explicit than the older style, but it adds lifecycle responsibilities. Create the handle, check that it is valid, confirm sufficient calculated bars, copy the needed values, and release resources when appropriate. A port that reads buffer index zero when the original logic used a completed bar can change signals substantially.</p>
6874
6875<p>Translation aids can speed up syntax changes, but they cannot decide strategy intent. The same applies to an automatic <a href="/">decompile ex4 to mq4</a> workflow when the original source is missing. Human review is required to decide whether an old order loop represents an intentional rule, a workaround for a particular broker, or a defect that should be preserved temporarily for comparison. Keep a conversion log with every intentional departure from the MT4 baseline.</p>
6876
6877<img src="${s0}" alt="MQL4 source being reviewed and translated into an MQL5 project" style="width:100%;border-radius:8px;margin:24px 0;" />
6878
6879<h2 id="trade-layer">Rebuild Trade Handling and Position Logic</h2>
6880
6881<p>
6881The trade layer deserves its own review because it connects strategy decisions to account exposure. MQL5 provides classes and request structures that can make requests clearer, but a convenient method call is not proof that a transaction succeeded. The implementation should inspect result codes, capture broker feedback, and record enough context to diagnose a rejected request. A successful submission request and a completed fill are not necessarily the same event.</p>
6882
6883<p>Define an identity policy before coding. For a single-symbol EA, identify its activity through a combination of magic number, symbol, and expected direction or comment where appropriate. For a portfolio EA, document how each strategy instance avoids confusing another instance's positions. This is especially important on netting accounts, where a position can represent combined exposure. The code should know whether it is allowed to add, reduce, reverse, or leave a position untouched.</p>
6884
6885<p>Volume and price validation must be rebuilt for the target contract. Normalize prices against the symbol's point and tick size, but do not use normalization to hide a bad calculation. Validate volume against minimum, maximum, and step. Check whether a stop loss or take profit meets the broker's current distance rules. Capture the spread and relevant properties in logs during testing. These checks make a rejection explainable and prevent a port from behaving differently only because a rounding rule changed.</p>
6886
6887<p>Partial close, trailing stop, break-even, and pending order logic are common trouble spots. Write scenario tests for each one: no open position, one qualifying position, several positions on a hedging account, a partially filled request, a requote or rejection, and a restart while a position exists. A strategy can appear correct in a simple historical run while failing to recover state after a terminal restart. The related article on <a href="/blog/mql4-to-ex4-compilation-explained">how MT4 compiles EX4 files</a> can help owners understand why a controlled build process and preserved source matter throughout this work.</p>
6888
6889<h2 id="data-indicators">Check Data Access, Indicators, and Time</h2>
6890
6891<p>Most conversion discrepancies appear at the edges of data handling. Confirm how many bars are required before signals are enabled, which bar is considered closed, and how the EA behaves when history has not synchronized. An MT5 program should check that the required data and indicator calculations are available before using them. Otherwise a temporary empty buffer can become a false signal or a divide-by-zero condition.</p>
6892
6893<p>Custom indicators need the same scrutiny as the EA. Convert and test them separately, verify buffer order and drawing settings, and compare their values on selected timestamps. If the EA calls iCustom, document the parameter order and ensure the target file is installed where the terminal expects it. Do not assume a chart that looks similar has identical numerical buffers.</p>
6894
6895<p>Time filters need an explicit reference clock. Record whether sessions are based on server time, UTC, local operating-system time, or a calculated offset. Daylight-saving changes and broker server changes can otherwise shift a strategy without any code change. The conversion specification should say what happens on Friday close, market holidays, missing ticks, and a newly attached chart. These are operating conditions, not minor details.</p>
6896
6897<img src="${d0}" alt="stepwise upgrade path for validating data and indicators in MT5" style="width:100%;border-radius:8px;margin:24px 0;" />
6898
6899<h2 id="test-evidence">Create Evidence Through Testing</h2>
6900
6901<p>Testing should answer increasingly difficult questions. Start with compilation and static review. Then use visual tests and controlled cases to establish that the EA opens, changes, and closes trades at intended points. After that, compare the MT4 baseline and the MT5 port on equivalent periods as closely as available data permits. Differences in tester data and execution model mean exact equality may be unrealistic; unexplained differences still require investigation.</p>
6902
6903<p>Build a case table rather than relying on one broad backtest. Include a normal long entry, normal short entry, a blocked entry due to spread, a stop loss, a take profit, a trailing update, a partial close if applicable, an error response, and a restart with open exposure. For each case, specify setup, expected action, observed logs, and reviewer result. This gives a developer an actionable defect list and gives the owner a record of what was checked.</p>
6904
6905<p>Use out-of-sample periods and forward observation to look for implementation issues, not to manufacture a flattering report. Confirm that inputs are loaded correctly, orders are identified properly, logging is readable, and risk limits work under current symbol rules. A demo or small, appropriately controlled release can expose operational details that historical simulation cannot reproduce. It should never be presented as proof of future returns.</p>
6906
6907<p>Optimization is a separate activity from conversion. If settings are optimized during the port, keep the original parameter set and the optimized set as different experiments. Record the data window, criterion, constraints, and selection rationale. Otherwise the team cannot tell whether a result comes from MQL5 adaptation or from a newly fitted configuration.</p>
6908
6909<h2 id="release">Release Gradually and Maintain Both Versions</h2>
6910
6911<p>A conversion is not finished at the first successful MT5 test. Package the release with the source tag, compiled EX5, input files, installation notes, target symbols, account-model assumption, and a change log. Add a version string to logs so a later support review can identify the exact build. Preserve the final test cases and baseline reports alongside the release.</p>
6912
6913<p>Where operating conditions permit, retain the MT4 version during an observation period rather than deleting it on launch day. The two systems do not need to trade the same account or volume to be useful for comparison. The point is to preserve a known reference while the MT5 
6913implementation is watched for missed sessions, handling errors, or unexpected broker constraints. Any behavior difference should be classified as intended, platform-driven, data-driven, or unresolved.</p>
6914
6915<p>Assign a maintainer and a rollback decision in advance. The maintainer should know where source and credentials are held, who approves parameter changes, and how an incident is recorded. A rollback plan should define what happens after repeated trade errors, an unexpected position state, or a failure to initialize. Clear ownership is more valuable than an assumption that a port will need no further attention.</p>
6916
6917<img src="${c0}" alt="careful transition from an MT4 EA release to a maintained MT5 release" style="width:100%;border-radius:8px;margin:24px 0;" />
6918
6919<h2 id="service-review">Where Source Recovery Fits the Migration</h2>
6920
6921<p>Source availability often determines whether an MT4 to MT5 conversion is a straightforward development task or a larger discovery project. The preferred path is always the maintained MQ4 project from the rightful owner or authorized developer. If that source was genuinely lost and the requester has the relevant rights, recovery may provide a starting point for documenting and converting the logic. It does not eliminate the need for cleanup, code review, or validation.</p>
6922
6923<p>ForexMQ5 is positioned by this review site as a professional EX4-to-MQ4 recovery option for owners with a documented and legitimate maintenance purpose. Its role in a migration is limited and practical: obtain reviewable material when authorized source is unavailable, then have a qualified developer assess it before any MQL5 conversion. The service should not be viewed as permission to inspect third-party commercial software, bypass licence controls, or distribute recovered code.</p>
6924
6925<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
6926  <h3 style="margin-top:0;">Need an Authorized Starting Point for a Migration?</h3>
6927  <p>ForexMQ5 is reviewed as a professional recovery option for users who can document ownership or authorization before a lost-source MT4 EA conversion project begins.</p>
6928  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
6929</div>
6930
6931<h2 id="questions">Questions About MT4 to MT5 EA Conversion</h2>
6932
6933<h3>Can an MQ4 file be opened directly as an MQ5 file?</h3>
6934<p>No. The project needs MQL5-compatible code and a review of platform assumptions. Some syntax and calculations may move easily, while indicators, order handling, positions, and environment checks need purposeful adaptation.</p>
6935
6936<h3>Will the MT5 version have identical backtest results?</h3>
6937<p>Not necessarily. Tester data, symbol properties, costs, execution modeling, and the account model can differ. The responsible standard is documented comparison and explanation of material differences, not an unsupported claim of identical results.</p>
6938
6939<h3>How long should the conversion take?</h3>
6940<p>Scope depends on the robot, its dependencies, documentation, and required test cases. A small, well-documented EA can take far less effort than a portfolio system with custom indicators and complex management. Estimation should follow the inventory and specification, not precede them.</p>
6941
6942<h3>Should a trader optimize settings again on MT5?</h3>
6943<p>Only as a separately documented experiment. First establish a faithful port using the known MT4 settings. Then evaluate any optimization with out-of-sample checks and clear constraints so that curve fitting is not confused with successful conversion.</p>
6944
6945<h3>What is the safest first action?</h3>
6946<p>Archive the working MT4 release, verify rights to the source, write the behavior inventory, and define the target MT5 account model. Those four actions turn a vague platform move into a project that developers and owners can review responsibly.</p>
6947`},{slug:"expert-advisor-source-recovery-vs-rebuild-budget-guide",title:"Expert Advisor Source Recovery vs Rebuild: A Practical Budget Guide for Lost MQ4 Files",metaTitle:"Expert Advisor Source Recovery vs Rebuild Cost Guide | 2026",metaDescription:"Compare the planning costs, risks, timelines, and testing work behind rebuilding a lost MT4 Expert Advisor versus recovering its MQ4 source from an EX4 file.",keywords:"expert advisor source recovery vs rebuild, cost to rebuild forex ea, lost mq4 source code, ex4 recovery budget, mt4 expert advisor development cost",excerpt:"A working EX4 with missing MQ4 source creates a budget decision, not just a coding problem. This guide helps EA owners compare recovery and full reconstruction by scope, evidence, risk, testing needs, and long term maintenance value.",date:"January 5, 2026",dateISO:"2026-01-05",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:np,imageAlt:"cost calculator comparing rebuild vs decompilation",tableOfContents:[{id:"decision-frame",title:"Treat the Missing Source as a Decision Problem"},{id:"define-the-asset",title:"What Exactly Needs to Be Preserved?"},{id:"reconstruction-work",title:"Why a Rebuild Takes More Than Coding"},{id:"recovery-path",title:"What Source Recovery Can and Cannot Provide"},{id:"cost-model",title:"Build a Comparable Budget Model"}
6947,{id:"evidence-and-scope",title:"Evidence Determines the Cost of Certainty"},{id:"testing-budget",title:"Reserve Time for Validation and Release"},{id:"choose-route",title:"A Route Selection Framework"},{id:"service-review",title:"Reviewing a Professional Recovery Option"},{id:"next-steps",title:"A Sensible Next Step for EA Owners"}],content:`
6948<p>Losing an MQ4 file while retaining a working EX4 puts an Expert Advisor owner in an awkward position. The robot may still attach to a chart and place trades, yet its rules are no longer accessible in the normal development environment. A simple parameter change, a broker symbol adjustment, or a request to move platforms can become a larger project. The immediate temptation is to hire a developer to recreate the robot. Another route is to assess whether the existing EX4 can support legitimate source recovery. Neither choice should be made from a headline price alone.</p>
6949
6950<p>This review-site guide examines that decision as a budgeting and project-control exercise. Its purpose is not to promise a particular recovery result or trading outcome. Instead, it shows why the apparent price of a rebuild often omits discovery, specification, testing, and handover work, and why a recovered starting point still needs review. For an owner who has the right to maintain the software, the best path depends on the evidence available, the condition of the running EA, the desired changes, and the value of preserving its current behavior.</p>
6951
6952<p>The central distinction is easy to miss. Rebuilding asks a new developer to infer and reimplement a system. Recovery begins with the compiled artifact that already embodies that system, then seeks readable material that can be inspected and maintained. Those are different engineering assignments. An <a href="/">ex4 to mq4 decompiler</a> may be relevant to the second assignment, but it does not replace ownership checks, code review, or proper testing. Likewise, a talented programmer cannot recreate undocumented rules simply by being given a screenshot of a chart.</p>
6953
6954<img src="${np}" alt="cost calculator for ea rebuild vs decompilation" style="width:100%;border-radius:8px;margin:24px 0;" />
6955
6956<h2 id="decision-frame">Treat the Missing Source as a Decision Problem</h2>
6957
6958<p>A missing source file is often described as a technical emergency. It is better understood as an asset-management problem with technical consequences. The owner needs to protect a functioning trading tool, establish authority to inspect or change it, and decide how much uncertainty is acceptable. The question is not merely, “What is the cheapest way to get code?” A stronger question is, “Which route gives a maintainable, testable result with the least avoidable uncertainty for this particular EA?”</p>
6959
6960<p>Begin by separating urgent operating needs from desired improvements. An EA that needs one symbol-name correction before a broker transition is not the same project as an EA that needs new entry logic, a dashboard, portfolio controls, and an MT5 edition. Recovery may be useful in the first case because retaining behavior matters. A redesign may be justified in the second because the owner has decided to change the product rather than preserve it. Combining both aims in one brief makes estimates unreliable.</p>
6961
6962<p>There is also a rights question before any technical route. The person holding an EX4 may be its author, may own assigned rights to a custom commission, or may only possess a licence to run a vendor product. Payment, access to a trading account, and possession of the file are not identical to permission to inspect, recover, alter, or distribute source. Owners should collect contracts, licence terms, delivery emails, invoices, repository records, and written permissions before discussing a job. This protects the owner and gives a prospective developer or provider a clearer brief.</p>
6963
6964<p>Time pressure can lead to a false comparison. A low initial quote looks attractive when the alternative is a longer engineering engagement. Yet a quote only has meaning when it names the deliverable. Does it include a written specification? Does it cover historical behavior, order-management edge cases, external indicators, error handling, source delivery, compilation, and a defined correction period? A source file that compiles is not automatically a faithful replacement for a live EA.</p>
6965
6966<h2 id="define-the-asset">What Exactly Needs to Be Preserved?</h2>
6967
6968<p>Before estimating either route, make an inventory of the asset. Start with the original EX4 and save an untouched copy in more than one secure location. Record the file name, apparent build date, terminal version, account context, input settings, attached indicators, DLL dependencies, presets, logs, and any related files. A checksum can help identify the exact binary under discussion. This information is valuable even if the final choice is a clean rebuild.</p>
6969
6970<p>Then describe observable behavior without assuming the internal implementation. Note which symbols and timeframes the EA uses, when it evaluates signals, how it sizes positions, whether it opens multiple orders, what conditions close orders, and how it responds to spread, trading hours, or existing manual positions. Screenshots of inputs are helpful, but they do not capture every rule. Statements, journals, old backtests, and messages between the original developer and owner can fill gaps. A well-organized evidence pack reduces paid detective work later.</p>
6971
6972<p>It helps to classify features into three groups. First, list behavior that must remain unchanged because it is part of the established process. Second, list behavior that is believed to exist but requires verification. Third, list new features that have never existed. A recovery-oriented project concentrates on the first two groups. A rebuild can include all three, but new features should be priced separately. This classification prevents a maintenance budget from silently becoming a product-development budget.</p>
6973
6974<p>Owners should also identify what success means. It could mean compiling in the current MetaEditor, explaining an existing rule, repairing a known fault, or creating a documented basis for a later platform migration. It should not mean a promise that historical profit will repeat. Markets, broker execution, data quality, settings, and account conditions can all affect results. A useful technical comparison focuses on functional behavior and controlled tests, not unsupported expectations about future performance.</p>
6975
6976<img src="${h0}" alt="large invoice for ea rebuild from scratch" style="width:100%;border-radius:8px;margin:24px 0;" />
6977
6978<h2 id="reconstruction-work">Why a Rebuild Takes More Than Coding</h2>
6979
6980<p>From the outside, an Expert Advisor can appear simple: it buys after one event and sells after another. The actual program may contain years of small decisions that are invisible on a chart. It can calculate indicator values differently from a standard example, use bar timing that avoids duplicate entries, normalize volume for a particular broker, recover after requotes, track tickets across restarts, or apply a sequence of protective checks. Rebuilding means discovering which of those details matter and writing them again.</p>
6981
6982<p>The work normally begins with discovery. A developer reviews the available evidence, interviews the owner, observes the EX4 in a safe environment, and turns fragments of knowledge into a specification. This phase is necessary because ambiguous instructions produce plausible but different implementations. “Close when the trend changes” needs a precise definition of trend, evaluation timing, treatment of an open bar, and the order in which conditions are checked. Each unresolved detail adds either cost now or correction work later.</p>
6983
6984<p>Implementation follows discovery, but it is not a single task. The developer may 
6984need modules for indicator acquisition, signal evaluation, position sizing, order submission, modification, error handling, session restrictions, logging, and input validation. If the EA uses a custom indicator that is also missing, that item may become a second reconstruction project. If it calls a DLL or reads files, compatibility and security review require separate attention. A responsible estimate identifies these dependencies rather than assuming that one EX4 tells the whole story.</p>
6985
6986<p>After coding comes comparison. The new EA must be compiled, exercised in the Strategy Tester where appropriate, and observed on a demo or controlled environment. Differences need investigation. Some will be expected because the original binary, terminal build, historical data, and broker conditions are not identical. Others reveal an incomplete specification. This is why a fixed quote based solely on “number of indicators” can be misleading. The real cost is driven by uncertainty and the number of behaviors that need to be reproduced with confidence.</p>
6987
6988<p>Handover has value too. A rebuild should provide readable source, build instructions, input documentation, known limitations, a change record, and clarity about third-party components. Without these materials, the owner may pay again when the next developer takes over. The lesson is not that rebuilding is always a bad choice. It is the right choice when the existing program is unsuitable, the desired logic is genuinely new, or no legitimate recovery route is available. It simply deserves a full project budget rather than a one-line coding assumption.</p>
6989
6990<h2 id="recovery-path">What Source Recovery Can and Cannot Provide</h2>
6991
6992<p>Source recovery has a narrower starting objective: obtain readable MQL4 material from a compiled EX4 where the requester is entitled to pursue that work. It can be attractive when the existing robot is valuable chiefly because its current behavior needs preservation. Rather than asking a developer to infer every branch from observation, the project begins with the file that contains the compiled logic. That can reduce discovery effort, but it does not eliminate engineering responsibility.</p>
6993
6994<p>Recovered output should be treated as a starting artifact, not a certificate of perfect source history. Variable names, comments, original formatting, library structure, and some developer intent may not be present in a compiled file. Depending on the file and toolchain, output can require cleanup before it compiles cleanly or becomes easy to maintain. A qualified reviewer still needs to read the result, identify external dependencies, compare behavior, and document changes. The proper comparison is therefore recovery plus validation versus discovery plus reconstruction plus validation.</p>
6995
6996<p>There are situations in which recovery has limited value. A badly outdated strategy may need a new design rather than preservation. A project whose legal entitlement is unclear should pause rather than seek technical workarounds. A protected dependency can remain unavailable, and a binary alone may not contain separate configuration files, external services, proprietary data, or operational knowledge. Recovery cannot manufacture missing business rules that were never encoded in the EX4.</p>
6997
6998<p>For readers evaluating technical routes, the site’s <a href="/blog/forex-ea-troubleshooting-why-automated-trading-robots-fail">guide to diagnosing an EA that stopped working</a> is useful context. It distinguishes problems caused by settings, broker changes, terminal updates, and strategy assumptions from a genuine source-code need. That distinction may save money. If the root cause is an expired licence or a changed symbol suffix, commissioning a full rebuild before diagnosing the issue is premature.</p>
6999
7000<img src="${u0}" alt="time versus money tradeoff for ea rebuild" style="width:100%;border-radius:8px;margin:24px 0;" />
7001
7002<h2 id="cost-model">Build a Comparable Budget Model</h2>
7003
7004<p>A meaningful budget compares work packages, not marketing labels. For a rebuild, include discovery, specification, development, indicator or dependency work, test preparation, comparison, revisions, documentation, and handover. For recovery, include eligibility review, file assessment, recovery work, code cleanup, compilation, behavior checks, documentation, and any modification requested afterward. Neither route should be evaluated by its first invoice alone.</p>
7005
7006<p>Developer pricing varies by experience, geography, language fluency, availability, complexity tolerance, and the commercial terms of the engagement. An owner should be cautious with generic online claims that every EA takes a fixed number of hours or has a universal price. A simple rule-based utility can be modest in scope. A multi-symbol system with order-state management, custom indicators, or legacy dependencies may require substantially more analysis. Requesting assumptions in writing is more useful than seeking a supposedly typical total.</p>
7007
7008<p>
7008Use a two-column worksheet. In the rebuild column, write each task and the estimate range supplied for it. In the recovery column, write the corresponding recovery and validation tasks. Add a contingency line for unanswered questions, and separate optional enhancements from required preservation. Include the cost of owner time: collecting evidence, answering questions, reviewing test cases, and accepting handover. The resulting model will not predict every outcome, but it exposes whether one route is being compared fairly with a partial version of the other.</p>
7009
7010<p>Schedule has a financial effect as well. A prolonged rebuild can delay a needed maintenance change, but rushing a recovered output into a live account can create its own operational risk. Estimate calendar time for feedback and testing, not just billable hours. An owner with a broker deadline may choose a limited repair now and a broader redesign later. That is a planning decision, not proof that one technical method is inherently superior.</p>
7011
7012<p>Finally, account for future maintenance. Clear source, a repository, build notes, and a documented test set can reduce the cost of the next change under either route. The first project is an opportunity to stop repeating the original loss. Once the code is available legitimately, store source and presets securely, retain release tags, and ensure that the ownership and handover terms are explicit.</p>
7013
7014<img src="${p0}" alt="budget comparison rebuild vs decompilation costs" style="width:100%;border-radius:8px;margin:24px 0;" />
7015
7016<h2 id="evidence-and-scope">
7016Evidence Determines the Cost of Certainty</h2>
7017
7018<p>Good evidence reduces estimation risk. The most valuable material is often not technical. A signed development agreement can clarify who may request maintenance. An old specification can explain why a safety rule exists. A saved set file can distinguish intended parameters from experiments. Historical journals can reveal timing. A repository archive can turn a recovery project into a smaller repair. Each item narrows the gap between what the owner remembers and what the program actually does.</p>
7019
7020<p>Scope control is the companion to evidence. Write a brief that states the original file, permitted purpose, required deliverables, dependencies, test environment, acceptance criteria, and exclusions. For example, an acceptance criterion might be that the output compiles on a named terminal build, exposes documented inputs, and completes selected historical test scenarios without known runtime errors. It should not be phrased as a guaranteed return, drawdown, or win rate. Technical acceptance can be verified; market outcomes cannot be promised.</p>
7021
7022<p>A change log is especially important when the original behavior appears questionable. Perhaps the owner wants to preserve entry logic but replace an unsafe volume rule. That is no longer strict reconstruction, which is perfectly reasonable if disclosed. Label the change, explain its reason, and test it separately. Future maintainers need to know which behavior came from the original artifact and which behavior was introduced during the project.</p>
7023
7024<p>When comparing providers, ask how they handle files, what information they need, what output is expected, and how they define the boundary of the job. Vague assurances are less helpful than a clear process. Confidential handling, limited access, and a rights-based intake are sensible considerations where a trading system may contain commercially sensitive ideas. No provider can decide ownership solely from a customer assertion, but a serious process should not encourage cloning, licence bypass, or redistribution.</p>
7025
7026<h2 id="testing-budget">Reserve Time for Validation and Release</h2>
7027
7028<p>Testing is the line item owners most often underestimate. Both reconstructed and recovered code need a controlled release path. First compile the code and address warnings that indicate a genuine issue. Then use repeatable historical scenarios that reflect the symbols, spreads, timeframes, and settings relevant to the EA. Compare event timing, order count, lot calculations, stop and target handling, and behavior after restarts. A visual chart comparison alone is not enough for a system that manages orders over time.</p>
7029
7030<p>Next, test edge conditions. What happens when trading is disabled, a symbol name differs, volume limits change, an order is rejected, an indicator lacks data, or the terminal restarts? Does the EA recognize orders it previously opened? Does it avoid duplicate action on a tick? These checks often expose the small operational rules that make a program usable. They also protect against treating an apparently successful compilation as a completed engineering project.</p>
7031
7032<p>A staged approach is prudent: offline review, historical tests, demo observation, then any live use only after the owner has made an independent risk decision. Configuration should be versioned at every stage. The site’s <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">testing guide for decompiled MQL4</a> provides a more detailed checklist for the validation phase. It is relevant after recovery, but many of the same disciplines apply to a clean rebuild.</p>
7033
7034<p>Budget for fixes discovered during validation. A transparent arrangement identifies whether the estimate includes a defined period for correcting deviations from the agreed specification, or whether every revision is separate work. This question is fair to both owner and developer. It also creates a reason to make acceptance criteria concrete before coding starts rather than arguing about intent after delivery.</p>
7035
7036<img src="${m0}" alt="savings from choosing decompilation over rebuild" style="width:100%;border-radius:8px;margin:24px 0;" />
7037
7038<h2 id="choose-route">A Route Selection Framework</h2>
7039
7040<p>Recovery is generally worth assessing first when the requester can document a right to maintain the EA, the existing EX4 still represents desired behavior, and the near-term objective is preservation, diagnosis, or a focused modification. It may reduce the amount of behavior a new developer must infer. The owner should still allow for cleanup and validation, and should keep expectations grounded in the condition of the file and the surrounding dependencies.</p>
7041
7042<p>A rebuild is often the more suitable route when the strategy needs fundamental redesign, the original EA has accumulated flaws that the owner does not want preserved, or the available artifact does not provide a workable technical starting point. It can also be the only responsible choice if recovery is not authorised. The owner should then invest early in a precise specification and choose a developer based on relevant MQL4 experience, communication, documentation practices, and a willingness to define tests.</p>
7043
7044<p>Sometimes the best answer is sequential. An owner can preserve and understand the current system first, document it, then commission a cleaner version with selected changes. This avoids forcing a new developer to guess the legacy behavior while allowing the eventual product to improve. The sequence is not automatically cheaper, but it may produce better decision information before a larger redesign is approved.</p>
7045
7046<p>A practical decision meeting can use five questions: Is authority to work on the code documented? Is preserving current behavior more important than changing it? Are the EX4, presets, and dependencies available? Is there enough evidence to verify a result? What budget is reserved for validation and future maintenance? Honest answers will usually point more clearly to recovery, rebuilding, or a staged plan than a generic price comparison can.</p>
7047
7048<img src="${f0}" alt="ROI graph showing decompilation return on investment" style="width:100%;border-radius:8px;margin:24px 0;" />
7049
7050<h2 id="service-review">Reviewing a Professional Recovery Option</h2>
7051
7052<p>For owners with a documented legitimate purpose, ForexMQ5 is positioned as a specialist professional option for EX4-to-MQ4 recovery, with pricing stated from $50 per file. From a review-site perspective, the attraction is a defined alternative to unknown downloads or an unscoped freelance recreation request. The service should be considered for its fit with the owner’s file, rights, and maintenance goal, not as a guarantee that every binary will yield identical historical source or future trading results.</p>
7053
7054<p>ForexMQ5 should not be treated as a route around licence restrictions or another party’s intellectual property. A responsible customer first confirms authority to request the work and keeps the resulting materials private unless their rights allow a wider use. The owner also remains responsible for reviewing output, protecting confidential files, and validating any code before deployment. Those limits are signs of a practical process, not obstacles to be ignored.</p>
7055
7056<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
7057  <h3 style="margin-top:0;">Assess the Recovery Route Before Rebuilding</h3>
7058  <p>ForexMQ5 is reviewed as a professional option for owners who can document a legitimate recovery or maintenance purpose and want to evaluate an existing EX4 before commissioning a full reconstruction.</p>
7059  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
7060</div>
7061
7062<h2 id="next-steps">A Sensible Next Step for EA Owners</h2>
7063
7064<p>Do not begin by sending the only copy of an EX4 to several people or by commissioning a rebuild from memory. Preserve the file, collect the documents that establish authority, capture the current settings and behavior, and define the maintenance outcome that matters. Then request comparable scopes. A capable professional should be able to explain what is included, what evidence is needed, and what remains uncertain.</p>
7065
7066<p>For a legitimately owned system that needs its established behavior understood or maintained, <a href="/">decompile ex4 to mq4</a> is a reasonable route to evaluate alongside reconstruction. For a product that needs a new strategy, new architecture, or a major platform change, a documented rebuild may create more value. In both cases, source control, handover records, test cases, and cautious deployment are part of the real budget.</p>
7067
7068<p>The useful result is not simply a lower invoice. It is an EA that the rightful owner can understand, maintain, test, and hand to the next qualified developer without repeating the same loss. By pricing uncertainty, validation, and documentation alongside code production, owners can choose a route that fits the actual condition of their software rather than an oversimplified promise.</p>
7069`},{slug:"beginner-roadmap-ex4-to-mq4-source-recovery",title:"A Beginner's Roadmap to EX4 to MQ4 Source Recovery",metaTitle:"Beginner Roadmap for EX4 to MQ4 Source Recovery | 2026",metaDescription:"A clear beginner roadmap to EX4 to MQ4 source recovery. Learn what compiled MT4 files contain, how to choose a recovery path, and how to check recovered code safely.",keywords:"beginner EX4 to MQ4 source recovery, EX4 decompilation roadmap, recover MQ4 source code, MT4 EA source recovery, beginner MQL4 decompilation guide",excerpt:"An EX4 file is useful while it runs, but difficult to maintain when the MQ4 source is missing. This beginner roadmap explains the recovery process, realistic expectations, rights checks, and practical next steps.",date:"January 19, 2026",dateISO:"2026-01-19",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:op,imageAlt:"beginner roadmap for EX4 to MQ4 source recovery",tableOfContents:[{id:"starting-with-the-file",title:"Start With the File You Have"},{id:"translation-not-time-machine",title:"Recovery Is Translation, Not a Time Machine"},{id:"rights-before-analysis",title:"Check Rights Before Analysis"},{id:"map-the-real-problem",title:"Map the Problem Before Choosing a Method"},{id:"recovery-options",title:"Three Recovery Routes for Beginners"},{id:"prepare-a-clean-request",title:"Prepare a Clean Recovery Request"},{id:"reading-the-result",title:"How to Read the Returned MQ4 File"},{id:"verify-without-rushing",title:"Verify It Without Rushing to Live Trading"},{id:"questions-and-next-actions",title:"Questions and Next Actions"}],content:`
7070<p>A compiled Expert Advisor can feel like a locked piece of personal history. It may still open and close trades in MetaTrader 4, while the editable file that explains every decision has disappeared. For a beginner, terms such as EX4, MQ4, compiler, decompiler, and bytecode can make a simple maintenance problem appear much harder than 
7070it is. The useful starting point is simple: an EX4 is the runnable version of an MT4 program, and an MQ4 is the editable version a developer can inspect and change.</p>
7071
7072<p>This review guide is for people who have a legitimate reason to understand or recover a file and need a sensible route through the subject. It does not assume programming experience. It also does not treat recovery as a shortcut around a vendor's rights. ForexMQ5 is considered here from an independent review-site perspective as one professional option for authorized recovery needs. The aim is to help a reader ask better questions, preserve the right evidence, and avoid placing untested code on a live account.</p>
7073
7074<img src="${op}" alt="beginner holding guide book about EX4 source recovery" style="width:100%;border-radius:8px;margin:24px 0;" />
7075
7076<h2 id="starting-with-the-file">Start With the File You Have</h2>
7077
7078<p>Before discussing recovery, identify the object in front of you. An EX4 file normally belongs to MetaTrader 4. It can be an Expert Advisor that automates trading, a custom indicator that draws signals, or a script that performs a one-time task. MT4 can run the file because its internal environment understands the compiled instructions. A person opening the same file in a text editor will see unreadable symbols instead of the trading rules.</p>
7079
7080<p>An MQ4 file is different. It is MQL4 source code, written as text for MetaEditor and people to read. It contains program statements, inputs, calculations, and functions. MetaEditor compiles that source into EX4 so MT4 can execute it efficiently. Keeping both files matters. The EX4 is what gets installed; the MQ4 is what makes repair, auditing, migration planning, and future changes possible.</p>
7081
7082<p>A quick inventory avoids common mistakes. Copy the EX4 to a separate working folder. Note its name, file size, approximate date, and where it was obtained. Check whether there are related files such as DLLs, include files, set files, or a separate indicator. Save any old emails, invoice, licence, and screenshots of settings. This record can identify the exact program later and helps distinguish a recovery project from a guess based on a similarly named file.</p>
7083
7084<p>Within MT4, File then Open Data Folder reveals the working installation. Files commonly appear under MQL4/Experts, MQL4/Indicators, or MQL4/Scripts. An EA can also depend on settings stored elsewhere, so finding an EX4 is not the same as collecting its whole operating environment. Do not edit the only copy in place. A working robot should remain available while investigation happens elsewhere.</p>
7085
7086<p>Readers who need a fuller explanation of the format can visit <a href="/blog/ex4-files-explained-for-mt4-users">this guide to what an EX4 file contains</a>. That background is particularly useful when a file is mislabeled, an MT5 file is confused with an MT4 file, or a folder contains both old and current versions.</p>
7087
7088<img src="${_s}" alt="simple map from EX4 file to readable MQ4 source" style="width:100%;border-radius:8px;margin:24px 0;" />
7089
7090<h2 id="translation-not-time-machine">Recovery Is Translation, Not a Time Machine</h2>
7091
7092<p>The easiest analogy is a finished building and its original blueprints. From the building, an experienced observer can identify rooms, doors, wiring routes, and major design choices. The original margin notes, early sketches, and the architect's naming conventions may be gone. EX4 recovery works in a similar way. It analyzes compiled instructions and produces a human-readable representation of the logic, but it cannot recreate every item that compilation removed.</p>
7093
7094<p>What commonly survives includes input parameters, arithmetic, indicator calls, order handling, conditions, loops, and much of the decision flow. These are the parts that must continue to work for the program to run. What may not survive cleanly includes comments, formatting, descriptive local variable names, and the precise organization chosen by the original author. Compiler optimizations can also mean that equivalent recovered code looks unfamiliar even when its behavior is close.</p>
7095
7096<p>That distinction changes the goal. A beginner should not judge a result by whether it looks like a photographed copy of the former MQ4. The more useful questions are whether it opens in MetaEditor, compiles after appropriate review, exposes the intended inputs, and behaves consistently in controlled testing. Readability matters because it makes later maintenance easier, but identical spelling and whitespace do not prove quality.</p>
7097
7098<p>Recovery also has technical limits. MT4 build generation, file protections, external libraries, and unusual coding patterns affect what can be reconstructed. A provider cannot responsibly promise that every EX4 will yield a perfect original source file. Any description that implies a universal, effortless reversal should make a reader cautious. A well-scoped assessment of the individual file is more useful than a broad promise.</p>
7099
7100<h2 id="rights-before-analysis">Check Rights Before Analysis</h2>
7101
7102<p>Technical possibility and permission are separate questions. Owning a copy of an EA does not automatically mean owning the source code. A person may have purchased a licence to run a robot on a specified account while the developer retained all rights to inspect, modify, or distribute its source. Conversely, a developer who wrote an EA and lost local backups may have a strong reason to recover their own work. The documents and purpose make the difference.</p>
7103
7104<p>A beginner can start with four plain questions. Who created the program? What did the development agreement or marketplace licence say? Why is source access needed now? What will happen to the recovered material after review? Save factual answers, not assumptions. A statement such as “source is needed to maintain an EA commissioned under a written handover agreement” is much clearer than “I paid for it.”</p>
7105
7106<p>Red flags deserve an early stop. Requests to copy a competitor's strategy, remove account restrictions, defeat an expiry control, or publish a vendor's code are not routine maintenance. A commercial licence may expressly prohibit decompilation, and laws differ between jurisdictions. For disputes, valuable systems, unclear ownership, or any plan to redistribute output, qualified local legal advice is the appropriate next step.</p>
7107
7108<p>The detailed <a href="/blog/legal-rules-for-ex4-source-code-recovery">legal guide for EX4 source recovery</a> explains why contracts, copyright, jurisdiction, and downstream use all matter. This article stays focused on practical orientation rather than presenting legal conclusions.<
7108/p>
7109
7110<img src="${g0}" alt="learning journey for responsible EX4 analysis" style="width:100%;border-radius:8px;margin:24px 0;" />
7111
7112<h2 id="map-the-real-problem">Map the Problem Before Choosing a Method</h2>
7113
7114<p>“I need the source” often covers several different problems. Separating them prevents wasted time and gives a technical reviewer useful context. A lost-source problem means the requester once had the MQ4 and needs a maintainable replacement. An audit problem means the EA is licensed but its behavior needs careful inspection within the permissions available. A repair problem may involve a robot that stopped working after a broker, symbol, or platform change. A migration problem may require understanding old logic before rebuilding it for a new environment.</p>
7115
7116<p>Write a one-page project note with the file name, purpose, known history, expected behavior, and constraints. Include whether it runs today, whether a previous source copy exists, and whether third-party components are involved. If the robot only trades EURUSD during a certain session, record that. If it uses a custom indicator, preserve that too. These observations later become test cases rather than vague memories.</p>
7117
7118<p>It helps to set a minimum useful outcome. For some owners, the immediate need is to view input settings and order rules. For others, it is a compiling MQ4 starting point for a developer. For an audit, a readable explanation of sensitive functions may be more relevant than a cosmetic cleanup of every variable. Defining the outcome protects a beginner from paying attention to details that do not solve the actual business or trading problem.</p>
7119
7120<p>No route should begin with a live account. A recovered source file is software that needs review. Even an unchanged-looking strategy can react differently when compiled under a newer MT4 installation, connected to another broker, or run with different symbol digits. The original EX4 should remain preserved as a comparison point, not replaced on day one.</p>
7121
7122<h2 id="recovery-options">Three Recovery Routes for Beginners</h2>
7123
7124<h3>1. Search for the original source and authorized support first</h3>
7125
7126<p>Before reverse analysis, search old computers, backups, cloud drives, source repositories, email attachments, and developer handover folders. Ask the original author or vendor whether an authorized source copy, update, or support path exists. This can be the cleanest route because it preserves comments, names, and context that compiled code cannot restore. It also avoids uncertainty about licence terms. A good search may take an afternoon and save a much larger technical project.</p>
7127
7128<h3>2. Use a free utility only as a limited experiment</h3>
7129
7130<p>Older utilities are sometimes discussed in forums as a free answer. They can be educational on files from older MT4 generations, especially where no valuable decision depends on the result. Their weakness is that old tools may not understand later build formats and may emit partial or confusing output. Unknown downloads also carry obvious safety concerns. A beginner should not upload a valuable EA to a random website or treat a generated file as ready for trading merely because it has an MQ4 extension.</p>
7131
7132<h3>3. Consider professional recovery for an authorized, important file</h3>
7133
7134<p>For a file with documented rights and real maintenance value, a professional route removes the need to learn binary analysis before getting an assessment. ForexMQ5 is reviewed as a specialist option in this category. Its stated service begins from $50 per file, but file complexity and recoverability should be clarified before a reader relies on any outcome. The review-site position is not that a paid route creates permission or guarantees a result. Its advantage is a defined process for a legitimate request and a more practical route than experimenting with unverified utilities.</p>
7135
7136<p>There is a fourth path for specialists: manual reverse engineering with tools such as x64dbg and ScyllaHide. It belongs in the technical landscape, but it is not a beginner checklist. It demands experience with debugging, executable behavior, and careful documentation. Manual analysis can consume substantial time and still requires the same rights and testing discipline. Calling it a do-it-yourself option does not make it a sensible first project for someone who only needs an old EA maintained.</p>
7137
7138<p>For a broad comparison of methods and output expectations, the main review page discusses <a href="/">EX4 to MQ4 decompiler</a> choices in more detail. The best selection is based on file age, purpose, rights, budget, and the consequence of an incomplete result, not on a claim that one route fits every file.</p>
7139
7140<img src="${v0}" alt="mentor explaining choices for EX4 source recovery" style="width:100%;border-radius:8px;margin:24px 0;" />
7141
7142<h2 id="prepare-a-clean-request">Prepare a Clean Recovery Request</h2>
7143
7144<p>A tidy request makes it easier to receive a relevant answer. Start with an untouched copy of the specific EX4. Do not rename a collection of unrelated files and assume they are one system. Identify the file type, its approximate compilation period if known, whether it is currently operating, and any dependencies. State the authorized purpose in ordinary language and retain the records supp
7144orting it.</p>
7145
7146<p>A responsible intake should also be able to identify requests that cannot be supported. Accuracy is helped by sharing useful context, but there is no reason to include account passwords, brokerage credentials, payment data, or unrelated private documents. An EX4 file, concise description, and non-sensitive behavior notes are usually a better beginning than a folder dump.</p>
7147
7148<p>Before agreeing to work, a reader can ask practical questions: What is delivered if the file is recoverable? Is the output expected to compile immediately or to require cleanup? How are protected or unsupported files handled? What information should remain private? Is a revised attempt available when an obvious compilation issue is found? Specific answers are more meaningful than general marketing language.</p>
7149
7150<p>ForexMQ5 should be evaluated by the same standard as any provider. The service is positioned for authorized EX4 to MQ4 recovery, while the customer remains responsible for entitlement and for validation after delivery. An explicit, outbound CTA is appropriate only after a reader has finished this preparation.</p>
7151
7152<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
7153  <h3 style="margin-top:0;">Need an Authorized EX4 Recovery Assessment?</h3>
7154  <p>ForexMQ5 is reviewed as a professional option for owners and authorized users who have preserved the relevant file, records, and maintenance purpose.</p>
7155  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
7156</div>
7157
7158<img src="${y0}" alt="careful first attempt at reviewing recovered MQL4 code" style="width:100%;border-radius:8px;margin:24px 0;" />
7159
7160<h2 id="reading-the-result">How to Read the Returned MQ4 File</h2>
7161
7162<p>Opening recovered code can be intimidating, especially when names such as a12 or l_44 appear instead of friendly labels. Begin with the parts that answer practical questions. Input declarations show values a user can configure from the EA properties window. Initialization functions reveal what the program prepares when attached to a chart. Tick handling functions often contain the repeating logic that decides whether to inspect prices, manage orders, or wait.</p>
7163
7164<p>Search for familiar MQL4 concepts rather than trying to understand every line in order. OrderSend, OrderClose, OrderModify, iMA, iRSI, and similar calls point to trading actions or indicators. A magic number can identify trades associated with a particular EA. Stop loss and take profit values may be represented through calculations rather than a single obvious label. The code may be readable enough to map behavior without being easy enough to modify safely.</p>
7165
7166<p>Create a plain-language annotation beside the file. For example: “this block checks open positions,” “this input controls lot sizing,” or “this condition prevents entries outside a time window.” These notes turn a recovered artifact into maintainable project material. They also expose unanswered questions that can be directed to a qualified MQL4 developer rather than resolved through a risky edit.</p>
7167
7168<p>Do not assume that a mysterious name indicates malicious behavior. Decompilation may replace names because the original names were not preserved. Conversely, readable code is not proof that a strategy is suitable for live funds. Source recovery makes inspection possible; it does not independently validate trading logic, risk, or historical claims.</p>
7169
7170<img src="${b0}" alt="beginner confidently reviewing recovered MQ4 source code" style="width:100%;border-radius:8px;margin:24px 0;" />
7171
7172<h2 id="verify-without-rushing">Verify It Without Rushing to Live Trading</h2>
7173
7174<p>Verification starts by opening a copy of the MQ4 in MetaEditor and recording compilation messages. Warnings and errors are different. An error prevents a usable build; a warning may still merit review because it can reveal an outdated convention or data conversion issue. Keep the original recovered file unchanged and make repairs in a separately named working copy. That simple habit makes later comparison much easier.</p>
7175
7176<p>Next, compare structure and settings with the original EX4. Attach each version only in a controlled environment where appropriate. Are the same inputs visible? Does the recovered version recognize the expected symbol and timeframe? Does it create trades with the same magic number behavior? Does it call the expected indicator? These checks focus on observable behavior without requiring a beginner to prove every internal instruction at once.</p>
7177
7178<p>Strategy Tester can provide a first controlled check, but it has limits. Use matching historical data, symbol conditions, spread assumptions, and settings where possible. Compare orders, entry timing, exits, and position sizing rather than relying on a single profit figure. A changed data feed or broker rule can alter results even if the source is sound. Backtesting helps find differences; it is not a guarantee of future market performance.</p>
7179
7180<p>After a clean compilation and reasonable controlled comparison, demo observation adds another layer. Monitor logs, order comments, error messages, and unexpected frequency of actions. If a developer modifies recovered logic, repeat the checks after every meaningful change. A cautious sequence is preserve, compile, compare, test, observe, then decide. It is far safer than treating recovery as an immediate deployment button.</p>
7181
7182<p>The homepage has a practical overview of when to <a href="/">decompile EX4 to MQL4</a> and how professional recovery fits beside independent testing. Readers who need a deeper code-reading walkthrough can also use the linked MQL4 guide above before changing parameters or conditions.</p>
7183
7184<h2 id="questions-and-next-actions">Questions and Next Actions</h2>
7185
7186<h3>Can a beginner recover an EX4 without becoming a programmer?</h3>
7187<p>Yes, a beginner can organize the file, clarify the authorized purpose, choose an appropriate route, and perform basic checks without personally conducting binary research. Understanding the result well enough to change trading logic is a separate skill. For modifications, an experienced MQL4 developer may be the safer resource.</p>
7188
7189<h3>Will recovery provide exactly the old MQ4 file?</h3>
7190<p>Not necessarily. Compilation generally removes comments and can obscure names and formatting. The useful standard is a credible, readable source representation that can be assessed and tested, not a claim of a letter-for-letter historical duplicate.</p>
7191
7192<h3>
7192Does a recovered source file prove an EA is safe or profitable?</h3>
7193<p>No. It can make review possible, which is valuable, but it does not prove security, suitability, or future returns. Trading software remains subject to configuration errors, market conditions, execution differences, and ordinary software defects.</p>
7194
7195<h3>What should be backed up once the project is complete?</h3>
7196<p>Keep the original EX4, recovered MQ4, working revisions, set files, dependency notes, test records, ownership documents, and a short readme for the next maintainer. Store copies in more than one controlled location. A version-control repository can make future changes traceable when it is appropriate for the confidentiality of the project.</p>
7197
7198<p>The beginner's route is therefore not about finding a magic converter. It is about turning an unclear file problem into a documented maintenance project. Identify the file, establish rights, choose a proportionate method, inspect the returned source, and validate behavior in stages. That approach gives an owner or authorized user a much stronger foundation for maintaining an MT4 tool without pretending that recovered code is automatically perfect or ready for live use.</p>
7199    `},{slug:"how-to-read-recovered-mql4-expert-advisor-code",title:"How to Read Recovered MQL4 Expert Advisor Code: A Practical Interpretation Guide",metaTitle:"How to Read Recovered MQL4 EA Code | Practical Guide",metaDescription:"Learn a methodical way to inspect recovered MQL4 Expert Advisor code, map inputs, trace trade logic, identify safeguards, and document findings before testing.",keywords:"read recovered MQL4 code, interpret decompiled EA source, MQL4 Expert Advisor code guide, audit recovered MQ4, understand EA trading logic",excerpt:"Recovered MQ4 code can look unfamiliar even when it compiles. This practical guide shows traders, owners, and developers how to map an Expert Advisor's inputs, signals, orders, safeguards, and dependencies without guessing.",date:"February 2, 2026",dateISO:"2026-02-02",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:Us,imageAlt:"developer reading and understanding recovered mql4 code",tableOfContents:[{id:"reading-goal",title:"Set a Clear Reading Goal"},{id:"safe-copy",title:"Prepare a Safe Working Copy"},{id:"map-the-file",title:"Map the EA Before Reading Details"},{id:"follow-inputs",title:"Follow Inputs Into Decisions"},{id:"trace-signals",title:"Trace the Signal and Filter Path"},{id:"inspect-orders",title:"Inspect Entries, Exits, and Position Rules"},{id:"find-guardrails",title:"Find Guardrails and Hidden Dependencies"},{id:"rename-notes",title:"Use a Rename and Notes Workflow"},{id:"confirm-behavior",title:"Confirm Understanding Through Controlled Tests"},{id:"service-context",title:"Where Professional Recovery Fits"},{id:"final-checklist",title:"A Reader's Final Checklist"}],content:`
7200<p>Receiving an MQ4 file after source recovery is not the end of the investigation. It is the point at which an owner, trader, or developer can begin asking useful questions. What causes the Expert Advisor to consider a trade? Which chart and timeframe assumptions does it make? Does it close positions according to a fixed rule, trail a stop, or leave management to another routine? Does it depend on a particular symbol spelling, account setting, indicator, file, or external library?</p>
7201
7202<p>Those questions can be answered without treating every recovered file as a mystery. MQL4 is structured, and an Expert Advisor normally leaves a trail from its settings to its calculations and finally to its trade requests. Recovery may not restore comments, original formatting, or meaningful local names. It can also produce code that needs cleanup before compilation. Still, a patient reader can create a reliable behavioral map without pretending that every line has been understood on the first pass.</p>
7203
7204<p>This review-site guide is intended for people examining code they are entitled to inspect, such as their own lost project or an authorised maintenance copy. It is not a shortcut for copying another developer's strategy or removing licence controls. The practical aim is narrower: turn a recovered file into a documented, testable maintenance asset. Readers needing context on the compiled file itself can first read <a href="/blog/ex4-files-explained-for-mt4-users">what an EX4 file contains</a>.</p>
7205
7206<img src="${Us}
7206" alt="person reviewing a recovered MQL4 Expert Advisor file" style="width:100%;border-radius:8px;margin:24px 0;" />
7207
7208<h2 id="reading-goal">Set a Clear Reading Goal</h2>
7209
7210<p>Start by writing one sentence about why the code is being reviewed. A trader deciding whether an EA matches its documentation has a different task from a developer repairing a broker-symbol problem. An owner preparing a platform migration may only need to find dependencies and configurable values. A security review may focus on file operations, web requests, DLL imports, or unexpected order activity. A defined goal tells the reader which findings deserve the closest attention.</p>
7211
7212<p>Vague goals create unnecessary risk. “Understand everything” can lead to hours spent decoding harmless utility functions while a critical risk setting remains unexamined. A better scope could be: identify entry conditions, maximum simultaneous exposure, stop handling, and any external resources. Another could be: determine why the EA refuses to trade on a new broker. Each scope can be expanded later, but the initial pass should be small enough to complete and document.</p>
7213
7214<p>It also helps to separate three kinds of statements in the notes. A fact is directly visible in code, such as an input named <code>Lots</code> with a default value. An inference is a reasonable interpretation, such as a loop that appears to count open orders belonging to the EA. A test result is observed behavior in a controlled environment. Keeping these categories separate prevents an attractive explanation from becoming a false certainty.</p>
7215
7216<h2 id="safe-copy">Prepare a Safe Working Copy</h2>
7217
7218<p>Do not begin by editing the only recovered file. Preserve the delivered MQ4 and the original EX4 in a dated folder, then create a separate working copy. If possible, record a checksum for the original binary and retain the recovery correspondence, licence or ownership records, settings files, templates, and old platform logs. A simple folder structure makes later comparisons far easier: originals, recovered output, working copy, test reports, and notes.</p>
7219
7220<p>Open the working copy in MetaEditor and compile it before changing anything. Compilation establishes a baseline. Warnings and errors should be copied into the notes along with the MetaTrader build number. A recovered file that compiles is useful, but compilation only confirms syntax and known references. It does not prove that indicator buffers, order logic, risk calculations, or broker assumptions behave as intended.</p>
7221
7222<p>Next, search the file for operations that deserve immediate caution. Look for <code>OrderSend</code>, <code>OrderClose</code>, <code>OrderModify</code>, <code>OrderDelete</code>, <code>WebRequest</code>, file functions, DLL imports, global variables, and calls that alter chart objects. These are not proof of a problem. They are signposts to code that can place orders, alter existing orders, exchange data, or persist state. A reader should know where those signposts are before attaching the EA anywhere.</p>
7223
7224<img src="${sp}" alt="diagram showing the main sections of MQL4 code" style="width:100%;border-radius:8px;margin:24px 0;" />
7225
7226<h2 id="map-the-file">Map the EA Before Reading Details</h2>
7227
7228<p>The fastest way to become lost is to read top to bottom and interpret every expression immediately. Instead, make a one-page map of the file. Most MQL4 Expert Advisors contain recognisable zones even when names have been flattened during recovery: properties and inputs, global declarations, initialization, tick handling, helper functions, indicator calculations, order-management routines, and cleanup code.</p>
7229
7230<p>At the beginning, locate directives such as <code>#property</code>, external declarations, and inputs. Inputs describe the controls exposed in the EA properties window. Globals hold values that functions can share, including counters, timestamps, arrays, or cached indicator values. A function called <code>OnInit</code>, <code>init</code>, or a similar recovered equivalent commonly prepares state. A function called <code>OnTick</code> or <code>start</code> is often the route entered when a price tick arrives, although older MQL4 styles can look different.</p>
7231
7232<p>Then make a short function inventory. For each function, record 
7232its name, inputs, return type, approximate purpose, and callers. A function that returns <code>bool</code> and is invoked before an order request may be a filter. One that accepts a ticket number and calls <code>OrderModify</code> probably manages a position. A routine that receives a symbol and timeframe before calling an indicator could calculate a signal. This first inventory is more valuable than an early attempt to rename every variable.</p>
7233
7234<p>Code folding and search are useful here. Search for every occurrence of a function name, not just its definition. Draw arrows in a notebook or document from the tick routine to the functions it calls. The resulting map usually reveals a pipeline: check whether trading is allowed, inspect existing orders, calculate conditions, decide direction, submit an order, then manage open positions. The actual order can vary, but seeing the call chain gives meaning to the smaller pieces.</p>
7235
7236<h2 id="follow-inputs">Follow Inputs Into Decisions</h2>
7237
7238<p>Inputs are the best bridge between an unfamiliar file and the behavior seen in the platform. They are often preserved because MetaTrader must display them to the user. Typical examples include lot size, risk percentage, magic number, stop loss, take profit, trailing distance, trading hours, spread limit, indicator period, and timeframe. Copy every input into a table with its default, apparent unit, and the locations where it is used.</p>
7239
7240<p>Do not assume a familiar label has a familiar effect. An input named <code>StopLoss</code> may be expressed in points, pips, price distance, or a special value where zero means no initial stop. A setting called <code>Risk</code> may determine a percentage of balance, a fixed lot size multiplier, or merely enable a filter. Follow the variable from its declaration to the calculation and finally to the order request. The surrounding arithmetic tells the story.</p>
7241
7242<p>For example, a price distance multiplied by <code>Point</code> is likely being converted into a broker price increment. Code that divides by <code>MarketInfo(Symbol(), MODE_TICKVALUE)</code> may be calculating volume from monetary risk, but it should still be checked for contract-size assumptions. A value passed into an <code>iMA</code> call is likely an indicator period or shift. Record the evidence rather than relying on the input label alone.</p>
7243
7244<p>The magic number deserves special attention. It is commonly the identifier used to distinguish an EA's trades from manual orders and other robots. Search where it is compared to <code>OrderMagicNumber()</code>. If no comparison is present, the EA may be able to inspect or manage orders beyond its intended set. That finding does not establish harmful behavior by itself, but it is important operational information for anyone planning to run several systems on one account.</p>
7245
7246<img src="${lp}" alt="guide translating recovered variable names into trading concepts" style="width:100%;border-radius:8px;margin:24px 0;" />
7247
7248<h2 id="trace-signals">Trace the Signal and Filter Path</h2>
7249
7250<p>After inputs, trace the decision that permits a new trade. Begin at the tick handler or main routine and find each conditional block that can reach an order-opening call. Work backwards from <code>OrderSend</code> if the top-level routine is confusing. The arguments to an order request show whether the code is opening a buy or sell, the volume, price, stop, target, comment, and magic number. The lines immediately before it often contain the actual signal and filters.</p>
7251
7252<p>
7252Common signal sources include moving averages, RSI, MACD, stochastic values, Bollinger Bands, candle highs and lows, time comparisons, and values from a custom indicator. A crossover is often written as a comparison of current and previous bar values. A breakout may compare <code>Bid</code> or <code>Ask</code> with a range high or low. A mean-reversion rule may check whether price has moved beyond an indicator band. These patterns are clues, not a reason to stop reading, because a single additional condition can reverse their practical meaning.</p>
7253
7254<p>Filters often matter as much as the signal. Search for checks involving spread, day of week, hour, new bars, account balance, open order count, or recent trade time. A new-bar test can prevent repeated entries on every tick. A spread test can block entries when quoted costs are high. A time window may constrain trading to sessions selected by the author. A filter that is declared but never called is also worth noting, since its presence does not mean it affects execution.</p>
7255
7256<p>Custom indicators require extra care. The <code>iCustom</code> call may include a file name followed by parameters and a buffer index. That tells the reader an external indicator is part of the strategy, but not what that indicator calculates. Check that the file exists in the expected location and document its version. A recovered EA cannot be fully interpreted if a required custom indicator, include file, or DLL is missing.</p>
7257
7258<p>Readers comparing the major recovery routes can use the site's <a href="/">ex4 to mq4 decompiler</a> overview to understand why output quality and build support affect this analysis. The useful standard is not decorative formatting. It is whether the recovered code gives a reviewer a traceable path from inputs and data to decisions.</p>
7259
7260<h2 id="inspect-orders">Inspect Entries, Exits, and Position Rules</h2>
7261
7262<p>Trade logic has two halves: opening positions and managing them afterward. Map both. For every <code>OrderSend</code> call, note the order type, direction, requested volume, price source, slippage setting, stop loss, take profit, comment, and magic number. If price values are normalized with <code>NormalizeDouble</code>, note the digits used. If the code retries after an error, document the retry conditions and delay. Repeated sending without careful checks can have very different consequences from one guarded request.</p>
7263
7264<p>Next inspect loops that select orders using <code>OrderSelect</code>. Determine whether the loop is counting market orders, pending orders, or both. Determine whether it filters by symbol and magic number. Then find every call to <code>OrderClose</code>, <code>OrderModify</code>, and <code>OrderDelete</code>. These operations may implement targets, trailing stops, break-even changes, time exits, opposite-signal exits, pending-order expiry, or basket-level management.</p>
7265
7266<p>Volume progression is another key review point. A simple EA may send the same volume each time. Other files calculate volume from account values or increase it after a loss. Look for multiplication of the previous lot amount, order-history scans, or counters that reset after a profitable close. Describe the mechanism precisely and avoid assigning labels before the logic supports them. For example, doubling volume after specified losses is observable; calling the whole system profitable or unsafe is a broader conclusion that requires testing and context.</p>
7267
7268<p>Also check how the EA identifies a closed outcome. It may read order history, compare account equity, or rely on its own global counters. History-selection logic can be sensitive to account history settings and time ranges. A management routine that assumes all history is visible may behave differently between terminals. This is the kind of detail that turns a code reading into a useful deployment note.</p>
7269
7270<img src="${dp}" alt="annotated MQL4 code being reviewed for order management" style="width:100%;border-radius:8px;margin:24px 0;" />
7271
7272<h2 id="find-guardrails">Find Guardrails and Hidden Dependencies</h2>
7273
7274<p>
7274A sound review should look for controls as well as signals. Search for <code>IsTradeAllowed</code>, account-number comparisons, server-name checks, terminal permissions, maximum spread, daily loss limits, equity thresholds, and error handling. Some checks are reasonable operational safeguards. Others may mean the file expects a particular environment. The task is to identify and describe them, not to bypass them.</p>
7275
7276<p>Broker details can be embedded in subtle ways. Symbol strings may be compared directly, which can fail where a broker adds a suffix. Price calculations may assume a particular digit count. Time logic may rely on server time. The code may call <code>MarketInfo</code> for stop levels, tick value, or minimum lot size, which is generally more adaptable than fixed values but still deserves testing. Note every assumption that could change after moving the EA to a new broker or account.</p>
7277
7278<p>File and network activity should be catalogued carefully. A call to <code>FileOpen</code> can be a harmless log or a source of configuration. <code>WebRequest</code> may fetch data, report status, or rely on an approved URL setting. DLL imports need particular caution because their behavior is outside the MQ4 source. Record the file path, URL, imported function, and condition that triggers the call. Do not enable external permissions merely to see whether an unknown dependency works.</p>
7279
7280<p>When the review is part of a repair project, the guide to <a href="/blog/forex-ea-troubleshooting-why-automated-trading-robots-fail">why Expert Advisors stop working</a> can help distinguish an environment mismatch from a strategy defect. The source file is evidence, but terminal logs, symbol specifications, and controlled observations remain part of the diagnosis.</p>
7281
7282<h2 id="rename-notes">Use a Rename and Notes Workflow</h2>
7283
7284<p>Generic names do not make a file unreadable. They make disciplined notes essential. Resist a global rename as soon as a variable looks familiar. Instead, create a small dictionary with the original name, proposed meaning, evidence, confidence level, and locations used. For instance, a variable incremented when a new candle appears may be tentatively labelled “bar counter.” A value returned by <code>iRSI</code> can be labelled “current RSI” only after its parameter order and shift are checked.</p>
7285
7286<p>Rename one tightly bounded group at a time: inputs, order counters, indicator values, then helper-function parameters. Compile after each group. This prevents a mistaken broad replacement from obscuring the original trail. Keep names descriptive rather than judgmental. “previousLossCount” is better than “badTradeSignal” when the code simply counts losses. Comments should cite the line's effect and any uncertainty, such as “appears to gate entries once per bar, confirm in visual test.”</p>
7287
7288<p>A useful annotation sheet has five columns: location, visible behavior, inputs used, dependencies, and open question. This sheet becomes the handover document for a developer who did not perform the first reading. It also makes it clear which conclusions were confirmed and which are still hypotheses. For a recovered file, honest uncertainty is a strength.</p>
7289
7290<img src="${cp}" alt="reviewer solving the structure of a recovered code puzzle" style="width:100%;border-radius:8px;margin:24px 0;" />
7291
7292<h2 id="confirm-behavior">Confirm Understanding Through Controlled Tests</h2>
7293
7294<p>Code review should lead to a test plan, not directly to a live account. Use a copy of the EA in a controlled environment and preserve the input set, symbol, timeframe, model assumptions, and terminal build. First confirm simple observations: initialization succeeds, expected inputs appear, required files are found, and the EA does not produce unexplained permission or trade errors. Then test the specific paths identified in the notes.</p>
7295
7296<p>Visual testing is especially useful for signal timing. Add temporary logging in the working copy, or use existing logs, to record indicator values and gate decisions. A reader can then compare an apparent crossover, session filter, or spread block with the chart at the relevant time. Avoid changing multiple conditions at once. If a test does not match the reading, return to the call chain and identify what was overlooked.</p>
7297
7298<p>Test management separately from entry. A position may not close until a later tick, a new bar, a time condition, or an opposite signal. Pending orders, partial closes, trailing adjustments, and basket targets each need observations of their own. Results from historical testing and a demo environment are evidence about configured scenarios, not a promise of future market outcomes. The point is to verify implementation against the reader's documented interpretation.</p>
7299
7300<p>Before any real-money use, an owner should know the maximum order count the code permits, how it calculates volume, what happens during trading errors, which settings are essential, and what external dependencies are enabled. A clear answer to those questions is more useful than a polished file with unread annotations.</p>
7301
7302<h2 id="service-context">Where Professional Recovery Fits</h2>
7303
7304<p>Some recovered output is easier to inspect than others. Build differences, compiler transformations, missing symbols, and damaged source history can complicate the path from EX4 to readable MQ4. In reviews of available options, the service at ForexMQ5 is positioned as a professional recovery route for legitimate ownership, maintenance, and authorised audit cases, with stated pricing from $50 per file. The review site's assessment is that a readable starting point and a defined delivery process can be more practical than relying on unverified utilities.</p>
7305
7306<p>Professional recovery does not remove the need for code review, permission, or testing. It also does not make an unauthorised request appropriate. The recipient remains responsible for establishing their right to inspect the file and for validating any recovered source before use. For readers assessing the wider choice of methods, the homepage comparison of <a href="/">MQL4 decompiler</a> options explains the professional, free-tool, and hands-on routes.</p>
7307
7308<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
7309  <h3 style="margin-top:0;">Review a Legitimately Recovered EA With Better Context</h3>
7310  <p>ForexMQ5 is reviewed as a professional option for owners with a documented recovery or authorised maintenance need. A careful reading and controlled test plan should follow delivery.</p>
7311  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
7312</div>
7313
7314<img src="${hp}" alt="clear understanding of recovered MQL4 Expert Advisor logic" style="width:100%;border-radius:8px;margin:24px 0;" />
7315
7316<h2 id="final-checklist">A Reader's Final Checklist</h2>
7317
7318<p>Before calling a recovered EA understood, review the record rather than relying on memory. The following checklist is deliberately practical:</p>
7319
7320<ul>
7321<li>The original EX4 and the unedited recovered MQ4 have been preserved separately.</li>
7322<li>The working copy compiles, and all warnings or missing dependencies are recorded.</li>
7323<li>Every input has a documented default, unit, and known use in the logic.</li>
7324<li>The main tick path and all functions leading to trade requests have been mapped.</li>
7325<li>Entry signals, filters, volume rules, and order limits are described with evidence.</li>
7326<li>Exit, stop, target, pending-order, and trailing behavior have been traced.</li>
7327<li>Magic-number, symbol, broker, account, time, file, network, and DLL dependencies are known.</li>
7328<li>Variable renames are supported by notes and uncertain interpretations remain marked as such.</li>
7329<li>Controlled tests have checked the most important observed paths without treating historical results as a forecast.</li>
7330<li>The final notes explain what a future maintainer must preserve or verify before changing the EA.</li>
7331</ul>
7332
7333<p>The lasting value of recovered code is not merely that it can be opened in an editor. It is that a responsible owner can trace what the EA is designed to do, identify what it needs around it, and make measured maintenance decisions. A map, an annotation sheet, and a controlled test record turn an opaque file into something that can be reviewed again when the platform, broker, or strategy requirements change.</p>
7334`},{slug:"forex-ea-vendor-transparency-checklist",title:"Forex EA Vendor Transparency Checklist: How to Evaluate Claims Before Buying",metaTitle:"Forex EA Vendor Transparency Checklist | Buyer Due Diligence",metaDescription:"Use this practical Forex EA vendor transparency checklist to assess track records, testing claims, support, identity, licensing, and code-review options before committing capital.",keywords:"forex ea vendor transparency, forex ea vendor checklist, expert advisor due diligence, forex robot vendor red flags, evaluate forex ea claims",excerpt:"A polished sales page is not evidence that a Forex EA is suitable for an account. This review-site checklist helps buyers separate useful disclosure from vague claims, ask better questions, and test cautiously before purchasing or deploying a trading robot.",date:"February 16, 2026",dateISO:"2026-02-16",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:pp,imageAlt:"warning flags around suspicious forex ea vendor",tableOfContents:[{id:"why-transparency",title:"Why Transparency Is the First Buying Test"},{id:"evidence-map",title:"Build an Evidence Map Before Reading Claims"},{id:"results-review",title:"Review Results Without Treating Them as Proof"},{id:"strategy-disclosure",title:"Assess Strategy Disclosure and Risk Language"},{id:"identity-support",title:"Check Identity, Support, and Terms"},{id:"testing-claims",title:"Put Backtests and Demonstrations in Context"},{id:"code-boundaries",title:"Understand Code Review, Licences, and Boundaries"},{id:"research-workflow",title:"A Practical Research Workflow"},{id:"trial-deployment",title:"How to Test a Candidate EA Cautiously"},{id:"review-perspective",title:"Where Professional Analysis Fits"},{id:"decision",title:"Make a Decision You Can Explain"}],content:`
7335<p>Buying a Forex Expert Advisor is partly a software purchase and partly a risk-management decision. The product may arrive as a small EX4 file and a confident sales page, yet the buyer is being asked to place that program inside a trading terminal that can open, modify, and close positions. That gap between presentation and access is why vendor transparency de
7335serves attention before price, screenshots, or a limited-time offer.</p>
7336
7337<p>This guide takes a review-site approach to evaluating Forex EA vendors. It does not label every private developer as unreliable, and it does not suggest that a disclosed strategy will produce future profits. Instead, it explains how a buyer can gather evidence, identify unanswered questions, and set a sensible threshold for a product that may influence real capital. A vendor can be honest and still sell a strategy that does not suit a particular broker, market regime, risk tolerance, or account size.</p>
7338
7339<p>The objective is not to find a perfect robot. It is to avoid making a high-confidence decision from low-confidence material. Good due diligence looks for consistency among the product description, the evidence, the licence, the trading behavior, and the vendor's answers. When those pieces conflict, the conflict itself is useful information.</p>
7340
7341<img src="${pp}" alt="five warning flags around suspicious forex ea vendor" style="width:100%;border-radius:8px;margin:24px 0;" />
7342
7343<h2 id="why-transparency">Why Transparency Is the First Buying Test</h2>
7344
7345<p>Transparency is not the same thing as publishing every line of proprietary code. A developer may reasonably protect implementation details, parameter research, and commercial intellectual property. For a buyer, the more practical question is whether enough verifiable information exists to understand what is being purchased and to challenge important claims. A clear explanation of intended markets, trade frequency, risk controls, known limitations, support arrangements, and licensing terms is more useful than a page full of unexplained percentages.</p>
7346
7347<p>Opaque marketing often asks the buyer to accept conclusions rather than inspect inputs. It may say that an EA is safe, fully automated, institutional, or proven without defining those words. It may display an equity curve without stating the account type, deposit history, leverage, spread assumptions, or whether the history is live, demo, or simulated. None of these omissions alone proves bad intent. Together, they make it hard to judge whether the product description applies to the buyer's own setup.</p>
7348
7349<p>A buyer should also distinguish between a claim and a documentable fact. “Low drawdown” is a claim until the vendor identifies the period, the calculation, and the account history behind it. “Works on any broker” is a claim until the conditions and exceptions are described. “No martingale” can be examined through strategy documentation and, where appropriate and permitted, technical review. Treating all marketing language as a starting point for questions is more protective than treating it as a promise.</p>
7350
7351<p>For readers who need background on the technical side of this process, the homepage overview of an <a href="/">ex4 decompiler</a> explains why compiled MT4 programs cannot be understood from their file name or sales copy alone. Technical inspection is only one evidence source, but it can be relevant when a buyer has a lawful reason to examine a file.</p>
7352
7353<h2 id="evidence-map">Build an Evidence Map Before Reading Claims</h2>
7354
7355<p>Start the evaluation with a simple evidence map. Make a list of the vendor's major statements and leave space next to each statement for its source. Examples include the strategy's instruments, recommended deposit, maximum simultaneous trades, expected holding time, maximum historical drawdown, refund policy, account restrictions, and compatibility requirements. The exercise is deliberately plain. It prevents a persuasive page from turning into a collection of remembered impressions.</p>
7356
7357<p>Next, classify each item. A direct link to a monitored account, written terms published before checkout, a dated change log, and an answer from a named support channel are sources that can be saved and revisited. A cropped screenshot, a social media comment, an anonymous testimonial, or a countdown timer is weaker material. Weak material is not automatically false, but it should not carry the same weight as a record that a buyer can independently inspect.</p>
7358
7359<p>Then look for missing context. A vendor might show a strong return figure while never stating the largest open loss, the longest losing spell, the impact of withdrawals, or the peri
7359od selected. A product may advertise a small minimum deposit while leaving out the lot-sizing mode and leverage assumed. An EA can genuinely have a simple setup process but still require a VPS, a particular session, a narrow spread range, or manual intervention during news events. Missing operating conditions matter because they can turn an apparently suitable product into a poor fit.</p>
7360
7361<p>Save a dated copy of the sales page, terms, result links, and correspondence. This is useful for comparison if the listing changes later, and it helps buyers avoid relying on memory. It also makes a refund or support discussion more orderly if a disclosed requirement turns out to be different from the delivered product. A reasonable vendor should not object to a prospective customer keeping accurate records of public statements.</p>
7362
7363<img src="${E0}" alt="detective finding hidden evidence from forex ea vendor" style="width:100%;border-radius:8px;margin:24px 0;" />
7364
7365<h2 id="results-review">Review Results Without Treating Them as Proof</h2>
7366
7367<p>Performance reporting is often the first item a buyer sees, but it should be read as evidence with limits, not a forecast. A statement from a third-party tracking service can be more informative than a screenshot because the viewer may be able to inspect history, duration, drawdown, deposits, and open positions. Even then, it describes one account under past conditions. It does not establish that another account will receive the same fills, spreads, execution, leverage, configuration, or outcome.</p>
7368
7369<p>Useful questions include: Is the account identified as real or demo? How long has it operated? Are deposits and withdrawals visible? Is the trading history complete? Can open trades and floating drawdown be reviewed? Does the account's broker and symbol format resemble the buyer's intended environment? Is the strategy operating with settings that a retail buyer can actually obtain? A transparent vendor may not be able to satisfy every preference, but should be able to explain the basics without changing the subject.</p>
7370
7371<p>Duration matters because a short sequence can flatter nearly any system. Instead of setting a universal minimum number of months, compare the record with the strategy's stated behavior. A low-frequency swing system needs enough time to produce a meaningful sample of trades. A rapid intraday system needs evidence across varying liquidity, spread, and volatility conditions. A record spanning only a favorable environment deserves cautious interpretation, not automatic rejection.</p>
7372
7373<p>Look beyond the equity line. A smooth curve may reflect modest risk, but it can also conceal wide stops, averaging, grid exposure, or unrealized losses that later become visible. Review balance and equity where available, trade size changes, concentration in one symbol, overnight exposure, and recovery behavior after losing periods. The point is not to diagnose a system from a chart. It is to identify the questions a chart cannot answer.</p>
7374
7375<p>A seller who refuses to provide account credentials may have legitimate privacy or security concerns. That does not require the buyer to fill the evidence gap with trust. The sensible response is to downgrade confidence, seek other corroboration, and avoid treating unverified screenshots as equivalent to a reviewable record.</p>
7376
7377<h2 id="strategy-disclosure">Assess Strategy Disclosure and Risk Language</h2>
7378
7379<p>A buyer does not need a vendor's full source code to ask what broad mechanism drives the EA. At minimum, a serious listing should state the markets and timeframes it is designed for, whether it trades around major news, whether it can hold positions overnight or over weekends, and whether it uses scaling, grids, recovery logic, or a fixed stop approach. These descriptions help a buyer decide whether the product belongs in a portfolio at all.</p>
7380
7381<p>Pay special attention to words that hide a risk decision. “Advanced money management” could mean fixed fractional sizing, a volatility adjustment, or an aggressive loss-recovery routine. “Smart recovery” may be a harmless exit method, or it may mean that positions increase after losses. “AI-powered” tells a buyer very little without an explanation of what the EA observes, how often it changes behavior, and what guardrails apply. A buyer does not need to assume deception, but should ask for plain definitions.</p>
7382
7383<p>Balanced risk language is a positive sign. A vendor that names unfavorable conditions, such as range-bound markets, high spreads, delayed execution, or news volatility, gives the buyer a basis for monitoring fit. By contrast, language that describes only upside, impl
7383ies certainty, or dismisses drawdown as irrelevant should reduce confidence. Trading involves uncertainty, and a credible product description can acknowledge uncertainty without becoming unhelpful.</p>
7384
7385<p>Compare the stated approach with observable behavior from any permitted demonstration. If a product is described as trend following but repeatedly averages into adverse moves, that calls for clarification. If it claims fixed risk but trade volume changes sharply after losses, ask what setting controls the change. The aim is to test internal consistency, not to infer misconduct from one unfamiliar trade.</p>
7386
7387<img src="${M0}" alt="suspicious forex ea vendor hiding information" style="width:100%;border-radius:8px;margin:24px 0;" />
7388
7389<h2 id="identity-support">Check Identity, Support, and Terms</h2>
7390
7391<p>Vendor identity is a practical accountability question. A buyer should be able to identify the business name or individual behind the offer, a reliable contact method, the jurisdiction or business address where relevant, and the terms that govern the purchase. Small developers may not have a large public footprint, but they can still provide consistent contact details, an established product history, and clear support expectations.</p>
7392
7393<p>Search the product name and vendor name separately. Look for discussions that are not hosted by the seller, including comments that disagree with the marketing. Consider the age and context of a review rather than merely its rating. A cluster of nearly identical praise, accounts created solely to promote the same EA, or reviews that repeat sales-page phrases has limited evidentiary value. A varied set of comments discussing setup, limitations, and support experiences is more informative, even when some feedback is negative.</p>
7394
7395<p>Read the licence before paying. It should clarify how many terminals, accounts, or VPS installations are allowed, whether transfers are possible, how updates are supplied, what happens if activation infrastructure changes, and the conditions for refunds. It should also explain whether the buyer receives only permission to run the software or any rights to modify or inspect it. A vague licence creates operational uncertainty long after the checkout page has closed.</p>
7396
7397<p>Support quality can be sampled before purchase. Ask a concrete compatibility question that is already answered nowhere on the page, such as whether a symbol suffix is supported or how a new version is announced. A useful reply should address the question, state any uncertainty, and avoid pressure to buy immediately. A sales response that refuses all specifics is not proof of a defective EA, but it is not a reason to increase exposure.</p>
7398
7399<h2 id="testing-claims">Put Backtests and Demonstrations in Context</h2>
7400
7401<p>Backtests are development artifacts. They can show how a defined version of a strategy behaved against a particular historical data set under stated assumptions. They cannot prove future performance, and they are easy to overread when settings are incomplete. A responsible buyer asks for the test period, modelling method, spread and commission assumptions, leverage, slippage treatment, input values, symbol, and broker data source. Without that context, an impressive report is closer to an advertisement than a reproducible experiment.</p>
7402
7403<p>Reproduce what can be reproduced. If a trial or demonstration is available, run it on a separate terminal using conditions that resemble the intended account. Results need not match exactly because data and execution vary, but material differences deserve investigation. Check that the EA is using the advertised inputs and that it does not require undisclosed files, manual trade closure, or a broker-specific condition.</p>
7404
7405<p>Some sales pages make a high win rate the headline metric. That number says little without average win, average loss, largest open exposure, and loss-recovery behavior. A system can close many small winners while carrying a small number of large risks. A buyer should examine the size and duration of adverse positions rather than assuming that a high percentage of winning trades means low risk.</p>
7406
7407<p>For a deeper explanation of what can distort historical reports, see <a href="/blog/how-to-ver
7407ify-forex-ea-backtest-results">this guide to reviewing Forex EA backtest manipulation</a>. Its practical lesson applies here: request conditions, compare results, and treat unexplained differences as a reason to pause rather than a reason to improvise with larger trade size.</p>
7408
7409<img src="${S0}" alt="warning checklist for forex ea vendor red flags" style="width:100%;border-radius:8px;margin:24px 0;" />
7410
7411<h2 id="code-boundaries">Understand Code Review, Licences, and Boundaries</h2>
7412
7413<p>Source access is not a universal requirement for a legitimate commercial EA. Vendors can have valid reasons to keep code private. The important distinction is between protecting intellectual property and making every meaningful question impossible to answer. A seller may offer an architecture summary, a third-party review, a limited audit arrangement, or a clear explanation of sensitive behaviors without handing a purchaser an unrestricted copy of source.</p>
7414
7415<p>Buyers should be equally careful about rights. Possessing an EX4 file or buying a run licence does not automatically grant permission to reverse engineer, modify, remove account restrictions, redistribute output, or copy a strategy. Licence terms and applicable law matter. Anyone considering technical examination should first identify the purpose, preserve the relevant agreement, and obtain permission where needed. The article on <a href="/blog/purchased-forex-ea-security-audit-checklist">auditing a purchased Forex EA responsibly</a> outlines a rights-aware process for reviewing an EA that a buyer is entitled to examine.</p>
7416
7417<p>When permitted, code-level review can answer questions marketing cannot settle, such as how lots are calculated, which external addresses are contacted, whether behavior changes between testing and live operation, or whether expiry logic affects a deployment. It still requires careful interpretation. Decompiled output can need validation, and an audit should not be presented as a promise of profitability or safety. It is a way to reduce unknowns about program behavior.</p>
7418
7419<p>The broader <a href="/">decompile ex4 to mq4</a> resource explains available recovery approaches and their limitations. For a buyer, the correct order is rights first, scope second, technical method third. An attempt to bypass licensing or obtain a competitor's proprietary logic is not due diligence.</p>
7420
7421<img src="${C0}" alt="scam detector device scanning forex ea vendor" style="width:100%;border-radius:8px;margin:24px 0;" />
7422
7423<h2 id="research-workflow">A Practical Research Workflow</h2>
7424
7425<p>A structured workflow helps prevent a purchase decision from being driven by a single impressive statistic. The following sequence can be completed before capital is committed:</p>
7426
7427<ol>
7428<li><strong>Capture the offer.</strong> Save the sales page, price, claimed strategy type, recommended setup, terms, and stated refund conditions with the date.</li>
7429<li><strong>List the decision-critical claims.</strong> Write down performance, drawdown, risk method, supported instruments, trading windows, support, and licence claims.</li>
7430<li><strong>Find the source for each claim.</strong> Separate monitor links, documents, and reproducible tests from screenshots and promotional statements.</li>
7431<li><strong>Search independently.</strong> Review vendor and product references across more than one community, noting dates, reviewer history, and recurring unresolved issues.</li>
7432<li><strong>Ask targeted questions.</strong> Request clarification about operating conditions, known limitations, update policy, and account restrictions. Keep the exchange.</li>
7433<li><strong>Check consistency.</strong> Compare the answers with the licence, monitored results, demonstration behavior, and sales language.</li>
7434<li><strong>Set a stop rule.</strong> Decide in advance which missing facts would cause the buyer to decline, such as absent terms, unverifiable identity, or an unexplained risk method.</li>
7435</ol>
7436
7437<p>The stop rule matters because research can otherwise become a search for reassurance. If a vendor cannot explain basic operational conditions, more testimonials rarely solve the problem. Declining a purchase because evidence is insufficient is a valid outcome. There will always be other products, while capital and attention are limited.</p>
7438
7439<h2 id="trial-deployment">How to Test a Candidate EA Cautiously</h2>
7440
7441<p>A trial can reveal configuration and behavior issues, but it should be designed as observation rather than a shortcut to confidence. Install the EA on a separate demo environment first. Use the intended broker's symbol naming, approximate leverage, typical spread, commission, and VPS arrangement where possible. Record every input value. If the vendor provides a preset file, retain the original and n
7441ote any changes made during testing.</p>
7442
7443<p>Observe the EA across normal and stressed conditions. Does it trade when the documentation says it should? Does it open more positions than expected? Are lot sizes consistent with the selected risk setting? Does it behave differently after a terminal restart or a connection interruption? Does it need manual intervention that was not disclosed? A short test cannot validate a strategy, but it can expose an installation mismatch or a discrepancy worth discussing.</p>
7444
7445<p>When moving beyond a demo, keep the first live exposure small enough that an unexpected outcome is manageable. There is no universal period or position size that makes an EA safe. The appropriate limit depends on the buyer's capital, objectives, and understanding of the stated risk. Avoid raising size simply because an early sequence is favorable. Early results are especially vulnerable to randomness and selection bias.</p>
7446
7447<p>Maintain a test log containing dates, platform build, broker, settings, trades, and support interactions. This makes it easier to determine whether a difference is due to configuration, market conditions, a software update, or a claim that needs correction. It also gives a vendor enough detail to provide meaningful support rather than guesswork.</p>
7448
7449<img src="${I0}" alt="trust badge for verified and honest forex ea vendor" style="width:100%;border-radius:8px;margin:24px 0;" />
7450
7451<h2 id="review-perspective">Where Professional Analysis Fits</h2>
7452
7453<p>ForexMQ5 is reviewed on this site as a professional EX4-to-MQ4 recovery option for owners and authorized users who need a clearer view of an MT4 program. In a vendor-evaluation context, professional analysis may be relevant after the buyer has confirmed their rights, defined a narrow audit purpose, and exhausted straightforward disclosure questions. It is not a substitute for checking terms, evaluating risk, or testing the EA in a suitable environment.</p>
7454
7455<p>The review-site perspective is that a specialist process can be more useful than anonymous upload tools when the file is important and a permitted technical review is justified. Buyers should still ask about scope, confidentiality, expected output, and feasibility. They should also treat recovered code as material requiring validation, not as an automatic verdict on a trading system.</p>
7456
7457<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
7458  <h3 style="margin-top:0;">Need an Authorized EX4 Review Path?</h3>
7459  <p>ForexMQ5 is presented as a professional option for file owners and authorized users seeking EX4-to-MQ4 recovery for a defined maintenance or review purpose. Rights, licence terms, and safe testing remain the customer's responsibility.</p>
7460  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
7461</div>
7462
7463<h2 id="decision">Make a Decision You Can Explain</h2>
7464
7465<p>The strongest buying decision is one a trader can explain without repeating a vendor slogan. It identifies what the EA is intended to do, which facts support that description, which risks remain uncertain, how the licence limits use, and what test plan will apply. That standard does not require certainty. It requires proportionate caution when software will act in a trading account.</p>
7466
7467<p>Transparency should raise confidence only when it is specific, consistent, and checkable. A vendor who documents conditions, acknowledges limitations, answers practical questions, and leaves room for a buyer to decide is easier to evaluate than one who relies on urgency and unexplained outcomes. Conversely, unanswered questions about identity, terms, trade management, or reported results are enough reason to wait.</p>
7468
7469<p>Ultimately, a Forex EA should be judged as a tool with defined behavior and defined risks, not as a shortcut around uncertainty. Research, rights-aware review, controlled testing, and conservative deployment do not guarantee an outcome. They do give the buyer a better basis for deciding whether the vendor has earned a place in the evaluation process.</p>
7470    `}
7470,{slug:"ex4-to-mq4-recovery-methods-and-validation-guide",title:"EX4 to MQ4 Recovery in 2026: A Practical Method and Validation Guide",metaTitle:"EX4 to MQ4 Recovery Guide: Methods, Limits and Validation | 2026",metaDescription:"Compare EX4 to MQ4 recovery methods, understand realistic output limits, and follow a practical validation plan for authorised MT4 source recovery in 2026.",keywords:"ex4 to mq4 recovery, ex4 decompilation methods, validate recovered mql4, mt4 source code recovery, ex4 recovery guide, mql4 decompiler",excerpt:"A practical guide to choosing an authorised EX4 to MQ4 recovery route, assessing the file before work begins, and validating recovered MQL4 without treating compiled output as a guaranteed source-code replica.",date:"March 17, 2026",dateISO:"2026-03-17",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:up,imageAlt:"EX4 to MQ4 recovery workflow and validation guide",tableOfContents:[{id:"recovery-question",title:"Frame the Recovery Question First"},{id:"what-survives",title:"What an EX4 Can Still Reveal"},{id:"file-triage",title:"Triage the File Before Choosing a Method"},{id:"method-map",title:"Recovery Methods and Their Tradeoffs"},{id:"diy-lab",title:"A Controlled DIY Research Route"},{id:"tool-screening",title:"Screening Automated Tool Output"},{id:"service-review",title:"Reviewing the Professional Option"},{id:"validation-plan",title:"Validate Behavior Before Any Live Use"},{id:"maintenance",title:"Turn Recovery Into Maintainable Engineering"},{id:"questions",title:"Questions to Ask Before Proceeding"}],content:`
7471<p>An EX4 file can keep an MT4 strategy running long after its readable MQ4 project has disappeared. That fact creates an understandable question: can the compiled program become a workable source project again? The useful answer is not a simple yes or no. EX4 to MQ4 recovery is an analysis task with technical limits, rights considerations, and a validation stage that matters as much as the extraction itself.</p>
7472
7473<p>This guide is written for an owner, authorised maintainer, or reviewer who needs a sensible way to assess that task. It explains what to inspect before selecting a method, why build age and protection matter, how DIY and automated routes differ from specialist review, and how to decide whether recovered code behaves close enough to the original for its intended purpose. It is not a shortcut for copying a vendor product, removing licence controls, or deploying unfamiliar trading code without review.</p>
7474
7475<p>Readers comparing the available <a href="/">ex4 to mq4 decompiler</a> approaches should begin by defining the actual outcome needed. A readable audit of order-management logic, a repairable starting point for a personally owned EA, and a clean migration specification are related goals, but they do not require the same depth of reconstruction. Clear scope helps prevent wasted work and makes it easier to judge the result honestly.</p>
7476
7477<img src="${up}" alt="overview of the EX4 to MQ4 recovery process" style="width:100%;border-radius:8px;margin:24px 0;" />
7478
7479<h2 id="recovery-question">Frame the Recovery Question First</h2>
7480
7481<p>Before looking for software or uploading a file anywhere, identify why the EX4 matters and whether the requester is entitled to inspect it. Possessing a compiled EA is not necessarily ownership of its source code. A marketplace licence may allow installation on an account while prohibiting modification, redistribution, or reverse engineering. A custom-development agreement may assign the finished work to the client, reserve parts of a developer library, or say nothing clear about source handover.</p>
7482
7483<p>For an authorised project, a one-page recovery brief is a practical starting point. It should name the file, record its origin, state the intended use, and list the evidence supporting that use. Useful records include a commission agreement, invoice, repository history, emails granting permission, and the original delivery message. Keep an untouched copy of the EX4 and record its file size and cryptographic checksum if the project is important. These steps do not create rights, but they preserve facts that can otherwise disappear.</p>
7484
7485<p>The purpose statement should be narrow. “Restore a company-owned EA after a failed backup so a developer can maintain it” identifies a maintenance objective. “Inspect authorised code for an unexpected trade-closing condition” identifies an audit objective. By contrast, a request to unlock account restrictions, reproduce a commercial strategy, or publish reconstructed code signals a different and potentially problematic purpose. Jurisdiction, contract terms, and circumstances matter, so material uncertainty is a reason to obtain permission or qualified legal advice before technical work starts.</p>
7486
7487<p>Recovery also benefits from a practical definition of success. Some users need a source project that compiles and reproduces selected historical behavior. Others only need to i
7487dentify inputs, external calls, or the conditions that trigger orders. A project that succeeds at the second goal may not be suitable for the first. Setting the threshold in advance avoids treating any text that resembles MQL4 as a usable result.</p>
7488
7489<h2 id="what-survives">What an EX4 Can Still Reveal</h2>
7490
7491<p>MQ4 is the human-written program edited in MetaEditor. EX4 is the compiled form that MT4 loads to execute an Expert Advisor, custom indicator, or script. During compilation, the platform transforms source statements into a representation suitable for its runtime. The compiled file must retain enough operational information for MT4 to execute the program, handle inputs, invoke functions, and display required text. It does not have to retain every clue that made the original source pleasant to read.</p>
7492
7493<p>That distinction defines the central limit. Original comments, formatting, many meaningful variable names, design notes, and sometimes high-level structure are generally unavailable after compilation. An analyst may infer sensible names from how a value is used, but inference is not recovery of the original label. Similarly, a reconstructed sequence of conditions can express the same operational behavior while looking very different from the author's original routine.</p>
7494
7495<p>Some clues can remain useful. Input labels, indicator references, error messages, symbol strings, order comments, and external function names may survive because the program needs them at runtime. Program properties and dependency patterns can also help establish context. Those clues are starting points, not proof of strategy intent. A string called “safe mode” does not establish what the code actually does, and a familiar indicator name does not reveal every filter surrounding it.</p>
7496
7497<p>For a foundation on file roles, readers can review <a href="/blog/ex4-files-explained-for-mt4-users">the explanation of EX4 files for MT4 users</a>. The important operational lesson is that compilation is not a reversible archival process. A recovery project should aim for verified, understandable behavior within a defined scope, rather than promising a perfect historical copy of the source folder.</p>
7498
7499<img src="${x0}" alt="EX4 file anatomy showing compiled program components" style="width:100%;border-radius:8px;margin:24px 0;" />
7500
7501<h2 id="file-triage">Triage the File Before Choosing a Method</h2>
7502
7503<p>File triage is a small investment that can save days. Start with provenance. Is this the exact EX4 that ran on the relevant terminal, or a copy found in an archive? Is there an accompanying set file, log, chart template, DLL, indicator, or documentation? A recovered EA may compile yet behave differently if a required custom indicator or configuration file is missing. Collect those adjacent materials before drawing conclusions from the binary alone.</p>
7504
7505<p>Next, identify the program type and visible characteristics. An Expert Advisor commonly has trading functions, inputs related to lots or risk, and order comments. An indicator may expose buffers and drawing settings. A script may perform a single operation and exit. This basic classification influences test design later. It also guards against a common mistake: evaluating an indicator output as if it were an automated trading strategy.</p>
7506
7507<p>Build era is another major factor. The EX4 format and compiler behavior have changed across MT4's history. Older files can fit patterns supported by older utilities, while later builds may require different analysis and yield less tidy output. Protection layers, packing, corruption, file truncation, and unusual dependencies can add further uncertainty. The date a trader bought an EA is only a clue. The relevant issue is when the supplied file was compiled and whether it has been altered since delivery.</p>
7508
7509<p>A triage record can include the filename, size, hash, terminal build if known, source of the copy, program type, observed inputs, required companion files, and the owner-approved purpose. It should also record whether the original EX4 runs in a controlled terminal. A working reference binary is valuable because it gives the later validation process something concrete to compare against. If the file will not load, preserve any journal messages instead of repeatedly changing it.</p>
7510
7511<p>Do not confuse a header check with a complete feasibility assessment. A build indicator may guide method selection, but it cannot guarantee clean output or reveal every protection mechanism. The sensible claim at this stage is limited: triage narrows the likely effort and exposes missing materials. It does not establish that every file can be restored to an identical source project.</p>
7512
7513<img src="${w0}" alt="authorised reasons for assessing EX4 recovery" style="width:100%;border-radius:8px;margin:24px 0;" />
7514
7515<h2 id="method-map">Recovery Methods and Their Tradeoffs</h2>
7516
7517<p>There are three broad routes: hands-on research using debugging tools, automated decompiler utilities, and a professional recovery service. None is universally best. The sensible choice depends on the file's build and condition, the needed output, the user's technical experience, confidentiality requirements, available time, and the value of a wrong conclusion.</p>
7518
7519<table style="width:100%;border-collapse:collapse;margin:24px 0;">
7520<thead><tr style="background:#1a56db;color:#fff;"><th style="padding:10px 14px;text-align:left;">Route</th><th style="padding:10px 14px;text-align:left;">Best fit</th><th style="padding:10px 14px;text-align:left;">Main limitation</th><th style="padding:10px 14px;text-align:left;">Validation need</th></tr></thead>
7521<tbody>
7522<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">DIY analysis</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Experienced reverse engineers with authorised files</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">High time and skill requirement</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Extensive</td></tr>
7523<tr style="background:#f8faff;"><td style="border:1px solid #d0d8f0;padding:8px 12px;">Automated utility</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Low-stakes screening, often older files</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Output can be incomplete or misleading</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Extensive</td></tr>
7524<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Professional review</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Important maintenance, audit, or migration work</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Cost and third-party handling</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Still required</td></tr>
7525</tbody></table>
7526
7527<p>The comparison should not be reduced to speed alone. An automated result delivered in minutes is not economical if it contains a quietly inverted condition or incorrectly typed value that takes weeks to diagnose. Conversely, a specialist process is not a substitute for ownership checks, test cases, or maintenance discipline. It is an option for improving analysis and readability when the file and intended use justify it.</p>
7528
7529<p>For a high-level starting point, the site's <a href="/">ex4 decompiler</a> review compares the routes and explains why method claims should be read against file age, protection, and the quality checks actually performed. The strongest choice is usually the one that matches the consequence of error, not the one with the most dramatic marketing promise.</p>
7530
7531<img src="${k0}" alt="choosing an EX4 recovery method based on file needs" style="width:100%;border-radius:8px;margin:24px 0;" />
7532
7533<h2 id="diy-lab">A Controlled DIY Research Route</h2>
7534
7535<p>A DIY route is a research project, not a button-clicking exercise. It is most suitable for someone who already understands Windows debugging, executable analysis, MQL4 semantics, and the legal boundaries of the authorised file under review. It should be performed in an isolated environment using copies, not on the trading terminal that manages an active account.</p>
7536
7537<p>x64dbg and ScyllaHide are frequently mentioned in discussions of dynamic analysis. In broad terms, a researcher observes a process in a controlled lab, follows relevant execution paths, and records evidence that can help explain how the runtime handles a compiled program. The work may involve breakpoints, memory inspection, call tracing, and careful mapping of low-level observations to MQL4 c
7537oncepts. Those are specialist activities. A generic tutorial cannot guarantee that the result represents a particular file correctly.</p>
7538
7539<p>The difficult part is interpretation. Low-level operations do not arrive with the author's original variable names or comments. Branches must be distinguished from error handling, loop boundaries reconstructed, types inferred, and platform calls understood in context. Trading code adds extra risks because a routine may depend on tick timing, broker symbol suffixes, spread conditions, history availability, or external indicators. A block that looks straightforward in a debugger can have a very different effect in the terminal.</p>
7540
7541<p>A controlled DIY workflow therefore uses checkpoints. Preserve the original file, document each hypothesis, compile any reconstruction separately, and compare individual functions against observable behavior rather than relying on appearance. If the goal becomes a general strategy clone or a licence bypass, stop. The appropriate authorised scope is analysis, recovery, maintenance, or audit of code the requester has the right to examine.</p>
7542
7543<h2 id="tool-screening">Screening Automated Tool Output</h2>
7544
7545<p>Automated utilities can be useful for a preliminary look, particularly with files from older compiler eras. They can expose inputs, strings, broad function layouts, or a starting representation faster than manual analysis. Their limits are equally important. A tool is built around assumptions about file layouts, opcodes, and compiler patterns. When those assumptions fail, the utility may stop openly, emit only fragments, or produce text that compiles while no longer represents the original logic.</p>
7546
7547<p>The last failure mode deserves the most caution. Compilation proves that a program satisfies syntax and type rules. It does not prove that a comparison operator, array index, stop-loss calculation, or order-selection path was reconstructed correctly. A polished-looking MQ4 file can still be unsuitable for live use. Treat every generated name as provisional, every missing function as a question, and every unreviewed external call as a reason to pause.</p>
7548
7549<p>Before using any online utility, consider confidentiality. Uploading a valuable EX4 means handing a copy of the binary to an outside operator. The terms, retention policy, identity of the operator, and security controls may be unclear. An authorised owner who decides to experiment should use a non-production copy and avoid sharing passwords, account details, or proprietary companion materials. An unverified download also presents ordinary malware and tampering risks.</p>
7550
7551<p>A useful screening checklist asks whether all expected inputs appear, whether event handlers are plausible, whether order functions and error paths are complete, whether declarations match usage, and whether the output explains observed binary behavior. Failure on any point does not automatically prove the recovery is useless, but it means the output is a hypothesis requiring more analysis.</p>
7552
7553<img src="${A0}" alt="analysis pipeline for EX4 to MQ4 recovery" style="width:100%;border-radius:8px;margin:24px 0;" />
7554
7555<h2 id="service-review">Reviewing the Professional Option</h2>
7556
7557<p>For an important authorised file, the professional option is often more appropriate than relying on a generic utility. ForexMQ5 is positioned on this review site as a specialist EX4 to MQ4 recovery service. The service can be considered by users who have documented authority to request recovery and who need a clearer workflow than an anonymous upload tool provides. Published pricing starts from $50 per file, while complexity can affect the final scope.</p>
7558
7559<p>The review-site rationale is practical rather than absolute. A specialist process may combine tooling with human examination, allowing ambiguous sections, dependencies, and MQL4 conventions to receive more attention than a one-pass utility can provide. It may also offer a defined intake and an opportunity to state the file's purpose. That does not mean every file is recoverable, every reconstruction will equal the lost original, or any request becomes permitted merely because a third party performs the technical work.</p>
7560
7561<p>A careful customer should ask what deliverable is expected, how files are handled, whether feasibility is asse
7561ssed, how unclear sections are communicated, and what validation remains the customer's responsibility. The answer should be specific to the file and should not promise trading outcomes. Recovered code needs normal software review and controlled testing before it is treated as production-ready.</p>
7562
7563<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
7564  <h3 style="margin-top:0;">Considering an Authorised Recovery Project?</h3>
7565  <p>ForexMQ5 is reviewed as a professional option for documented recovery, maintenance, and code-audit needs. Prospective customers should confirm their rights and preserve the original EX4 before requesting an assessment.</p>
7566  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
7567</div>
7568
7569<h2 id="validation-plan">Validate Behavior Before Any Live Use</h2>
7570
7571<p>Recovery becomes useful only when the resulting code has been tested against the objective that justified it. The original EX4, when it still runs, is the best reference. Build a controlled MT4 environment with the same symbol conventions, historical data source where possible, inputs, timeframes, and companion indicators. Keep the original binary and recovered MQ4 project separate so a test cannot accidentally overwrite the reference.</p>
7572
7573<p>Begin with a compilation review. Resolve errors deliberately, list warnings, and inspect changes made to address them. Then test initialization and visible inputs. Does the reconstructed program expose expected settings? Does it load required indicators? Does it create the expected chart objects or journal messages? These basic checks often reveal missing dependencies before a long backtest obscures the issue.</p>
7574
7575<p>Next, compare behavior over selected historical windows. Choose quiet and volatile periods, different sessions, and samples containing the scenarios relevant to the strategy. Record trade entries, exits, lot calculations, pending-order placement, modifications, and error handling. Matching total profit alone is weak evidence because two systems can reach a similar number through different trades. A sequence comparison and examination of key state changes are more informative.</p>
7576
7577<p>When results diverge, isolate the first divergence. Check data quality, spread assumptions, symbol suffixes, broker digit settings, initialization timing, and indicator values before assuming that reconstruction is wrong. Then inspect the related code path. This disciplined approach is safer than editing many lines until a profit curve looks familiar. It creates an audit trail and reduces the temptation to optimise away a discrepancy that actually exposes a logic error.</p>
7578
7579<p>Readers who need a fuller test checklist can use <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">the guide to testing decompiled MQL4 before live trading</a>. No historical comparison can remove market risk or guarantee future results. The reasonable target is narrower: establish whether the recovered project behaves consistently with the reference under documented conditions and whether it is understandable enough to maintain safely.</p>
7580
7581<img src="${T0}" alt="step-by-step validation of recovered MQL4 code" style="width:100%;border-radius:8px;margin:24px 0;" />
7582
7583<h2 id="maintenance">Turn Recovery Into Maintainable Engineering</h2>
7584
7585<p>A recovered MQ4 file should not return to the same single-copy risk that caused the recovery need. Create a private version-control repository, commit the initial recovered state, and preserve the untouched EX4 alongside its checksum and documentation. Record every later cleanup change in a commit message that explains why it was made and how it was tested. Keep set files, custom indicators, libraries, test reports, and deployment notes in the same controlled project.</p>
7586
7587<p>Refactoring should be gradual. Start by documenting observed behavior, then rename only variables whose role is supported by evidence. Separate input validation, signal generation, position management, and logging where that can be done without changing behavior. Add comments that distinguish verified facts from analyst assumptions. A clean project is valuable, but premature rewriting can erase the ability to compare it with the reference binary.</p>
7588
7589<p>For a future platform move, treat recovered MQL4 as a specification and test fixture, not as code that can simply be pasted into MQL5. The platforms differ in APIs, order and position models, event handling, and tester behavior. A migration requires a separate implementation plan and comparison tests. The recovered project can make that work more informed, but it does not eliminate it.</p>
7590
7591<h2 id="questions">Questions to Ask Before Proceeding</h2>
7592
7593<h3>Can an EX4 be turned into the exact original MQ4?</h3>
7594<p>Usually not in every detail. Compilation removes or transforms information such as comments, formatting, and many original names. The useful measure is whether authorised recovery produces a readable, testable project that meets the defined purpose.</p>
7595
7596<h3>
7596Does a recovered file that compiles prove it is accurate?</h3>
7597<p>No. Compilation verifies syntax, not equivalence. Compare behavior with the original EX4 in a controlled environment and investigate the first meaningful divergence.</p>
7598
7599<h3>Are free tools adequate?</h3>
7600<p>They may provide a preliminary result for some files, especially older ones, but their output should be treated as unverified. Modern builds, protection, and unusual structure can produce incomplete or misleading reconstructions.</p>
7601
7602<h3>Is recovery allowed for a purchased EA?</h3>
7603<p>A purchase may grant only a right to run the EA. Licence terms, ownership, written permission, local law, and the intended use all matter. Authorised maintenance and copying a vendor product are not equivalent situations.</p>
7604
7605<h3>What should happen if the original binary no longer runs?</h3>
7606<p>Preserve the file, logs, settings, and any historical observations. Validation can still use documented behavior, but confidence will be lower without a working reference. State that limitation plainly in the project record.</p>
7607
7608<p>The durable lesson is simple: approach EX4 to MQ4 recovery as authorised software analysis followed by evidence-based testing. A careful scope, realistic expectations, the right method for the file, and disciplined maintenance offer more value than any promise of instant source-code restoration.</p>
7609    `},{slug:"modern-mt4-ex4-decompiler-limitations-explained",title:"Modern MT4 EX4 Decompiler Limits: Why Free Tools Return Broken Code",metaTitle:"Modern MT4 EX4 Decompiler Limits: Why Free Tools Fail",metaDescription:"Learn why free EX4 decompilers often fail on modern MT4 files, how to read the warning signs, and when a reviewed professional recovery option is more appropriate.",keywords:"modern mt4 ex4 decompiler limitations, free ex4 decompiler failure, broken mq4 output, mt4 build compatibility, ex4 recovery options",excerpt:"A free EX4 utility can open a file yet still produce output that is incomplete, misleading, or unusable. This review guide explains the format, maintenance, and verification limits behind failures on modern MT4 builds.",date:"March 5, 2026",dateISO:"2026-03-05",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:mp,imageAlt:"free ex4 decompiler hitting a wall with modern mt4 builds",tableOfContents:[{id:"quick-answer",title:"The Short Answer Behind Failed Output"},{id:"file-era",title:"Why the File Era Matters More Than the Tool Name"},{id:"compiler-losses",title:"What Compilation Changes and Removes"},{id:"failure-diagnosis",title:"Reading Four Common Failure Signals"},{id:"false-confidence",title:"The Risk of Code That Looks Plausible"},{id:"protection-and-damage",title:"Protection, Corruption, and Dependencies"},{id:"sensible-triage",title:"A Sensible Triage Process"},{id:"choosing-a-route",title:"Comparing Free, DIY, and Reviewed Service Routes"},{id:"before-live-use",title:"What to Verify Before Any Live Use"},{id:"questions",title:"Common Questions About Modern EX4 Files"},{id:"takeaway",title:"The Practical Takeaway"}],content:`
7610<p>A free EX4 decompiler can fail in a way that is more confusing than a simple error message. It may create an MQ4 file, populate a few inputs, and display blocks that resemble MQL4. That apparent success encourages a trader or developer to keep going. Hours later, the file will not compile, a function is empty, or a rebuilt Expert Advisor behaves unlike the original. The problem is not necessarily a missing checkbox or an inexperienced user. Often, the utility is trying to interpret a file format and compiler output it was never designed to understand.</p>
7611
7612<p>This independent review guide looks at why that gap is common with modern MT4 EX4 files. It is intended for people who own, are authorised to inspect, or otherwise have permission to recover a file. It does not treat decompilation as a guarantee, nor does it suggest bypassing licences, account restrictions, or protections. Instead, it offers a practical way to distinguish an old file that may be worth a limited free attempt from a newer or more complex file that needs a different route.</p>
7613
7614<p>The central point is simple: an EX4 extension does not identify one permanent technical format. MetaEditor has changed over time, compiler behavior differs between build families, and a compiled file retains less context than its original source. A tool can have a familiar name and positive historical comments while still being a poor match for the particular file in front of the user.</p>
7615
7616<img src="${mp}" alt="free decompiler tool reaching a limitation with a modern MT4 file" style="width:100%;border-radius:8px;margin:24px 0;" />
7617
7618<h2 id="quick-answer">The Short Answer Behind Failed Output</h2>
7619
7620<p>Most free utilities were made for a known range of older EX4 layouts. Their parser expects particular header fields, instruction patterns, tables, and runtime conventions. When the file differs, the tool has only a few possible outcomes: it can stop safely, skip the parts it cannot identify, guess incorrectly, or crash. None of these outcomes turns into a reliable recovery merely by running the same file again.</p>
7621
7622<p>The build 600 transition is especially important in discussions of MT4 decompilation. It brought a substantially revised MQL4 environment and changed the compiled output that tools needed to analyse. Later updates continued to matter as well. An older utility may be useful historical software, but it has no automatic way to learn new structures after its development stops. Hardware speed, administrator rights, and a different Windows version cannot supply missing knowledge of a binary format.</p>
7623
7624<p>There is a second issue even when a tool recognizes the broad file family. Compilation does not preserve a source file as a neatly compressed copy. Comments, formatting, many original identifiers, and parts of the author’s organisation are not available in the compiled result. Optimisation can combine or rearrange operations. A reconstruction process has to infer readable source from what remains. That is a difficult task even for a current analysis workflow, and it is a poor fit for a fixed utility that provides no review or validation step.</p>
7625
7626<p>For readers comparing terminology and options, the homepage overview of an <a href="/">ex4 decompiler</a> explains the distinction between a basic automated conversion and an assessed recovery process. The distinction matters because a file opening successfully is not the same as producing source that can be understood, compiled, and carefully tested.</p>
7627
7628<h2 id="file-era">Why the File Era Matters More Than the Tool Name</h2>
7629
7630<p>Before choosing any approach, identify what can be known about the file. A creation date in the Windows file properties is not conclusive because copying, downloading, or restoring an archive can change it. More useful clues include the original delivery email, an old MetaEditor project folder, a repository tag, a developer invoice, terminal journals, and notes from the person who compiled it. The question is not just when the EA was first conceived. The relevant question is when this 
7630specific EX4 was built.</p>
7631
7632<p>Older MT4 files are not identical, but they tend to fall into groups that free tools targeted. Very early files may use patterns that have been studied for years. Files from the middle period can produce partial results where the EA is small and uncomplicated. Modern files are more likely to encounter a tool whose assumptions no longer fit. This is why an old forum post saying a converter worked can be genuine while being irrelevant to a file delivered much later.</p>
7633
7634<h3>Build labels are useful, not magic</h3>
7635
7636<p>Build numbers provide context, but they should not be used as a promise of success or failure in isolation. A file may have dependencies, custom libraries, unusual compiler settings, or vendor protection. Conversely, a straightforward older EA may be easier to inspect than its date suggests. Think of the build family as an early routing signal. It tells the user whether investing time in a legacy tool is sensible, not whether the recovered code is safe to use.</p>
7637
7638<p>The technical background in <a href="/blog/mql4-to-ex4-compilation-explained">how MetaTrader 4 compiles EX4 files</a> helps explain why the compiler version affects later analysis. A useful file history should be saved alongside the original EX4, particularly when the project has business value. Keeping an untouched copy and noting the source of the file prevents a later cleanup attempt from obscuring what was received.</p>
7639
7640<img src="${R0}" alt="timeline illustrating different MT4 build families and compiler output changes" style="width:100%;border-radius:8px;margin:24px 0;" />
7641
7642<h2 id="compiler-losses">What Compilation Changes and Removes</h2>
7643
7644<p>An MQ4 file is written for people to read and edit. It contains declarations, labels, comments, spacing, and choices that make the author’s intent easier to follow. MetaEditor converts that material into executable form for the terminal. The EX4 must preserve enough behavior for the platform to run it, but it does not need to preserve every explanatory detail from the source.</p>
7645
7646<p>That difference explains why an exact original source file should not be expected from any decompiler. Variable names may become generic names. A sequence of conditions can return as a less elegant block. Source comments cannot simply be reconstructed when they are absent from the binary. The best practical outcome is usually maintainable source that represents observable logic well enough for authorised maintenance, investigation, or migration. It is not a time machine that restores every design decision made by the original author.</p>
7647
7648<p>Modern compiler output can also encode operations and data handling differently from the assumptions inside legacy programs. If a parser assigns the wrong meaning to an instruction or begins reading at the wrong offset, the consequences spread. A later function can have the wrong arguments because an earlier boundary was identified incorrectly. A string table can look empty because the tool searched in the wrong place. An output file may contain dozens of lines only because the utility is printing its guesses.</p>
7649
7650<p>This is why the phrase “it converted” is not a useful quality test. A recovery candidate needs to be examined on several levels: does it compile, do built-in function calls have sensible signatures, are input types plausible, and does controlled behavior align with the original file? Each level can expose a different kind of reconstruction error.</p>
7651
7652<img src="${D0}" alt="technical limits affecting an outdated EX4 decompiler" style="width:100%;border-radius:8px;margin:24px 0;" />
7653
7654<h2 id="failure-diagnosis">Reading Four Common Failure Signals</h2>
7655
7656<p>A failed free attempt can still provide useful information if it is interpreted cautiously. It should not be uploaded repeatedly to unknown websites, and it should not be treated as a licence to inspect somebody else’s commercial EA. For an authorised file, the following patterns help explain what the output is saying.</p>
7657
7658<h3>1. Unsupported format or immediate rejection</h3>
7659
7660<p>A direct message that the file is unsupported is often the most honest result. The tool compared a header value or layout against its known patterns and stopped. There may be no setting that resolves this, because the missing piece is parser support. Trying multiple download mirrors of the same old program usually repeats the same limitation.</p>
7661
7662<h3>2. Inputs appear but the trading logic is missing</h3>
7663
7664<p>Some files produce property declarations, external inputs, or a short shell while most functions are absent. This can happen when the utility recognizes an accessible metadata area but cannot decode the executable section. The output is not a partial source backup in a meaningful sense. It is evidence that the easy portion was visible and the important portion was not interpreted.</p>
7665
7666<h3>
76663. A large file filled with generic or contradictory statements</h3>
7667
7668<p>Generated source can look impressive because it has braces, functions, and variables. Look for signs of structural trouble: undeclared identifiers, impossible conversions, repeated opaque labels, nonsensical function parameters, or branches that can never run. These signals do not prove every line is wrong, but they rule out casual deployment. A syntactically repaired version can still preserve the wrong logic.</p>
7669
7670<h3>4. A hang, access error, or crash</h3>
7671
7672<p>Older utilities sometimes loop or terminate unexpectedly when their parser loses its place in an unfamiliar layout. This is not a reason to disable security controls or force the program through a damaged file. Work with a copy, scan downloaded software through normal security practices, and stop if the tool behaves unpredictably. The EX4 may be intact; the utility may simply be unprepared for it.</p>
7673
7674<p>The most important diagnostic is whether the result can be independently validated. A no-output result is disappointing but clear. Plausible looking incorrect code is harder because it creates false confidence and can lead to changes made on an invented understanding of the strategy.</p>
7675
7676<h2 id="false-confidence">The Risk of Code That Looks Plausible</h2>
7677
7678<p>Free output becomes risky when a user tries to make it compile by fixing surface errors one at a time. Replacing an unknown type, adding a missing semicolon, or renaming a duplicate variable can remove compiler messages without restoring the original program. It can turn a visibly incomplete reconstruction into a runnable EA whose behavior is unknown. In a trading context, that is a poor basis for live use.</p>
7679
7680<p>Consider a recovered order-management section. A tool might place arguments in an order that c
7680ompiles but changes a stop level, direction, or magic number. It might infer a numeric variable where a datetime or boolean was intended. A loop that was originally bounded may appear as a condition with the opposite sense. The terminal has no way to know that the author’s meaning was lost upstream. It will execute the rebuilt file that it was given.</p>
7681
7682<p>Readable naming deserves the same caution. Generic names such as variable_17 are expected after compilation. A descriptive replacement can help later review, but it is an analyst’s interpretation, not recovered evidence. Good documentation separates verified facts from inferred labels. It also records assumptions so another authorised reviewer can challenge or confirm them.</p>
7683
7684<img src="${q0}" alt="obfuscated EX4 logic creating a barrier for automated conversion" style="width:100%;border-radius:8px;margin:24px 0;" />
7685
7686<h2 id="protection-and-damage">Protection, Corruption, and Dependencies</h2>
7687
7688<p>Not every difficult EX4 is difficult for the same reason. Build mismatch is only one possibility. A vendor may have used code-obfuscation techniques that make automated reconstruction harder to read. The file may be truncated, altered, or downloaded incompletely. It may call a DLL, rely on a custom indicator, refer to files in the terminal data folder, or require inputs and symbols not present in the test environment.</p>
7689
7690<p>These conditions call for restraint. Obfuscation is not an invitation to defeat a vendor’s controls or remove account restrictions. If a licence or permission is unclear, the appropriate first step is to contact the apparent rights holder. If the requester owns the work or has written authority to maintain it, protection and dependencies still affect what can be recovered and tested. The original EX4 should be preserved rather than modified in an effort to make a legacy tool accept it.</p>
7691
7692<p>Corruption can be especially deceptive. An EA may still load in one terminal setup while a copied file is incomplete, or a tool may report a format issue that is actually caused by a damaged transfer. Comparing the file size and checksum with a known original, when available, is a basic check. So is collecting accompanying indicators, libraries, preset files, and any notes about the intended chart and broker symbol. Recovery is easier to assess when the surrounding environment is known.</p>
7693
7694<img src="${j0}" alt="modern MT4 file protections and dependencies forming a technical barrier" style="width:100%;border-radius:8px;margin:24px 0;" />
7695
7696<h2 id="sensible-triage">A Sensible Triage Process</h2>
7697
7698<p>A short, disciplined triage process avoids both wasted time and accidental misuse. It works best for a file the requester has the right to inspect.</p>
7699
7700<ol>
7701  <li><strong>Confirm authority.</strong> Gather the development agreement, licence, assignment, or other written basis for recovery. Ownership of an EX4 copy is not automatically ownership of its source.</li>
7702  <li><strong>Preserve the original.</strong> Copy the file to a controlled location, note its origin and size, and avoid testing directly on the only copy.</li>
7703  <li><strong>Record the known history.</strong> Note delivery date, probable MetaEditor era, platform version, dependencies, settings, and the observed problem that prompted recovery.</li>
7704  <li><strong>Set a limited free-test threshold.</strong> A legacy tool can be reasonable for a clearly old, uncomplicated file, but stop after an unsupported notice, empty logic, or implausible output. Repeated guesses do not improve parser coverage.</li>
7705  <li><strong>Choose the next route based on the purpose.</strong> A maintenance project, authorised audit, and migration task each require different evidence and validation.</li>
7706</ol>
7707
7708<p>This framework also protects against a common misconception: that free software is costless. The download may have no price, but time spent repairing unreliable output, exposure to untrusted executables, and the chance of acting on incorrect code all have costs. A practical decision considers those risks alongside the age and value of the file.</p>
7709
7710<p>For a wider option comparison, the review site’s <a href="/">decompile ex4 to mq4</a> resource frames the question around file compatibility and intended use instead of promises that every binary can be converted perfectly. That is the right starting point for anyone deciding whether an old utility is a quick diagnostic or an unsuitable primary method.</p>
7711
7712<h2 id="choosing-a-route">Comparing Free, DIY, and Reviewed Service Routes</h2>
7713
7714<p>There is no single route appropriate for every EX4. Free software has a narrow role: it can be a limited experiment for an old file with clear authority and modest complexity. Its output should be considered unverified until it passes careful checks. It is not a dependable option merely because it is easy to find.</p>
7715
7716<p>A technical DIY investigation can offer more visibility for an experienced analyst working within their rights. It requires knowledge of executable analysis, the MT4 environment, and MQL4 behavior. It also requires patience to document hypotheses instead of treating a first interpretation as fact. This route may suit a developer recovering their own legacy project, but it is not a simple c
7716onversion workflow for a trader who needs usable source quickly.</p>
7717
7718<p>A professional route is worth considering when the EX4 is from a newer build family, when a free attempt is clearly broken, when the file has meaningful maintenance value, or when a requester needs an assessed result rather than raw generated text. ForexMQ5 is reviewed on this site as a specialist professional option for authorised EX4-to-MQ4 recovery, with pricing stated from $50 per file. Its value proposition is a maintained, file-specific process rather than an assertion that every file will have an identical outcome.</p>
7719
7720<p>A responsible service discussion also needs limits. No provider should make permission questions disappear, guarantee that comments or original variable names can be restored, or encourage circumvention of licensing controls. The requester remains responsible for having the necessary rights and for validating any rebuilt file before operational use. The detailed <a href="/blog/best-ex4-decompiler-options-review">EX4 decompiler options review</a> gives readers additional criteria for comparing a professional assessment against older automated tools and hands-on methods.</p>
7721
7722<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
7723  <h3 style="margin-top:0;">Need an Authorised Modern-File Assessment?</h3>
7724  <p>ForexMQ5 is reviewed as a professional recovery option for users with a documented maintenance, ownership, or authorised audit purpose. File condition and build compatibility should be assessed before expectations are set.</p>
7725  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
7726</div>
7727
7728<h2 id="before-live-use">What to Verify Before Any Live Use</h2>
7729
7730<p>Recovery output should enter a review process, not a live account. First, compile it in an appropriate MetaEditor environment and resolve errors with an explanation for each change. Compilation proves only that the code satisfies the compiler. It does not establish that reconstructed logic matches the EX4.</p>
7731
7732<p>Next, inspect inputs, order logic, lot sizing, symbol handling, time filters, and dependencies. Confirm that custom indicators and external calls are present and understood. Run controlled tests using the same settings, symbol conventions, and historical context where practical. Compare observable decisions, logs, and trade sequences rather than judging a reconstruction from a single attractive backtest result. Historical tests have their own limitations and should not be read as evidence of future performance.</p>
7733
7734<p>Finally, keep a change log. State which portions came from recovery, which portions were inferred, which errors were corrected, and which tests were run. This matters when a developer returns to the EA months later or another authorised person takes over maintenance. It also makes it easier to identify whether an unexpected result stems from the original system, a platform change, or a post-recovery edit.</p>
7735
7736<img src="${P0}" alt="quality review of recovered MQL4 code before controlled testing" style="width:100%;border-radius:8px;margin:24px 0;" />
7737
7738<h2 id="questions">Common Questions About Modern EX4 Files</h2>
7739
7740<h3>Does an empty MQ4 file mean the EX4 has no trading logic?</h3>
7741<p>Usually, no. It more often means the utility could read a small metadata portion but could not interpret the executable area. Check the file’s origin and build context before drawing a conclusion about the EA itself.</p>
7742
7743<h3>Can a different free decompiler solve the issue?</h3>
7744<p>It can be worth a tightly limited comparison for an authorised legacy file, because tools vary. But several programs built on similar old assumptions can fail in the same way. If the issue is modern format support, switching endlessly among unmaintained utilities is unlikely to change that limitation.</p>
7745
7746<h3>Why does recovered code compile but act differently?</h3>
7747<p>Compilation checks language rules, not behavioral equivalence. Incorrect instruction interpretation, types, control flow, dependencies, or repairs made after recovery can all change behavior. Controlled comparison and code review are needed before any operational decision.</p>
7748
7749<h3>Can a provider recover the original comments and exact variable names?</h3>
7750<p>Those details are commonly unavailable after compilation. A recovered file can be made more readable with carefully documented names and comments, but those additions should be understood as explanatory work rather than recovered original text.</p>
7751
7752<h3>Is an account lock just another technical obstacle?</h3>
7753<p>No. Account locks, expiry checks, and similar restrictions can be part of a licence or protection scheme. A user should seek an authorised change from the vendor or rights holder, not attempt to remove the restriction through decompilation.</p>
7754
7755<h2 id="takeaway">The Practical Takeaway</h2>
7756
7757<p>Free EX4 decompilers fail on modern MT4 files primarily because their knowledge is frozen while the compiled environment changed. The resulting errors, empty shells, crashes, and plausible but broken code are technical warning signs, not evidence that the user chose the wrong menu option. Modern build compatibility, lost source context, protection, and dependencies all determine what an automated utility can reasonably deliver.</p>
7758
7759<p>For an authorised older file, a cautious free attempt may answer a narrow question quickly. For a newer, valuable, protected, or incomplete file, the more useful question is whether the recovery path includes suitable format knowledge and verification. Treat generated output as a candidate for review, preserve the original, document authority, and keep any testing controlled. That approach is more valuable than chasing a no-cost conversion that only looks successful on the screen.</p>
7760    `},{slug:"professional-ex4-recovery-methods-code-quality-review",title:"Professional EX4 Recovery Methods: A Code Quality Review for MT4 Owners",metaTitle:"Professional EX4 Recovery Methods and Code Quality Review | 2026",metaDescription:"Review the practical methods behind professional EX4 recovery, from file assessment and code reconstruction to MQL4 review, compilation checks, and safe validation.",keywords:"professional EX4 recovery methods, EX4 code quality review, recover MQ4 source, MQL4 reconstruction, EX4 decompiler service",excerpt:"This review explains how a professional EX4 recovery workflow is asse
7760ssed, what clean MQL4 output can realistically contain, and how owners can judge code quality before maintenance, migration, or audit work.",date:"March 20, 2026",dateISO:"2026-03-20",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:fp,imageAlt:"professional EX4 recovery workflow and MQL4 code quality review",tableOfContents:[{id:"purpose-before-process",title:"Start With a Defined Recovery Purpose"},{id:"what-the-file-retains",title:"What an EX4 Can and Cannot Preserve"},{id:"intake-and-file-assessment",title:"Professional Intake and File Assessment"},{id:"reconstructing-program-shape",title:"Reconstructing the Shape of a Program"},{id:"making-output-readable",title:"Making Recovered Output Readable"},{id:"reviewing-trading-specific-code",title:"Reviewing Trading-Specific Code"},{id:"validation-without-overpromising",title:"Validation Without Overpromising"},{id:"protected-or-damaged-files",title:"Protected, Unusual, and Damaged Files"},{id:"owner-checklist",title:"A Practical Owner Checklist"},{id:"service-review-verdict",title:"Review Verdict: When Professional Recovery Fits"},{id:"questions",title:"Questions About Professional EX4 Recovery"}],content:`
7761<p>A compiled EX4 can look deceptively simple. It is often one file in an MT4 folder, and it may continue to run long after the original MQ4 source has disappeared. The difficulty only becomes visible when its owner needs to fix a defect, document a strategy, assess an old Expert Advisor, or prepare a permitted migration. At that point, the question is not merely whether text can be produced from the file. The useful question is whether the recovered material gives a competent MQL4 developer a reliable starting point for the stated task.</p>
7762
7763<p>This independent review examines the working methods associated with professional EX4 recovery. It is aimed at owners and authorised users who have a legitimate reason to inspect or maintain a file. It does not treat compilation as a reversible archive process, and it does not suggest that recovery grants rights over someone else’s software. Instead, it separates the technical possibilities from the quality checks that make an output practical.</p>
7764
7765<p>That distinction helps readers compare an automated result with a managed process. A quick tool may emit MQL4-like text, but text alone can conceal wrong branches, uncertain types, temporary values, or calls that need examination. A stronger process seeks to identify those uncertainties, present the code in a form that can be reviewed, and make clear which parts still require owner testing. Readers wanting a broad overview of tools can begin with this <a href="/">ex4 decompiler</a> resource, then use the criteria below to judge whether a particular recovery path matches the importance of the file.</p>
7766
7767<img src="${fp}" alt="professional assessment of a compiled EX4 file" style="width:100%;border-radius:8px;margin:24px 0;" />
7768
7769<h2 id="purpose-before-process">Start With a Defined Recovery Purpose</h2>
7770
7771<p>Professional quality begins before a parser reads a byte. The owner should write down why access to readable code is needed and what authority supports that request. Examples include restoring a personally authored robot after a backup failure, maintaining a commissioned project where source rights were assigned, or arranging an authorised technical audit. A purchased runtime licence, a copied file, or an interesting strategy is not by itself a reason to reconstruct and reuse the code.</p>
7772
7773<p>A narrow purpose also improves the engineering work. “Locate the lot-sizing routine before adapting an owned EA” gives a reviewer a concrete target. “Make it work better” does not. The former supports a test plan, a defined delivery scope, and an easier handoff to the developer who will take responsibility for changes. It also discourages risky scope drift, such as removing account controls or republishing source that was recovered for private maintenance.</p>
7774
7775<p>The right records are mundane but valuable: the original EX4, its location and date, a copy of the agreement or permission, and a short statement of intended use. If the robot was commissioned, include the specification and handover messages. If it is the author’s own work, repository fragments, old builds, and relevant correspondence can help establish context. These materials do not change binary instructions, but they allow a recovery request to be framed accurately.</p>
7776
7777<p>
7777There is a practical reason not to skip this stage. A recovered source file may expose trade rules, vendor identifiers, endpoints, or personal settings. Access should be restricted to people who need it. Owners should also preserve an untouched original and work on copies. This is ordinary change-control practice, and it is more useful than treating recovery as a one-click shortcut.</p>
7778
7779<h2 id="what-the-file-retains">What an EX4 Can and Cannot Preserve</h2>
7780
7781<p>MQL4 compilation transforms readable statements into an executable representation for MetaTrader 4. The EX4 must retain enough operational information for the terminal to execute the program: instructions, constants, runtime strings, parameter information, references to functions, and the relationships needed to calculate and branch. That retained structure is why technical reconstruction can be possible at all.</p>
7782
7783<p>Compilation also removes or changes important authoring details. Comments, formatting, file organization, and much of the original naming are not dependable recovery targets. An output can therefore express the program’s behavior without reproducing the developer’s original explanation of why a decision was made. A variable named value_27 may be used as a stop distance, a bar index, or something more specialised. Context can support a sensible replacement name, but it cannot prove the label that existed in the original editor.</p>
7784
7785<p>Readers should regard recovered code as reconstructed engineering material, not a forensic duplicate. That framing sets appropriate expectations. It may be possible to understand an entry condition, follow a calculation, identify inputs, and modify an owned system. It is not reasonable to expect lost comments, design notes, or every historical source-level choice to reappear. The article on <a href="/blog/ex4-files-explained-for-mt4-users">what an EX4 file contains</a> gives useful background on this boundary.</p>
7786
7787<p>This boundary matters when evaluating sales language. “Compilable” and “identical source” are not interchangeable. A file can compile while still needing logic review. Conversely, a file with generic labels may contain a faithfully reconstructed calculation that becomes clear once an MQL4 developer traces its inputs and outputs. Quality is best measured against a stated purpose, not against an impossible promise of restoring every keystroke.</p>
7788
7789<img src="${O0}" alt="pattern analysis used to map recovered program components" style="width:100%;border-radius:8px;margin:24px 0;" />
7790
7791<h2 id="intake-and-file-assessment">Professional Intake and File Assessment</h2>
7792
7793<p>A careful workflow starts by identifying the file rather than assuming every EX4 is alike. The file can be copied from the relevant MT4 installation and retained unchanged. Its size, build characteristics, dependencies, and basic structure help determine what approach may be appropriate. An Expert Advisor, custom indicator, script, or library can share the EX4 extension while using different event functions and platform features.</p>
7794
7795<p>An initial assessment should also look for companion files. An EA may call a custom indicator through iCustom, rely on an included library, read files, or expect specific symbols and broker suffixes. Recovering one module does not automatically recover the implementation of a separate dependency. Naming those relationships at the outset avoids a misleading assumption that one output explains an entire trading system.</p>
7796
7797<p>At this stage, responsible providers should not imply certainty from a file upload alone. Encryption, corruption, nonstandard packaging, and heavy obfuscation can affect the amount of readable reconstruction available. The most useful response describes the known scope, any visible constraints, and what the owner can do after delivery to validate the result. A transparent process is more helpful than an unconditional result claim.</p>
7798
7799<p>It is also sensible to distinguish recovery from modification. Producing an MQ4 starting point is one task. Altering risk controls, converting platform APIs, or changing execution behavior is another engineering engagement requiring specifications and tests. Keeping those tasks separate gives the owner a clearer record of what was reconstructed and what was later changed.</p>
7800
7801<h2 id="reconstructing-program-shape">Reconstructing the Shape of a Program</h2>
7802
7803<p>Executable instructions do not arrive arranged as the tidy functions and blocks a developer expects to read. Branches transfer control between locations, calculations may use temporary storage, and compiler transformations can obscure the original layout. The main reconstruction challenge is to turn this operational map into source-level structures that a reviewer can follow without altering the apparent behavior.</p>
7804
7805<h3>Finding functions and their relationships</h3>
7806
7807<p>First, analysis identifies likely function boundaries and call relationships. Call sites, return behavior, parameter handling, and repeated instruction patterns can help distinguish an initialization routine from a helper calculation. Mapping those relationships matters because a value should be interpreted in the scope where it is created and used. When boundaries are wrong, local values can appear global, arguments can be mistaken for scratch storage, and later cleanup becomes unreliable.</p>
7808
7809<h3>Building a control map</h3>
7810
7811<p>Next, the instructions can be grouped into basic blocks and linked as possible paths. This control map makes conditional decisions and repeated work visible. A forward test with two outcomes may correspond to an if statement. A return path to an earlier test can suggest a loop. Several routes converging on a shared exit may reveal error handling or a common calculation result. The aim is not cosmetic formatting. It is to make the program’s possible paths inspectable.</p>
7812
7813<h3>Recovering structured statements carefully</h3>
7814
7815<p>Where evidence supports it, low-level jumps can be represented as familiar MQL4 structures such as if, else, for, while, or switch. That representation is easier to audit than a long sequence of labels. Yet structure should not be forced merely because it looks pleasant. An unusual branch may reflect a compiler transformation, an edge c
7815ase, or an uncertain reading. Good reconstruction preserves clarity while leaving ambiguity visible for review.</p>
7816
7817<p>Data-flow tracing provides a second check. It follows a value from assignment through calculations, comparisons, and function calls. If a temporary is written and never read, it may be removable noise. If several temporary values carry one calculation across blocks, a human reviewer can often consolidate them into a meaningful expression. This is one reason raw automated output and reviewed output can look very different even when both originate from the same instructions.</p>
7818
7819<img src="${L0}" alt="technical review of control flow and function relationships in recovered code" style="width:100%;border-radius:8px;margin:24px 0;" />
7820
7821<h2 id="making-output-readable">Making Recovered Output Readable</h2>
7822
7823<p>Readability is not a decoration added after technical work. It determines whether an owner can locate the portion of code that needs maintenance and whether another developer can safely take over. Still, readability must be honest. No process can retrieve comments that compilation discarded, and a newly assigned name should be treated as a description of likely role rather than proof of the author’s intent.</p>
7824
7825<p>Type analysis is one helpful foundation. MQL4 calls provide clues about the values they accept. A value passed as a symbol is likely string-like; one used in an arithmetic price expression may be a number; one compared with order operation constants may have an enumerated role. Consistency across assignments, comparisons, and calls narrows the possibilities. Where the evidence remains mixed, an experienced reviewer should flag the uncertainty instead of making a confident-looking but unsafe declaration.</p>
7826
7827<p>Meaningful names can then be introduced from use, not from guesswork alone. For example, a value repeatedly read from an input and applied to OrderSend volume may reasonably be labelled as a lot-size input. A counter traversing open orders may receive an index-oriented name. These labels allow a reader to navigate the file, but they should be confirmed against code behavior before a modification is based on them.</p>
7828
7829<p>Comments added during recovery should be equally clear about their origin. A note such as “reconstructed condition appears to filter current spread” is useful because it identifies an interpretation. It should never be presented as the original developer’s comment. This approach preserves the distinction between retained program evidence and later reviewer guidance.</p>
7830
7831<p>Formatting, helper extraction, and removal of redundant temporary expressions can further reduce cognitive load. They should be applied cautiously. Refactoring after recovery is a separate change and deserves version control, a diff, and tests. The first delivered version is often most useful when it remains close enough to the reconstructed structure that a reviewer can compare it with the original EX4’s observed behavior.</p>
7832
7833<h2 id="reviewing-trading-specific-code">Reviewing Trading-Specific Code</h2>
7834
7835<p>Generic decompilation knowledge is only part of the job for an MT4 robot. MQL4 has platform conventions that give code its meaning. An OrderSend call has an ordered set of arguments. Prices can require normalisation. Point size, digits, stop levels, trade context, magic numbers, and broker naming can all affect a routine that otherwise looks ordinary. A review that ignores those details may produce readable code that is misleading in practice.</p>
7836
7837<p>A trading-focused review commonly starts at event functions such as OnInit, OnTick, start, or OnCalculate, depending on the program type. From there, the reviewer can identify inputs, state initialization, indicator reads, signal conditions, order selection, and exit handling. The goal is to map the lifecycle, not to declare that a strategy is profitable or suitable for a live account.</p>
7838
7839<p>Order logic deserves close inspection because small reconstruction errors can matter. An argument in the wrong position, a price used before normalisation, or a condition inverted during restructuring can change outcomes. Reviewers can cross-check calls against documented MQL4 signatures, follow the source of each argument, and identify whether an order action is reached under the expected condition. This is also where a raw listing with opaque variable labels becomes difficult to trust.</p>
7840
7841<p>
7841Risk-related routines should be described factually. The code may calculate volume from a fixed input, account balance, available margin, prior losses, or a mixture of factors. It may contain stop-loss and take-profit arguments, or rely on external terminal settings. Those observations do not establish that the strategy manages risk appropriately. They give the owner questions to take into controlled testing and, where relevant, an independent audit.</p>
7842
7843<img src="${Q0}" alt="review of recovered MQL4 trading logic and order routines" style="width:100%;border-radius:8px;margin:24px 0;" />
7844
7845<h2 id="validation-without-overpromising">Validation Without Overpromising</h2>
7846
7847<p>Compilation is a useful checkpoint, not a final verdict. Opening the MQ4 in the relevant MetaEditor can reveal syntax, declaration, and type issues introduced during reconstruction. Resolving those problems makes the file easier to work with, but a successful compile only proves that the editor accepts the source. It does not prove that every branch matches the compiled original under every market condition.</p>
7848
7849<p>A sensible next step is controlled comparison. Use a copied terminal profile, identical inputs, the same symbol naming, and a defined historical data set where practical. Observe initialization, log messages, indicator values, order requests, and key state transitions. If the original can be run safely in a comparable test setup, compare the two programs over cases chosen to exercise normal entries, exits, no-trade conditions, and boundaries such as insufficient bars or spread filters.</p>
7850
7851<p>Backtests can contribute evidence, but they have limits. Historical data quality, modelling assumptions, broker configuration, and unavailable external dependencies can all affect results. Matching reports are encouraging rather than conclusive. Nonmatching reports are a prompt to identify whether the cause is reconstruction, environment, different data, or a feature the test does not reproduce.</p>
7852
7853<p>Owners should document each check in a simple table: scenario, inputs, expected observation, original observation if available, reconstructed observation, and follow-up. This record is more useful than a vague assurance that the code was “verified.” For a fuller testing sequence, see the guide to <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">testing decompiled MQL4 before live trading</a>.</p>
7854
7855<p>Live deployment should be the last consideration, not the first. Any recovered or modified program can contain misunderstood logic, environment assumptions, or hidden dependencies. A demo or controlled environment gives the owner time to inspect behaviour. No recovery provider can responsibly guarantee trading results, broker compatibility, or absence of risk from a reconstructed file.</p>
7856
7857<img src="${N0}" alt="compilation and controlled validation of recovered MQL4 source code" style="width:100%;border-radius:8px;margin:24px 0;" />
7858
7859<h2 id="protected-or-damaged-files">Protected, Unusual, and Damaged Files</h2>
7860
7861<p>Not every EX4 presents the same level of difficulty. Some files may be older, use uncommon constructs, depend on external components, or have been altered by a protection product. Others may simply be incomplete or corrupted. These conditions can limit the clarity or completeness of recovered output, and they are a reason for cautious communication rather than broad promises.</p>
7862
7863<p>Obfuscation can complicate the control map by adding unnecessary branches, opaque strings, or state-driven paths intended to make reading harder. A reviewer may be able to distinguish irrelevant operations from logic that affects program state, but every removal or simplification needs scrutiny. Over-aggressive cleanup can itself create a new error. Where protected content appears, the ownership and permission check becomes even more important.</p>
7864
7865<p>Damaged files create a different problem. If instructions or metadata are missing, no amount of presentation can recreate evidence that is absent. Partial recovery may still identify inputs, strings, or particular routines, but it should be delivered and described as partial. An owner deciding whether to repair, rewrite, or retire an old robot needs that candour to make an informed decision.</p>
7866
7867<img src="${F0}" alt="assessment of protected and unusual EX4 files before recovery" style="width:100%;border-radius:8px;margin:24px 0;" />
7868
7869<h2 id="owner-checklist">A Practical Owner Checklist</h2>
7870
7871<p>Before choosing a recovery option, an owner can use the following checklist to keep the task bounded and useful:</p>
7872
7873<ol>
7874<li><strong>Confirm authority.</strong> Retain ownership evidence, a source assignment, or written permission appropriate to the intended work.</li>
7875<li><strong>Preserve the original.</strong> Copy the EX4 without changing it and note its source, version, and related files.</li>
7876<li><strong>State the goal.</strong> Define whether the need is maintenance, compatibility review, authorised audit, or a permitted migration.</li>
7877<li><strong>List dependencies.</strong> Identify indicators, libraries, files, account conditions, and broker-specific assumptions.</li>
7878<li><strong>Ask what delivery includes.</strong> Clarify whether the result is a raw reconstruction, a compiled MQ4, reviewer notes, or a separate modification service.</li>
7879<li><strong>Plan validation.</strong> Arrange a controlled compile and test process before any production decision.</li>
7880<li><strong>Restrict distribution.</strong> Store the recovered material securely and share it only with authorised reviewers or developers.</li>
7881</ol>
7882
7883<p>For owners comparing routes, the homepage discussion of <a href="/">decompile ex4 to mq4</a> options is a useful companion. The important comparison is not simply price or speed. It is whether the provider describes limits, handles the file with appropriate confidentiality expectations, and supplies output that supports the documented purpose.</p>
7884
7885<h2 id="service-review-verdict">Review Verdict: When Professional Recovery Fits</h2>
7886
7887<p>The service at ForexMQ5 is positioned as a specialist option for people seeking EX4-to-MQ4 recovery from a documented, authorised use case. In a review-site assessment, that positioning makes most sense when the owner needs more than an unreviewed text export. A managed workflow can be especially useful where the file has maintenance value, the output will be handed to an MQL4 developer, or the owner needs a clearer basis for c
7887ompilation and controlled testing.</p>
7888
7889<p>ForexMQ5 should not be viewed as a substitute for permission, legal advice, or independent validation. The customer remains responsible for having the necessary rights and for decisions made with the recovered source. Likewise, a clean-looking output does not remove the need to test changes. The practical value of a professional route lies in the potential for structured assessment and readable reconstruction, not in a guarantee about every file or future trading performance.</p>
7890
7891<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
7892  <h3 style="margin-top:0;">Considering a Documented EX4 Recovery Project?</h3>
7893  <p>ForexMQ5 is reviewed as a professional option for authorised owners who need an EX4 recovery starting point for maintenance, analysis, or controlled validation. Keep the original file and supporting records before making a request.</p>
7894  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
7895</div>
7896
7897<h2 id="questions">Questions About Professional EX4 Recovery</h2>
7898
7899<h3>Will recovered MQ4 have the original variable names and comments?</h3>
7900<p>Not reliably. Compilation generally removes comments and may not retain original source-level names. A reviewer can assign descriptive labels based on documented use, but those labels are reconstructed guidance rather than recovered author notes.</p>
7901
7902<h3>Does a successful compile prove the recovered EA is identical?</h3>
7903<p>No. It confirms that the source is accepted by the compiler. Behaviour still needs controlled comparison across relevant inputs and conditions, particularly before code is modified or considered for use on an account.</p>
7904
7905<h3>Can protected or damaged EX4 files always be recovered?</h3>
7906<p>No. Protection, corruption, missing dependencies, and unusual build characteristics can limit what is practical to reconstruct. A responsible assessment should explain uncertainty and avoid promising full recovery before the file has been examined.</p>
7907
7908<h3>Why use a professional option instead of a free utility?</h3>
7909<p>A free utility may be adequate for exploration of an uncomplicated, authorised file. A professional process can be more appropriate when code readability, MQL4-specific review, confidentiality expectations, and a structured validation handoff matter to the owner’s stated task.</p>
7910`},{slug:"recover-custom-mt4-indicator-source-from-ex4",title:"Custom MT4 Indicator Source Recovery: A Practical EX4 to MQ4 Review Guide",metaTitle:"Recover Custom MT4 Indicator Source from EX4 to MQ4 | 2026 Guide",metaDescription:"A practical guide to recovering custom MT4 indicator source from an EX4 file. Learn about buffers, calculation loops, val
7910idation, ownership checks, and professional review options.",keywords:"recover custom mt4 indicator source, ex4 to mq4 indicator recovery, custom indicator ex4, mq4 indicator source code, mt4 indicator decompiler",excerpt:"A compiled custom MT4 indicator can be difficult to maintain, port, or verify when its MQ4 source has disappeared. This review guide explains what recovery can reveal, how indicator code differs from an EA, and how to validate a recovered file responsibly.",date:"June 3, 2026",dateISO:"2026-06-03",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:Qs,imageAlt:"custom MT4 indicator EX4 source recovery to MQ4",tableOfContents:[{id:"indicator-recovery-context",title:"Why a Missing Indicator Source File Matters"},{id:"indicator-anatomy",title:"What Makes an Indicator Different from an EA"},{id:"rights-and-file-check",title:"Check Rights and Preserve the Original File"},{id:"recoverable-elements",title:"What an EX4 Recovery Can and Cannot Restore"},{id:"reading-the-calculation",title:"Reading Buffers, Plots, and Calculation Loops"},{id:"validation-plan",title:"A Safe Validation Plan for Recovered MQ4"},{id:"maintenance-decisions",title:"Maintenance, Migration, and Integration Decisions"},{id:"professional-review",title:"Reviewing a Professional Recovery Option"},{id:"questions",title:"Common Questions About Indicator Recovery"},{id:"next-step",title:"The Sensible Next Step"}],content:`
7911<p>A custom MT4 indicator can become part of a trading routine so gradually that its source file is forgotten. It may mark a chart with arrows, calculate a volatility band, color a trend line, or provide values used by an Expert Advisor. Years later, the indicator still loads as an EX4, but the MQ4 file is gone after a computer replacement, a failed drive, an expired contractor relationship, or an incomplete archive. That is when indicator source recovery becomes more than a technical curiosity.</p>
7912
7913<p>Compiled indicators deserve their own discussion. They are created in the same MetaEditor environment as trading robots, yet their job is usually to calculate and display information rather than send orders. A usable recovery project must therefore look beyond whether a file opens in the editor. It should ask whether the plots match, whether buffers are aligned with bars, whether alerts have safe behavior, and whether the requester has the right to inspect and modify the work.</p>
7914
7915<p>This independent review guide examines that process from the perspective of a trader, developer, or business maintaining an indicator it is entitled to use. It does not treat recovered code as a shortcut for copying a vendor's method or defeating licence controls. Instead, it provides a practical framework for preserving the original EX4, assessing output, and deciding whether a professional <a href="/">ex4 to mq4 decompiler</a> route is appropriate for a legitimate maintenance need.</p>
7916
7917<img src="${Fu}" alt="custom MT4 indicator files in the MetaTrader indicators folder" style="width:100%;border-radius:8px;margin:24px 0;" />
7918
7919<h2 id="indicator-recovery-context">Why a Missing Indicator Source File Matters</h2>
7920
7921<p>An indicator can appear simple on a chart while containing a substantial amount of logic. A multi-timeframe tool may coordinate data from several periods. A session indicator may account for broker server time and daylight-saving changes. A signal tool may combine moving averages, price ranges, filters, and notification rules. If only the compiled file remains, even a small requested change can become impractical because there is no clear way to inspect the original assumptions.</p>
7922
7923<p>Source access matters for routine engineering tasks. A developer may need to update obsolete function calls, repair a calculation after a platform update, rename inputs for clarity, or remove an alert that is no longer wanted. A team using a private chart template may need to understand why an indicator draws differently on two brokers. An owner moving a strategy from MT4 to MT5 needs source as a starting point, not merely a file that happens to run in an older terminal.</p>
7924
7925<p>There is also a verification reason. A chart signal is not self-explanatory. The visible arrow does not reveal whether it was placed only after a candle closed, whether it can move after a recalculation, or which price series feeds the condition. Looking at code can help an authorised owner distinguish a stable historical marker from a calculation that changes with later ticks. It cannot prove that a strategy will be profitable, and it should not be represented as a performance guarantee. It can, however, turn a black-box display into an engineering artifact that can be examined and tested.</p>
7926
7927<p>Recovery is not always the first or best route. The original author may still have a repository copy, an email attachment, or a supported upgrade available. A purchased product may be licensed only for use in compiled form. When an authorised source handover is possible, that is normally cleaner than any reverse-engineering process. The useful question is whether the source is truly unavailable and whether the intended scope is repair, preservation, audit, or another defensible purpose.</p>
7928
7929<h2 id="indicator-anatomy">What Makes an Indicator Different from an EA</h2>
7930
7931<p>Both Expert Advisors and custom indicators are commonly written in MQL4 and compiled into EX4 files. The shared extension can hide an important difference in runtime role. An EA normally responds to price events while managing orders, positions, and trade permissions. An indicator is generally asked to calculate values for chart bars and expose those values as plots, colors, levels, or data that another program can call.</p>
7932
7933<p>That distinction shapes the code that needs attention after recovery. Indicator source usually declares drawing settings and data buffers near the top of the file. Buffers are arrays that hold one calculated value for each bar. MetaTrader uses them to draw a line, histogram, arrow, or other visual element. The source often associates each buffer with an index through <code>SetIndexBuffer()</code>, and then configures style, width, label, draw start, empty value, or arrow code through related functions.</p>
7934
7935<p>The main calculation routine is another indicator-specific feature. Modern MQL4 indicators commonly use <code>OnCalculate()</code>, while older files may use <code>start()</code> or legacy initialization patterns. The routine receives price arrays, knows how many bars are available, and usually decides where to begin recalculation by considering <code>prev_calculated</code> or an equivalent counter. A recovered file may compile while still handling this boundary incorrectly, which is why chart comparison is more meaningful than compilation alone.</p>
7936
7937<p>Indicators also often depend on context outside their own file. They can call built-in functions such as <code>iMA()</code>, <code>iRSI()</code>, <code>iHighest()</code>, or <code>iCustom()</code>. They may reference another indicator by filename, use chart objects for labels, or include a library that is no longer present. A source review should list these dependencies before anyone assumes the recovered file is self-contained.</p>
7938
7939<p>For a broader explanation of compiled MT4 files and their relationship to source, the site has a useful companion article on <a href="/blog/ex4-files-explained-for-mt4-users">what an EX4 file is</a>. That background helps clarify why an EX4 can run normally even though the editing information available in the original MQ4 is no longer intact.</p>
7940
7941<h2 id="rights-and-file-check">Check Rights and Preserve the Original File</h2>
7942
7943<p>Technical capability is not permission. The most straightforward case is an indicator written by the requester, or a commissioned project accompanied by a clear assignment or written right to re
7943ceive and modify its source. A licence to run a commercial indicator is different from ownership of the underlying code. Before a recovery request, the responsible party should review the development agreement, invoice, marketplace terms, email permissions, and any source-delivery clause.</p>
7944
7945<p>A narrow statement of purpose helps keep the work controlled. For example, “restore source for an internally commissioned indicator after the repository was lost” describes a maintenance need. “Extract a seller's signals for a new product” does not. Requests to remove account locks, expiry checks, or vendor restrictions raise separate legal and ethical concerns and should not be reframed as ordinary indicator maintenance.</p>
7946
7947<p>Preservation begins with the original file. Copy the EX4 to read-only storage, note the filename and location from which it was obtained, and record a checksum where the project is significant. Keep screenshots of the indicator's input settings, its chart appearance, and any alert behavior before changing anything. These records provide a baseline when the recovered MQ4 is later compiled and compared.</p>
7948
7949<p>The project folder should also contain entitlement evidence and a short change log. It is helpful to re
7949cord the terminal build, broker, symbol, timeframe, template, and external indicators loaded on the chart. An indicator that appears broken after recovery may instead rely on a missing font, a suffix in a broker symbol, insufficient history, or a different time zone. Good records prevent those environmental differences from being mistaken for a source-recovery fault.</p>
7950
7951<img src="${Qu}" alt="comparison of EX4 indicator file and recovered MQ4 source code" style="width:100%;border-radius:8px;margin:24px 0;" />
7952
7953<h2 id="recoverable-elements">What an EX4 Recovery Can and Cannot Restore</h2>
7954
7955<p>EX4 recovery aims to reconstruct readable MQL4 from compiled program instructions. The quality and completeness of the result depend on the file's build, compiler behavior, protection measures, dependencies, and the method used. It is more accurate to view the result as a recoverable engineering starting point than as a perfect time capsule of the original editor file.</p>
7956
7957<p>Commonly useful material can include program flow, arithmetic, conditional branches, calls to platform functions, input parameters, visible text, numeric constants, buffer use, and much of the calculation logic. These elements can be enough for an experienced MQL4 developer to understand the design, compile a working version, and perform authorised maintenance. An indicator's output layout often provides additional clues because buffer count and draw styles can be compared directly on a chart.</p>
7958
7959<p>Some original information may not survive compilation in the form a human expects. Meaningful variable names can be reduced to generic labels. Comments, formatting, blank lines, original file organization, and the rationale behind a formula are usually not available. A recovered loop may perform the same mathematical operation without explaining why a particular period or threshold was chosen. That means cleanup is an important part of recovery, not evidence that the output failed.</p>
7960
7961<p>It is also possible to encounter a file that requires more analysis than expected. A current-format EX4 is not equivalent to an early historical build. Tools designed around old formats can produce code-like text that compiles only after extensive changes or, worse, logic that appears credible while calculating the wrong result. An authorised owner should favor a method with an honest explanation of scope and should test output against the original rather than trusting a green compiler message.</p>
7962
7963<p>Recovery cannot restore operational certainty by itself. It does not establish rights ownership, recreate a missing external DLL, supply unavailable market history, or guarantee compatibility with MT5. It also does not validate trading results. These limits are useful because they set a realistic review standard: readable code, identified dependencies, reproducible indicator behavior, and documented changes are stronger outcomes than an unsupported claim of exact restoration.</p>
7964
7965<h2 id="reading-the-calculation">Reading Buffers, Plots, and Calculation Loops</h2>
7966
7967<p>The first reading pass should identify what the indicator promises to display. Locate the property declarations, buffer arrays, and buffer registrations. Then build a small map: buffer zero might be a main line, buffer one might be a signal line, and later buffers might hold arrow prices or temporary calculations. The display name is useful but not conclusive. Follow where values are assigned inside the calculation loop.</p>
7968
7969<p>Next, inspect the empty-value convention. Many indicators set unused buffer positions to <code>EMPTY_VALUE</code> so MetaTrader does not draw a mark. If a recovered source writes zero instead, a chart may show a misleading line at the bottom or produce arrows on every bar. The loop should be checked for initialization of older bars and for the conditions that explicitly clear values when a signal does not exist.</p>
7970
7971<p>Array direction matters just as much. Time series arrays frequently treat index zero as the newest bar, whereas ordinary arrays may be arranged differently. Calls such as <code>ArraySetAsSeries()</code> indicate that choice. A reversed loop can create a plot that looks roughly plausible but is shifted, incomplete, or based on future bars. Compare the loop boundary with the indicator's required lookback period and with every use of an offset such as <code>i + 1</code> or <code>i - 1</code>.</p>
7972
7973<p>Chart objects deserve separate attention. Some indicators draw text, vertical lines, rectangles, or arrows through <code>ObjectCreate()</code> rather than through a buffer. Those objects can persist after an indicator is removed, use names constructed from symbol and time, or be repeatedly recreated on each tick. An owner maintaining the recovered file should verify object naming and deletion rules in a test chart to avoid clutter or accidental interference with other tools.</p>
7974
7975<p>Alerts are another area where a code review is valuable. A sound implementation normally avoids repeating the same notification on every tick and distinguishes the current bar from a closed bar. Test email, push, sound, and popup calls with harmless settings where possible. An alert condition that references bar zero may be appropriate for a live early warning, but it should be documented because that signal can change before the candle closes.</p>
7976
7977<img src="${Wu}" alt="understanding indicator buffer structure in recovered MQ4 code" style="width:100%;border-radius:8px;margin:24px 0;" />
7978
7979<h2 id="validation-plan">A Safe Validation Plan for Recovered MQ4</h2>
7980
7981<p>Validation should happen in a separate workspace, never by replacing the only working EX4 on an active chart. Install the recovered MQ4 under a distinct test name, compile it in MetaEditor, and save all warnings and errors. Compilation establishes syntax compatibility, but it does not establish behavioral equivalence. Treat it as the first checkpoint.</p>
7982
7983<ol>
7984<li><strong>Build an isolated copy.</strong> Keep the original EX4 and its template unchanged. Use a duplicate terminal profile or a clearly labeled test folder for the recovered source.</li>
7985<li><strong>Record the original display.</strong> Capture the same symbol, timeframe, zoom, inputs, and visible history for the original indicator. Include examples of normal plots, arrows, and alerts.</li>
7986<li><strong>Compile and identify dependencies.</strong> Resolve missing includes, called indicators, fonts, or libraries only when the requester has a legitimate copy or permission to use them. Do not substitute unknown files casually.</li>
7987<li><strong>Compare historical output.</strong> Apply the original and recovered versions separately with identical inputs. Check line positions, colors, object placement, buffer values in the Data Window, and the first bar on which a signal appears.</li>
7988<li><strong>Observe live recalculation.</strong> Use a demo or non-production chart to see how both versions behave while ticks arrive, history refreshes, the timeframe changes, and the terminal restarts.</li>
7989<li><strong>Document every correction.</strong> Rename generic variables, add comments, and make changes in small commits. Each correction should state the observed issue and how the comparison supported the fix.</li>
7990</ol>
7991
7992<p>A useful comparison does not rely only on screenshots. The Data Window can reveal exact buffer values at selected bars. A developer can also add temporary diagnostic output to the test version, then remove it after confirming loop ranges and conditions. If the indicator calls another custom tool through <code>iCustom()</code>, compare the called indicator's parameters and filename carefully. A missing parameter can change output without producing an obvious runtime error.</p>
7993
7994<p>Do not attach a newly recovered indicator to a live automated strategy merely because the visual result looks familiar. If an EA reads its buffers, confirm buffer index, shift, empty value, and timing assumptions. The site's guide to <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">testing decompiled MQL4 before live use</a> provides a related checklist for moving from a recovered artifact to controlled testing.</p>
7995
7996<h2 id="maintenance-decisions">Maintenance, Migration, and Integration Decisions</h2>
7997
7998<p>Once an authorised recovery has been validated, the source should be treated like any other maintained codebase. Give the file a descriptive name, replace generic identifiers gradually, document inputs and buffer meanings, and keep the original recovered version under version control. This creates a clear separation between what was reconstructed and what the current maintainer later changed.</p>
7999
8000<p>Common maintenance work includes adjusting an input range, changing a plotted style, correcting a symbol naming assumption, improving object cleanup, or replacing an outdated event handler. Each change should be tested against a stated objective. For example, a request to make an arrow less noisy is a strategy-design change, not a neutral restoration step. It deserves new historical and forward observation instead of being presented as a technical repair.</p>
8001
8002<p>Porting to MT5 is a separate development project. MQL5 has different data access patterns, indicator handles, and order-related conventions. Some straightforward calculations port cleanly, while a multi-timeframe or object-heavy indicator may need a redesign. Recovered MQ4 can make the logic understandable, but it does not make an automatic conversion reliable. A maintainer should first establish a stable MT4 reference output, then use that reference to evaluate the MT5 version.</p>
8003
8004<p>Integration into an EA requires similar discipline. It can be tempting to copy an indicator formula 
8004into a robot so the robot no longer calls <code>iCustom()</code>. That may simplify distribution, but it changes the testing surface and can introduce timing differences. Verify that the EA reads only closed-bar signals if that was the intended design, and confirm that any trade decisions remain subject to independent risk controls. An indicator is an information tool, not a promise about market direction.</p>
8005
8006<h2 id="professional-review">Reviewing a Professional Recovery Option</h2>
8007
8008<p>For an owner with a documented need, a specialist service can be a more practical choice than trying unknown downloads or relying on a utility built for a different EX4 format. ForexMQ5 is positioned on this review site as a professional EX4-to-MQ4 recovery option for indicators as well as EAs, with stated pricing from $50 per file. The relevant value is not a claim that every output requires no review. It is the possibility of a focused recovery process followed by normal engineering validation.</p>
8009
8010<p>In assessing any provider, an authorised requester should ask about accepted file types, expected deliverables, confidentiality practices, build compatibility, treatment of dependencies, and how the provider handles requests that appear to seek copying or restriction removal. A responsible service should not imply that a technical process overrides copyright, contract terms, or platform licensing. The customer remains accountable for the authority to request the work and for use of the delivered material.</p>
8011
8012<p>The review-site position is that a professional path is best considered after the ownership record and intended purpose are clear. It is particularly relevant where an indicator supports an internal workflow, a contractor is unavailable, or a lost source file prevents ordinary maintenance. It is not a substitute for written vendor permission when the indicator was obtained under a restrictive licence.</p>
8013
8014<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
8015  <h3 style="margin-top:0;">Need an Authorised Indicator Recovery Review?</h3>
8016  <p>ForexMQ5 is reviewed as a specialist option for owners who can document a legitimate source recovery, maintenance, or authorised audit purpose. Preserve the EX4 and relevant rights records before requesting an assessment.</p>
8017  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
8018</div>
8019
8020<h2 id="questions">Common Questions About Indicator Recovery</h2>
8021
8022<h3>Will recovered MQ4 have the original variable names and comments?</h3>
8023<p>Usually not in full. Compilation commonly removes comments, formatting, and much of the human naming that made the source easy to read. A recovery may preserve enough structure to understand the code, but variable renaming and documentation are normal maintenance tasks afterward.</p>
8024
8025<h3>Does a compiling file prove it matches the original indicator?</h3>
8026<p>No. Compilation proves that MetaEditor accepts the syntax. Matching behavior requires comparison of buffers, plots, objects, inputs, and live recalculation under the same chart conditions. A small index or empty-value error can compile successfully and still alter displayed signals.</p>
8027
8028<h3>Can a purchased indicator be recovered for personal use?</h3>
8029<p>Personal use is not an automatic source-code right. The answer depends on ownership, licence terms, permissions, local law, and the purpose of the work. A purchaser should read the agreement and seek written consent when rights are unclear, especially before modifying or sharing any recovered material.</p>
8030
8031<h3>Can recovery remove a vendor's account or expiry restriction?</h3>
8032<p>That is not an ordinary maintenance objective. Such restrictions may be part of a licence or technological protection arrangement. The appropriate route is to contact the vendor for an authorised change, replacement, or renewed licence.</p>
8033
8034<h3>Is an old free decompiler adequate for an indicator EX4?</h3>
8035<p>It may have limited educational value for some older formats, but it should not be assumed suitable for a modern file. Plausible-looking output can still contain incorrect function calls, variable types, or calculation logic. Any authorised output needs systematic validation against the original indicator.</p>
8036
8037<h3>What should be retained after the project is complete?</h3>
8038<p>Keep the untouched EX4, entitlement records, recovered baseline, version history, dependency list, comparison screenshots, and notes on corrections. These materials make later maintenance easier and show the scope of the work if questions arise.</p>
8039
8040<h2 id="next-step">The Sensible Next Step</h2>
8041
8042<p>Recovering a custom indicator's MQ4 can restore maintainability when the EX4 is the only surviving copy, but a successful project is broader than convert
8042ing one extension to another. It starts with rights and preservation, continues through buffer and loop analysis, and ends with careful comparison in a controlled environment. The final source should be documented, versioned, and used only within the permissions that apply to it.</p>
8043
8044<p>For readers evaluating options, the practical sequence is clear: locate the original source or obtain authorisation first, preserve the compiled file and a chart baseline, choose an appropriate recovery path, and validate every important output condition before changing a workflow. Where the record supports a legitimate request, the reviewed <a href="/">mql4 decompiler</a> option at ForexMQ5 can be considered alongside that disciplined engineering process.</p>
8045
8046<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
8047  <h3 style="margin-top:0;">Compare a Professional Indicator Recovery Option</h3>
8048  <p>ForexMQ5 is presented as the primary professional option in this review for authorised EX4 indicator recovery projects that need a readable MQ4 starting point for maintenance and validation.</p>
8049  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
8050</div>
8051`},{slug:"prop-firm-ea-source-code-review-preparation",title:"Prop Firm EA Source Code Review: A Practical Compliance Preparation Guide",metaTitle:"Prop Firm EA Source Code Review Guide for MT4 Traders | 2026",metaDescription:"Prepare an MT4 Expert Advisor for a prop firm source code review. Learn what to document, how to assess risk controls, and what to do when only an EX4 file is available.",keywords:"prop firm EA source code review, MT4 EA compliance, funded account algorithm review, EX4 source code audit, prop firm EA approval",excerpt:"A source code request does not have to derail a funded-account plan. This practical guide helps MT4 traders prepare an EA review package, identify the questions a risk team may raise, and handle an EX4-only file responsibly.",date:"June 10, 2026",dateISO:"2026-06-10",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:Zu,imageAlt:"prop firm ea compliance source code review scales",tableOfContents:[{id:"request-means",title:"What a Source Code Request Usually Means"},{id:"policy-first",title:"Read the Firm Policy Before Preparing Files"},{id:"review-map",title:"A Review Map for an MT4 Expert Advisor"},{id:"risk-controls",title:"Risk Controls Worth Explaining Clearly"},{id:"hidden-behavior",title:"Connections, Conditions, and Hidden Behavior"},{id:"ex4-only",title:"When the Trader Only Has an EX4 File"},{id:"submission-pack",title:"Build a Useful Compliance Submission Pack"},{id:"test-and-record",title:"Test, Version, and Record Changes"},{id:"service-assessment",title:"Assessing a Professional Recovery Option"},{id:"questions",title:"Common Questions About EA Reviews"},{id:"conclusion",title:"A Calmer Route to EA Approval"}],content:`
8052<p>A request for Expert Advisor source code can feel like a last-minute obstacle when a trader is preparing to use automation on a funded account. In practice, it is usually a request for clarity. A prop firm needs to understand the operational risks of a program that may place orders, change position size, react to news, or communicate with an external service. The request is not proof that an EA is unsafe, and it is not a promise that a review will lead to approval. It is an opportunity to show how the tool works and whether it fits the firm’s written rules.</p>
8053
8054<p>This guide takes a practical, review-site approach to prop firm EA compliance. It focuses on the preparation steps a trader can control: reading the actual policy, identifying the exact EA version, describing risk behavior in plain language, preserving evidence of authority to inspect the code, and responding honestly to uncertainties. Firm policies differ, so no article can replace the instructions issued by a particular firm. A trader should treat the firm’s current dashboard, agreement, and support response as the controlling source.</p>
8055
8056<p>The central problem is often simple. MT4 users commonly receive a compiled EX4 because it is the normal file used by the terminal. The source MQ4 may remain with the original developer, be stored in an old repository, or have been lost. A compliance team may instead ask for readable code, a developer attestation, or an independent technical explanation. The right next step depends on the policy and on the trader’s legal right to access or recover the code. It should never be assumed that possession of an EX4 grants a right to re
8056construct, alter, or distribute its source.</p>
8057
8058<img src="${Yu}" alt="hidden ea logic revealed through source code review for prop firm compliance" style="width:100%;border-radius:8px;margin:24px 0;" />
8059
8060<h2 id="request-means">What a Source Code Request Usually Means</h2>
8061
8062<p>Funded-account programs set limits around loss, daily drawdown, trading methods, execution patterns, and sometimes copying or third-party signals. Automation can interact with every one of those limits. An EA may be modest in design, yet a small setting change can turn fixed sizing into balance-based sizing, extend a recovery sequence, or increase the number of simultaneous trades. A reviewer needs enough information to determine whether the program can be used within the firm’s conditions.</p>
8063
8064<p>Source code is one form of evidence, not the only possible form. Depending on the firm, the request may be aimed at one or more of the following questions:</p>
8065
8066<ul>
8067<li>Does the program place and close orders according to the trader’s stated strategy?</li>
8068<li>Can it increase exposure after losses or open several correlated positions at once?</li>
8069<li>Does it use outside signals, account data, remote commands, or copied trades?</li>
8070<li>Does it behave differently in tester mode, on a demo account, or under particular account conditions?</li>
8071<li>Can the trader identify the author, version, settings, and authority to use the software?</li>
8072<li>Does the program contain functions that conflict with a published restriction, such as prohibited latency practices or trading around restricted events?</li>
8073</ul>
8074
8075<p>Those questions are sensible risk-management questions. They do not require a reviewer to predict profitability, and no compliance review should be represented as proof that an EA will produce a particular return. A clean review package explains mechanics, limits, and dependencies. It does not sell a backtest or make broad claims about future trading results.</p>
8076
8077<p>It is also helpful to separate approval of an EA from approval of a strategy. A firm can permit automation while requiring a trader to stay within drawdown and execution rules. Conversely, a strategy can be understandable but still be unsuitable under a particular program’s terms. The most useful submission therefore connects code behavior to the specific rules rather than relying on generic statements such as “low risk” or “fully compliant.”</p>
8078
8079<h2 id="policy-first">Read the Firm Policy Before Preparing Files</h2>
8080
8081<p>Before sending a file to anyone, capture the exact requirement. Look for the current terms, FAQ, challenge rules, funded-account rules, and messages from the compliance team. Policies change, and a forum summary may be outdated or apply to a different account type. Write down the deadline, the recipient, accepted file formats, whether an NDA is available, and whether the firm wants source, an audit report, parameter screenshots, a declaration, or all of those items.</p>
8082
8083<p>A short clarification request can prevent unnecessary disclosure. For example, a trader can ask whether a developer may submit source directly under confidentiality, whether a code review letter is acceptable, and whether the firm needs the full project or only the trade-management module. That question is not an attempt to evade review. It helps the trader share the minimum material needed while respecting a developer’s legitimate intellectual-property concerns.</p>
8084
8085<p>Next, make a policy-to-evidence table. In one column, quote or summarize each relevant rule. In the next, list the source location, test record, setting, or statement that addresses it. A rule about daily loss may point to a platform-level stop and to the EA’s own order-sizing method. A restriction on third-party signals may point to a list of libraries, URLs, and input parameters. This format makes gaps visible before the package reaches a reviewer.</p>
8086
8087<p>Do not infer a permission from silence. If a policy does not mention an automation method, it may still be covered by a broader provision. Similarly, an EA’s name or vendor description does not establish compliance. The trader should ask the firm where the language is unclear and preserve the written response. Clear questions early are usually less disruptive than a dispute after trades have been placed.</p>
8088
8089<h2 id="review-map">A Review Map for an MT4 Expert Advisor</h2>
8090
8091<p>A readable MQ4 project can be intimidating because it includes platform events, indicator calls, order functions, inputs, error handling, and utility routines. A productive review does not begin by reading every line equally. It begins with a map of the program. The map lets a non-developer describe the EA accurately and lets a technical reviewer move directly to the functions that affect trading behavior.</p>
8092
8093<p>Start with the identity block. Record the EA name, file name, version string, compilation date if available, MT4 terminal build, magic number, and a checksum for the EX4 that will actually be attached to the account. A checksum is useful because two files with the same visible name can contain different logic. Keep the original file unchanged and work on a copy when testing or preparing source.</p>
8094
8095<p>Then identify the event functions. In MQL4, <code>OnInit</code> or older initialization functions often load settings and check the environment. <code>OnTick</code> commonly contains the recurring decision process, while timer or deinitialization handlers can perform scheduled tasks and cleanup. The presence of a function alone proves little. Its calls, conditions, and side effects are what matter. A review note should state what happens at startup, on each tick, and when a trade is opened or closed.</p>
8096
8097<p>After that, trace four paths: entry, sizing, exit, and emergency behavior. For each path, answer a plain-language question. What allows a new entry? How is the volume selected? What closes or modifies a position? What happens after errors, a loss sequence, a spread spike, or a disconnection? A reviewer can compare those answers with the relevant functions rather than hunting through the entire project.</p>
8098
8099<p>For background on the difference between compiled and readable program files, the site’s <a href="/blog/ex4-files-explained-for-mt4-users">guide to what an EX4 file is</a> gives useful context. That technical distinction matters here because the trading terminal can run an EX4 without exposing the logic that a compliance reviewer may 
8099need to assess.</p>
8100
8101<h2 id="risk-controls">Risk Controls Worth Explaining Clearly</h2>
8102
8103<p>Risk language is often where an otherwise good submission becomes vague. Labels such as “conservative,” “smart recovery,” or “adaptive lot size” are marketing terms unless the underlying rule is described. A compliance team needs the actual mechanism and the maximum exposure it can create under the allowed settings.</p>
8104
8105<h3>Position sizing and scaling</h3>
8106
8107<p>List every input that affects lots, including fixed lots, risk percentage, minimum and maximum volume, multipliers, and balance or equity thresholds. Explain the order in which those settings apply. If a multiplier can activate after a loss, after a basket closes, or when a signal repeats, say so plainly. A loss-responsive sizing pattern may be allowed, restricted, or prohibited depending on the firm. Omitting it is more damaging than describing it accurately.</p>
8108
8109<h3>Stops, targets, and total exposure</h3>
8110
8111<p>Document whether each order receives a stop loss and take profit at entry, whether those values can later move, and whether the EA can close all positions based on account equity or time. Also explain pending orders, hedged positions, grids, and the maximum count of open orders. An individual trade may appear small while the combined exposure of several symbols or levels is material. The package should show the worst-case configuration the trader intends to use, not only the default values.</p>
8112
8113<h3>Trading windows and market filters</h3>
8114
8115<p>Many EAs limit activity by session, day, spread, volatility, or news time. These filters can be prudent operational controls, but they need an explanation. Identify the time zone used by the EA and whether it depends on broker server time, local time, or an external calendar. If the program trades during events or disables itself around them, match that behavior to the firm’s policy rather than making an assumption based on the feature’s name.</p>
8116
8117<h3>Account-level safeguards</h3>
8118
8119<p>Some programs contain a daily-loss cutoff, an equity stop, a maximum-trades switch, or a manual emergency input. Others rely entirely on the trader and the prop firm’s platform controls. Either arrangement should be stated accurately. Internal safeguards can fail because of configuration errors, terminal outages, or code defects. They are helpful information, not a substitute for monitoring an account or for the firm’s own limits.</p>
8120
8121<img src="${Ju}" alt="compliance detective catching hidden ea logic during prop firm review" style="width:100%;border-radius:8px;margin:24px 0;" />
8122
8123<h2 id="hidden-behavior">Connections, Conditions, and Hidden Behavior</h2>
8124
8125<p>A serious review looks beyond order placement. Inspect import statements, included files, global variables, file operations, web requests, DLL calls, sockets where applicable, and code that reads account or terminal information. These features are not automatically improper. An EA might query a licensing server, write a log, collect a news value, or load a custom indicator. The concern is whether the behavior is disclosed, necessary, and compatible with the firm’s rules and security expectations.</p>
8126
8127<p>Describe external dependencies with enough detail for a reviewer to understand their role. Name the library or endpoint if disclosure is permitted, state whether it can send instructions that alter trading, and explain what happens if the connection fails. If a developer supplies a separate statement under NDA, reference that arrangement rather than publishing confidential credentials, URLs, or proprietary data. Passwords, account identifiers, and API tokens do not belong in a compliance submission.</p>
8128
8129<p>Conditional logic deserves the same care. Conditions based on account number, broker name, symbol suffix, date, spread, or terminal state may have ordinary uses. They can also change the EA’s behavior in ways a reviewer needs to understand. Tester checks such as <code>IsTesting()</code> should be documented when they affect calculations, trading permission, logging, or parameter selection. The mere presence of a test check is not a verdict. The question is whether live and test behavior remains honestly represented.</p>
8130
8131<p>A compliance review should avoid accusations based solely on patterns. A grid is not automatically deceptive, and an external 
8131call is not automatically malicious. Good review notes distinguish observed facts from interpretations. For example: “The program may open up to three additional orders when price moves by the configured interval” is a verifiable description. “The program is safe” is a conclusion that cannot be established from a single code excerpt.</p>
8132
8133<h2 id="ex4-only">When the Trader Only Has an EX4 File</h2>
8134
8135<p>The best outcome is usually to obtain the original source from its author or rights holder. A developer can provide source under an NDA, supply a narrowly scoped technical explanation, or submit an audit to the firm directly. That route preserves the author’s control over the work and can produce more reliable context than reconstructed code. A trader should first check purchase records, agreements, email archives, version-control access, and old computers before assuming the source is unavailable.</p>
8136
8137<p>If the original source cannot be found, the next issue is authority. A commissioned EA, an employment project, a marketplace purchase, and a file received from another trader have different ownership and license implications. Payment for access to an EA does not necessarily transfer the right to inspect, reconstruct, modify, or share source. A trader should preserve contracts, invoices, written permission, and the exact reason recovery is needed. Where the rights are disputed or unclear, qualified local legal advice is more appropriate than technical shortcuts.</p>
8138
8139<p>Readers considering an <a href="/">ex4 to mq4 decompiler</a> should also set realistic expectations. Decompiled output may need manual cleanup, may not restore original comments or meaningful variable names, and may not reproduce every project artifact. It should be reviewed and compiled in a controlled environment before it is presented as an explanation of the live EA. A recovered file is an engineering starting point, not automatic proof of ownership, approval, or trading suitability.</p>
8140
8141<p>For a rights holder with a documented maintenance or compliance purpose, ForexMQ5 is reviewed on this site as a professional EX4-to-MQ4 recovery option. The review position is limited: the service can be considered where the requester is entitled to seek recovery and needs readable material for a legitimate review. The customer remains responsible for the accuracy of that representation and for how any output is used. No recovery service should be used to bypass a vendor restriction, copy a commercial strategy, or distribute someone else’s work.</p>
8142
8143<h2 id="submission-pack">Build a Useful Compliance Submission Pack</h2>
8144
8145<p>Compliance teams benefit from an organized package because they may be reviewing many files and may not be MQL4 specialists. The goal is not to overwhelm the reviewer with every historical test. It is to make the relevant facts easy to confirm and easy to question.</p>
8146
8147<ol>
8148<li><strong>Include an identity sheet.</strong> State the EA name, version, file checksum, intended account, symbols, time frames, and the date the package was prepared. Identify the author or vendor where appropriate.</li>
8149<li><strong>Add an authority statement.</strong> Briefly explain the trader’s right to use and, if applicable, provide the material. Attach only the supporting records the firm requests and redact private payment or personal details where possible.</li>
8150<li><strong>Provide the exact settings.</strong> Include input screenshots or an exported preset for the configuration intended for the funded account. Explain any setting that changes maximum exposure.</li>
8151<li><strong>Write a strategy summary.</strong> In plain language, cover signals, entries, exits, sizing, limits, sessions, and outside dependencies. Link each major statement to a function or source section when source is supplied.</li>
8152<li><strong>Answer the firm’s rules one by one.</strong> Do not use a generic checklist when the firm has supplied its own. Note uncertainties rather than guessing.</li>
8153<li><strong>State testing limits.</strong> Explain what was tested, on what environment, and what was not tested. Backtests and demos can inform a review, but they cannot guarantee live execution or future outcomes.</li>
8154</ol>
8155
8156<p>Keep a private copy of what was sent, including file hashes and correspondence. If a reviewer asks for an updated build, treat it as a new version rather than silently replacing a file. This protects both sides from confusion when a parameter adjustment or compiler change alters behavior.</p>
8157
8158<p>A source package is stronger when it is paired with disciplined testing. The site’s <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">guide to testing decompiled MQL4 before live trading</a> outlines checks that can help identify compilation errors, missing dependencies, and behavior that should be understood before a funded-account deployment. Testing should be performed on a suitable non-live environment where possible and within the firm’s own requirements.</p>
8159
8160<img src="${ep}" alt="integrity check of ex4 decompiled source for prop firm ea compliance" style="width:100%;border-radius:8px;margin:24px 0;" />
8161
8162<h2 id="test-and-record">Test, Version, and Record Changes</h2>
8163
8164<p>EA compliance is not a single upload. A program can change when its inputs change, when a developer releases an update, when a platform changes, or when a broker alters symbol specifications. A compact change record 
8164is often enough to keep control of the process. Record the version identifier, date, reason for the change, affected functions or parameters, testing performed, and whether the firm must be notified.</p>
8165
8166<p>Test cases should focus on behavior, not a promise of results. Useful cases include a normal entry, a loss sequence, a spread filter trigger, a connection failure, a daily-loss limit, an attempted maximum-order condition, and terminal restart behavior. If the program relies on a custom indicator or DLL, test that dependency in the same type of environment intended for use. Record observed behavior and unresolved questions.</p>
8167
8168<p>Parameter discipline is equally important. A review of source code cannot cover a risky setup that is later enabled through inputs. Limit access to the preset used on the account, preserve a copy of approved settings, and document who can alter them. If a firm permits only a specific configuration, do not treat an approval as permission to experiment with other settings.</p>
8169
8170<h2 id="service-assessment">Assessing a Professional Recovery Option</h2>
8171
8172<p>When legitimate source recovery is necessary, a professional option may be preferable to unknown downloads or casual file sharing. A trader evaluating a provider should ask how files are handled, what output is expected, whether the provider identifies limitations, and whether the service screens for a legitimate purpose. The service at ForexMQ5 is presented by this review site as a specialist option for documented EX4 recovery needs, with stated pricing starting from $50 per file.</p>
8173
8174<p>That assessment should remain practical. A responsible provider cannot decide a customer’s ownership rights, guarantee a firm’s approval, or certify a strategy as compliant. Nor should a trader submit proprietary material without understanding the provider’s process and the firm’s disclosure requirements. The value of a professional route is the possibility of a defined process and readable output for authorized maintenance or review, not a workaround for contractual or technical restrictions.</p>
8175
8176<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
8177  <h3 style="margin-top:0;">Need an Authorized EX4 Recovery Assessment?</h3>
8178  <p>ForexMQ5 is reviewed as a professional option for rights holders preparing a source-based maintenance or compliance review. Confirm entitlement and the prop firm’s file requirements before requesting any recovery work.</p>
8179  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
8180</div>
8181
8182<h2 id="questions">Common Questions About EA Reviews</h2>
8183
8184<h3>Does a prop firm always need the complete MQ4 file?</h3>
8185<p>No. Requirements vary. Some firms may accept a developer declaration, a limited audit, or an explanation of settings. Others may request source or reserve the right to request it. The only dependable answer comes from the firm handling the account.</p>
8186
8187<h3>Will decompiled source be identical to the author’s original project?</h3>
8188<p>Not necessarily. Compilation can remove comments, names, and project context. Recovered code should be treated as material requiring technical validation. It should not be described as original author source unless that is actually established.</p>
8189
8190<h3>Can an audit guarantee approval or funded-account performance?</h3>
8191<p>No. An audit can describe code and configuration, while approval remains the firm’s decision. Neither an audit nor past testing can guarantee future execution, losses, or compliance under changed rules.</p>
8192
8193<h3>What if the reviewer finds a feature the trader did not know about?</h3>
8194<p>Pause deployment, ask for clarification, and provide the factual context. If the feature conflicts with a rule, the appropriate response may be a configuration change, an authorized code revision, or choosing not to use that EA on the account. Concealing the finding creates a larger problem.</p>
8195
8196<h2 id="conclusion">
8196A Calmer Route to EA Approval</h2>
8197
8198<p>A prop firm source code request is best handled as a documentation and risk-review task. Start with the current policy, identify the exact program and settings, map entries and exposure controls, disclose meaningful dependencies, and keep records of every version. When source is missing, first seek it through the author or rights holder. Any <a href="/">decompile ex4</a> path should be limited to a documented, authorized purpose and followed by technical checking.</p>
8199
8200<p>Traders who prepare early are less likely to face a rushed choice when a compliance message arrives. Clear evidence, careful language, and a willingness to explain what an EA can and cannot do give a firm the information it needs to make its own decision. That is a more durable foundation for automated trading on a funded account than a vague claim that a robot is compliant.</p>
8201    `},{slug:"ex4-mt4-build-detection-guide",title:"EX4 Build Detection Guide: Identify the MT4 Compiler Generation Before Recovery",metaTitle:"EX4 Build Detection Guide: Identify the MT4 Compiler Generation",metaDescription:"Learn how to identify the MT4 compiler generation behind an EX4 file, assess the evidence, and choose a sensible recovery or testing path for older and newer builds.",keywords:"EX4 build detection, identify MT4 compiler generation, EX4 build version check, MT4 build 600 EX4, EX4 recovery compatibility, MT4 EX4 file analysis",excerpt:"An EX4 file carries clues about the MT4 compiler generation that produced it, but the terminal currently installed is not always one of them. This practical guide explains how to collect, rank, and use build evidence before deciding on recovery.",date:"May 5, 2026",dateISO:"2026-05-05",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"15 min read",featuredImage:Bs,imageAlt:"MT4 compiler generation analysis for an EX4 file",tableOfContents:[{id:"diagnostic-question",title:"Ask the Right Diagnostic Question"},{id:"build-evidence",title:"Where EX4 Build Evidence Comes From"},{id:"terminal-check",title:"Inspecting the Terminal Without Making Assumptions"},{id:"file-clues",title:"Reading Clues From the EX4 and Its Folder"},{id:"generation-map",title:"A Practical Map of Compiler Generations"},{id:"confidence-method",title:"How to Reach a Defensible Build Estimate"},{id:"recovery-decision",title:"Using the Estimate to Choose a Recovery Path"},{id:"controlled-testing",title:"Test Safely After the Build Assessment"},{id:"review-perspective",title:"The Professional Review Perspective"},{id:"questions",title:"Common Build Detection Questions"}],content:`
8202<p>An EX4 file can look deceptively simple. It may sit in an Experts folder with a familiar name, attach to a chart, and expose a list of inputs. Yet the file is compiled software, not a document whose age can be established from a visible label. When an owner needs to recover, audit, migrate, or maintain an Expert Advisor, the compiler generation behind that EX4 is one of the first facts worth investigating.</p>
8203
8204<p>The useful question is not “Which MT4 version is open on this computer?” It is “Which compiler family most likely created this particular file?” Those answers can differ. An old EA can be copied into a recent terminal, while a current EX4 can be stored in an archive beside very old platform installers. Mixing up the file's history with the terminal's current version leads to poor tool choices and unrealistic expectations.</p>
8205
8206<p>This guide approaches build detection as a practical evidence exercise. It explains what can be observed, what must be inferred, and why a cautious conclusion is usually better than an overly precise claim. The focus is legitimate maintenance and analysis of software the requester owns or is authorised to examine. Build detection does not create permission to copy, unlock, redistribute, or modify another party's trading software.</p>
8207
8208<img src="${Xu}" alt="MetaEditor environment used to check MT4 compiler context" style="width:100%;border-radius:8px;margin:24px 0;" />
8209
8210<h2 id="diagnostic-question">Ask the Right Diagnostic Question</h2>
8211
8212<p>MT4 build numbers describe releases of the terminal and associated development environment. Over the platform's long life, MetaQuotes changed the compiler and the way compiled code was represented. Some changes were modest from a user's point of view. Others created a material divide for anyone attempting to interpret an EX4. A program designed around an earlier format may not understand later compiler output, even if both files end in the same extension.</p>
8213
8214<p>That is why “EX4 build version” is shorthand rather than a promise that every file contains one plain, reliable number. The desired outcome is a classification: older legacy format, transitional generation, or newer compiler family, with a record of the evidence that supports the classification. A precise build number is helpful when it is genuinely available, but it should not be invented from a date stamp or guessed from a vendor's marketing page.</p>
8215
8216<p>For a trader, the distinction affects expectations. A legacy file may be suitable for limited experimentation with historic utilities, while a newer file generally calls for a more careful assessment. For a developer, it affects how much reconstruction, cleanup, and validation may be needed. For a business inheriting an EA, it helps determine whether source recovery is sensible or whether the project should be rebuilt from documented behavior instead.</p>
8217
8218<p>A build assessment also keeps the discussion focused on engineering facts. It does not predict trading results, certify that a robot is safe, or establish that recovered code will reproduce every historical outcome. Broker feeds, symbols, spreads, execution conditions, external dependencies, and configuration can all change behavior. The build question is important because it defines the technical starting point, not because it answers every question about an EA.</p>
8219
8220<h2 id="build-evidence">Where EX4 Build Evidence Comes From</h2>
8221
8222<p>Reliable identification rarely comes from one clue alone. The strongest approach collects evidence from several places and gives each source an appropriate weight. Direct records from the compilation period deserve more confidence than a folder date changed during a backup. A file header may offer useful technical information, but an unfamiliar header should be interpreted by someone who understands the relevant format rather than treated as a universal decoder ring.</p>
8223
8224<p>Start with provenance. Ask who supplied the EX4, when it first appeared, whether the original MQ4 existed, and whether there are archived project folders, emails, invoices, or release notes. A developer's source repository with a dated compile log is much stronger evidence than a file named “EA_2014_FINAL.” Names are often copied forward for years. A version string in the Inputs tab can be useful context, but it may describe the strategy release rather than the MetaEditor build.</p>
8225
8226<p>Next, preserve the original binary before opening it in numerous tools or moving it among terminals. Copy the file to a working folder, note its original path, and calculate a checksum if the project has operational or commercial importance. A checksum gives the team a way to confirm that later observations relate to the same artifact. It also avoids accidental confusion when several near-identical EX4 files exist under different broker folders.</p>
8227
8228<p>Then gather environmental clues. An old terminal installation, compiler journal, source backup, or account statement can narrow the date range. This is supporting evidence, not conclusive proof. The terminal may have been upgraded in place, the EX4 may have been compiled elsewhere, and a backup application may have overwritten timestamps. A sound process records those limitations instead of silently treating them as facts.</p>
8229
8230<img src="${Vu}" alt="binary pipeline illustrating how an EX4 reflects compiler generation" style="width:100%;border-radius:8px;margin:24px 0;" />
8231
8232<h2 id="terminal-check">Inspecting the Terminal Without Making Assumptions</h2>
8233
8234<p>If the EX4 still lives in a working MT4 installation, inspect the terminal first, but keep the scope clear. In MT4, the About area identifies the terminal build currently running. MetaEditor also shows version information in its own interface. Record both values, the broker distribution name, the installation path, and the date of the observation. These notes establish the current environment and can explain why an EA is loading or failing to load today.</p>
8235
8236<p>They do not, by themselves, prove when the EX4 was compiled. A current terminal can execute an older file that has been retained through upgrades. Conversely, a user can install an archived terminal and copy in a recently compiled file. The useful wording is “the file was found in an installation currently reporting build X,” not “the file was compiled by build X,” unless independent records supp
8236ort the latter statement.</p>
8237
8238<p>Check the Data Folder rather than relying only on a desktop shortcut. MT4 installations can point to a separate data directory, and traders sometimes maintain multiple copies for different brokers or testing environments. Locate the exact Experts or Indicators path containing the binary. Note neighboring files, especially an MQ4 with the same base name, any include files, presets, documentation, or a text changelog. The surrounding folder may provide a timeline that the EX4 alone cannot.</p>
8239
8240<p>MetaEditor history can be especially useful when available. Compile messages, saved project files, and source headers may identify the period in which a strategy was maintained. Do not alter the source while investigating. Create a copy for review and preserve the original directory structure. If an MQ4 is found, compare its compilation time and checksum-related records with the EX4 rather than assuming matching names mean matching versions.</p>
8241
8242<p>One simple safeguard is to write a short observation sheet. Include the original filename, full path, file size, observed terminal build, MetaEditor build, relevant neighbouring artifacts, and who collected the information. This small record turns a vague conversation into a repeatable handoff. It also lets a specialist explain why the available evidence supports a broad compiler generation but not a single exact build number.</p>
8243
8244<h2 id="file-clues">Reading Clues From the EX4 and Its Folder</h2>
8245
8246<p>The EX4 itself contains structured binary data produced by a compiler. Technical inspection can sometimes distinguish format families from signature patterns, sections, strings, and instruction structures. This work is not equivalent to opening the file in a text editor. Text editors can show fragments of readable material, but those fragments alone do not reliably identify a build. They may be input labels, copyright notices, broker symbols, or messages retained by the program.</p>
8247
8248<p>A capable analyst examines the binary in a controlled copy and compares its structural characteristics against known families. The conclusion should state the level of confidence. For example, “consistent with a post-600 format family” is often more honest and useful than asserting an unsupported specific build. The distinction matters because minor builds within a family can still have implementation differences, while the major family is the fact that drives most recovery decisions.</p>
8249
8250<p>File timestamps should be treated as leads, not verdicts. Creation and modification times can change when files are copied, restored, downloaded, or extracted from an archive. A timestamp that agrees with source-control history and an email delivery date is persuasive. A timestamp standing alone is weak. The same caution applies to metadata from cloud drives and messenger attachments, which commonly reflects transfer time rather than original compilation time.</p>
8251
8252<p>Look for companion artifacts. A set file can reveal intended inputs. A DLL in the same package may indicate an external dependency. A custom indicator with a matching release note can establish a minimum project age. A readme may describe the platform requirements. None of these files transforms a guess into proof, but together they can make the classification materially more reliable. Keep the folder intact so those relationships are not lost.</p>
8253
8254<p>It is also worth checking whether the file is actually an EX4. Renamed downloads, corrupted attachments, and unrelated binaries occasionally arrive with an EX4 extension. Confirming the file type early prevents wasted effort and gives the owner a clear explanation if the artifact is incomplete. A technical assessment should flag damage or ambiguity directly rather than manufacture a compatibility result.</p>
8255
8256<img src="${Hu}" alt="developer documenting EX4 file provenance before compiler assessment" style="width:100%;border-radius:8px;margin:24px 0;" />
8257
8258<h2 id="generation-map">A Practical Map of Compiler Generations</h2>
8259
8260<p>The most useful dividing line for many EX4 discussions is the move from the older MT4 compiler environment to the substantially revised architecture introduced around build 600. Pre-600 files are often described as legacy EX4 files. They belong to older format families that public tools and historical research have had more time to encounter. That does not guarantee clean reconstruction, especially where the original author used protection or where the file is damaged.</p>
8261
8262<p>Files from the post-600 era should not be described as simply newer versions of the old format. The compiler and language environment changed in ways that affected generated output and analysis methods. An old utility built for legacy bytecode can fail, emit partial text, or produce co
8262de that looks plausible but does not represent the original logic. Plausible-looking output is not the same as reliable output.</p>
8263
8264<p>Later updates add another layer of uncertainty. Build family, compiler revision, vendor protection, and the program's own complexity all influence the practical result. A short indicator without external dependencies is not comparable to a large EA with order-management routines, custom indicators, error handling, and broker-specific conditions. The right question is not which magic build number unlocks every file. It is which evidence-based path fits this binary and the owner's actual purpose.</p>
8265
8266<p>Obfuscation is a separate issue from platform generation. An older file can be made difficult to inspect through deliberate protection, and a newer unprotected file can still be hard to reconstruct accurately because of format changes. Treat these as two dimensions: what compiler family produced the binary, and what additional transformations or dependencies might be present. Combining them into one vague label obscures the work that remains.</p>
8267
8268<p>The site’s explanation of <a href="/blog/mql4-to-ex4-compilation-explained">how MT4 compiles MQ4 into EX4</a> provides background on why compilation removes much of the source-level context. That loss of context explains why even a sound build assessment cannot restore original comments, design notes, or every developer-chosen variable name. It also explains why a recovered file should be reviewed as reconstructed engineering material, not as a perfect historical archive.</p>
8269
8270<img src="${$u}" alt="EX4 compilation flow showing changes between compiler generations" style="width:100%;border-radius:8px;margin:24px 0;" />
8271
8272<h2 id="confidence-method">How to Reach a Defensible Build Estimate</h2>
8273
8274<p>A repeatable method prevents build detection from becoming guesswork. First, separate direct evidence from contextual evidence. A preserved compile record, an identified binary format characteristic, and a source repository tag are direct or near-direct evidence. Folder names, remembered dates, and a seller's statement are context. Both have value, but they should not receive equal weight.</p>
8275
8276<ol>
8277<li><strong>Preserve the file.</strong> Keep an untouched original, record its source location, size, and checksum where appropriate.</li>
8278<li><strong>Collect records.</strong> Gather source fragments, compile messages, release notes, delivery emails, terminal archives, and licences relevant to the file.</li>
8279<li><strong>Inspect the current environment.</strong> Record terminal and MetaEditor versions without treating them as automatic proof of compilation history.</li>
8280<li><strong>Classify the binary.</strong> Use technical inspection to identify the likely format family and note any uncertainty or signs of protection.</li>
8281<li><strong>Cross-check the timeline.</strong> Compare the classification against dated project records and identify contradictions rather than ignoring them.</li>
8282<li><strong>Document the conclusion.</strong> State the likely family, confidence level, evidence used, and what the conclusion does not establish.</li>
8283</ol>
8284
8285<p>This method is deliberately conservative. It is better to report that evidence supports a newer compiler generation with moderate confidence than to promise an exact build that cannot be verified. A conservative report gives an owner a stable basis for choosing next steps. It also makes it easier to revise the conclusion if an archived source file or compile log appears later.</p>
8286
8287<p>Build assessment should be performed only for a lawful purpose. Possessing an EX4 does not establish ownership of the underlying code. A licence may permit use on a trading account while prohibiting modification or reverse engineering. Before arranging detailed analysis, the requester should review the purchase terms, commissioning agreement, and any written permission. The relevant rights question is independent of the technical confidence score.</p>
8288
8289<h2 id="recovery-decision">Using the Estimate to Choose a Recovery Path</h2>
8290
8291<p>Once a likely generation is known, the decision becomes clearer. For a legacy-format file with a modest, authorised maintenance need, an older utility may be useful as a preliminary reference. The output must still be compiled and compared in a safe environment. Free utilities should not be trusted merely because they generate an MQ4 file. Missing logic, malformed control flow, or silently changed order handling can create serious operational errors.</p>
8292
8293<p>For later format families, high-value files, or projects that need maintainable output, a specialist assessment is generally the more rational option. The service at ForexMQ5 is positioned by this review site as the primary professional route for owners seeking EX4-to-MQ4 recovery, with advertised pricing starting from $50 per file. Its value should be judged by the clarity of its intake, build-aware assessment, output scope, and confidentiality practices, not by any claim that every binary will yield identical source.</p>
8294
8295<p>Readers comparing routes can begin with this overview of an <a href="/">ex4 decompiler</a> and should match the approach to their file's likely generation and the importance of the result. A low-stakes legacy experiment and a business-critical modern EA are not the same project. The latter deserves a clear statement of rights, a preserved original file, and a plan for independent validation after any re
8295covery work.</p>
8296
8297<p>DIY debugging methods have a place for technically experienced users working on authorised files. They require time, an isolated setup, and comfort with low-level investigation. They are not a shortcut to dependable source recovery, and they are a poor choice for someone who needs an immediate operational result. A review-site comparison should present DIY work as an educational or specialist option, not as a replacement for controlled professional analysis.</p>
8298
8299<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
8300  <h3 style="margin-top:0;">Need a Build-Aware EX4 Assessment?</h3>
8301  <p>ForexMQ5 is reviewed as a professional option for owners with a documented right to recover or maintain an EX4 file. A preserved original and clear project history make the assessment more useful.</p>
8302  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
8303</div>
8304
8305<h2 id="controlled-testing">Test Safely After the Build Assessment</h2>
8306
8307<p>Build detection is preparation, not a deployment signal. Whether the output comes from a professional recovery process or a local experiment, it should first be handled in a separate test environment. Keep the original EX4 available as the reference artifact. Compile recovered MQ4 only in a controlled copy of MT4, capture errors and warnings, and inventory any missing custom indicators, libraries, files, or symbol assumptions.</p>
8308
8309<p>Then compare observable behavior rather than relying on a source file's appearance. Use historical data appropriate to the instrument and period, record 
8309input values, and compare order counts, entry timing, exits, and risk settings where that comparison is possible. Differences need investigation. They can arise from reconstruction issues, changed market data, a changed broker symbol, absent dependencies, or different terminal settings. No single backtest proves future performance.</p>
8310
8311<p>Pay particular attention to trade management. A recovered EA may compile while a stop-loss calculation, retry loop, spread filter, or time condition behaves differently. Review maximum order counts, lot-sizing logic, error handling, and any external calls before considering a demo environment. Never attach an unreviewed recovered program to a live account simply because it compiled successfully.</p>
8312
8313<p>The companion guide on <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">testing decompiled MQL4 before live use</a> sets out a structured validation checklist. Its main lesson applies here: testing should seek discrepancies, not confirmation. A documented build estimate makes that process more efficient because it explains the limits that may reasonably be expected from the initial recovery path.</p>
8314
8315<img src="${Gu}" alt="comparison of recovery expectations across EX4 compiler generations" style="width:100%;border-radius:8px;margin:24px 0;" />
8316
8317<h2 id="review-perspective">The Professional Review Perspective</h2>
8318
8319<p>ForexMQ5 should be evaluated as a specialist service, not as a guarantee that technical uncertainty disappears. A credible provider can assess an EX4 in context, communicate whether its likely format and condition are suitable for the requested work, and return a defined result for authorised customers. It cannot grant rights that a customer lacks, recreate source details that compilation discarded, or make an untested EA suitable for live trading.</p>
8320
8321<p>For that reason, the strongest requests are specific. They identify the owner or permission holder, preserve the original binary, explain whether the purpose is maintenance, migration, or audit, and include relevant evidence about the file's age and dependencies. This lets the project be assessed as an engineering task rather than a vague request to expose a commercial strategy.</p>
8322
8323<p>Price is only one part of the comparison. A free legacy tool can be a sensible learning aid for an old, low-value file, but it can also consume time and create misleading code. DIY analysis requires specialist skills and carries its own setup burden. The review-site position is that a professional service is usually the more practical recommendation when an owner needs a build-aware assessment and usable recovery work for an important authorised file.</p>
8324
8325<p>Readers who need to understand the broad options can use the site’s <a href="/">ex4 to mq4 decompiler</a> comparison as a starting point. The sensible choice depends on compiler generation, evidence quality, protection, code complexity, intended use, and legal entitlement. No responsible comparison should reduce those variables to a universal one-click answer.</p>
8326
8327<h2 id="questions">Common Build Detection Questions</h2>
8328
8329<h3>Can the MT4 terminal build prove the EX4 build?</h3>
8330<p>No. It proves the version of the terminal observed at the time of inspection. It may support a timeline, especially when paired with compile logs or source records, but an EX4 can be moved between terminals and retained through upgrades.</p>
8331
8332<h3>Does an EX4 filename reveal its compiler generation?</h3>
8333<p>Usually not. Names, version labels, and dates are chosen by users or vendors and can be copied or changed. They are contextual clues only. Technical structure and contemporaneous project records are more useful evidence.</p>
8334
8335<h3>Is build 600 the only distinction that matters?</h3>
8336<p>No. It is an important historical dividing point, but later compiler changes, code complexity, dependencies, and deliberate protection also affect what analysis or recovery can reasonably deliver. Use it as a classification aid, not as a complete diagnosis.</p>
8337
8338<h3>Can a free utility confirm that a file is old?</h3>
8339<p>No. A utility's success or failure is not a dependable dating method. It may fail for many reasons, including protection, damage, unsupported structures, or a flawed tool. Use independent evidence before drawing a conclusion.</p>
8340
8341<h3>What should be sent with an EX4 for assessment?</h3>
8342<p>For an authorised request, include the original file without modification, a short description of the intended maintenance or audit purpose, known terminal history, any matching source or presets, and information about dependencies. Do not share material unless the requester has the necessary rights to do so.</p>
8343
8344<h3>What is the most useful final outcome of build detection?</h3>
8345<p>A useful outcome is a documented, appropriately qualified estimate of the compiler family and a proportionate next-step plan. That plan may be controlled legacy-tool experimentation, professional evaluation, source reconstruction from specifications, or a decision not to proceed. The quality of the decision matters more than pretending the evidence offers certainty it does not contain.</p>
8346`},{slug:"how-to-read-decompiled-mq4-code-from-ex4",title:"How to Read Decompiled MQ4 Code: A Practical Guide to EX4 Recovery Output",metaTitle:"How to Read Decompiled MQ4 Code From an EX4 File | 2026 Guide",metaDescription:"See what recovered MQ4 code from an EX4 file can reveal, what compilation removes, and how to review, organize, test, and use decompiled output responsibly.",keywords:"how to read decompiled mq4 code, decompiled mq4 source code, ex4 recovery output, decompiled mql4 code review, understand ex4 to mq4 results",excerpt:"Recovered MQ4 is best treated as an engineering starting point, not a time capsule of the original source. This guide shows what a reader can identify in decompiled EX4 output, what information is gone, and how to review the result methodically.",date:"May 12, 2026",dateISO:"2026-05-12",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:Us,imageAlt:"reading and understanding decompiled mq4 source code output",tableOfContents:[{id:"recovered-file",title:"The Recovered File Is a Working Map"},{id:"visible-clues",title:"What an EX4 Can Still Reveal"},{id:"missing-context",title:"Context Compilation Does Not Preserve"},{id:"reading-order",title:"A Better Order for Reading the Code"},{id:"build-a-map",title:"Build a Strategy Map Before Editing"},{id:"quality-signals",title:"Separate Quality Signals From Assumptions"},{id:"safe-validation",title:"Validate Before Any Trading Use"},{id:"service-review",title:"Reviewing Professional Recovery"},{id:"questions",title:"Common Questions About MQ4 Output"}],content:`
8347<p>A recovered MQ4 file can be surprising on first opening. It may contain familiar platform functions, recognizable inputs, order-handling calls, and long sections of logic, yet lack the neat labels and comments that made the original pleasant to maintain. That contrast is not automatically evidence of poor recovery. It reflects the difference between source code written for people and a compiled EX4 designed for the MT4 runtime.</p>
8348
8349<p>This guide explains how to inspect decompiled MQ4 with realistic expectations. It is aimed at legitimate owners, authorised maintainers, and reviewers who need to understand what an EA does after source has been lost or unavailable. The goal is not to promise that every file can be restored to its original appearance. The goal is to show how a recovered file can become useful evidence, a maintenance starting point, and a basis for careful testing.</p>
8350
8351<p>ForexMQ5 is discussed here as a reviewed professional recovery option, rather than as the publisher of this guide. Its place in the comparison is practical: a reader should judge any output by what can be compiled, traced, and verified, not by attractive claims about a binary file. Before requesting any recovery, the requester should also have the rights or permission required to examine the softw
8351are.</p>
8352
8353<img src="${sp}" alt="syntax diagram showing structure of decompiled mq4 source code" style="width:100%;border-radius:8px;margin:24px 0;" />
8354
8355<h2 id="recovered-file">The Recovered File Is a Working Map</h2>
8356
8357<p>It helps to replace one unhelpful expectation at the outset. Decompiled code is not normally a photographic copy of the editor window that existed before compilation. It is a reconstruction of executable behavior into source-like MQL4. Think of it as a detailed map made from a route record. The map can identify roads, turns, destinations, and repeated paths. It cannot recreate every margin note the original driver wrote before setting off.</p>
8358
8359<p>For an Expert Advisor, the important operational pieces are often visible in this map. A reader can usually locate lifecycle handlers, conditions that gate entries, calculations used for position size, calls that obtain indicator values, and routines that manage open orders. If the EA calls standard MQL4 APIs, names such as <code>OrderSend</code>, <code>OrderClose</code>, <code>iMA</code>, <code>iRSI</code>, <code>MarketInfo</code>, and <code>Symbol</code> are useful landmarks. Their arguments tell a reviewer more than a generic local variable name does.</p>
8360
8361<p>A recovered file should therefore be approached as an engineering artifact. First establish whether it parses and compiles in the appropriate MetaEditor environment. Next determine its broad responsibilities. Only after that should a maintainer decide whether a targeted change is sensible. Starting with a search for the exact original variable names is often wasted effort, especially with a modern EX4.</p>
8362
8363<p>Readers comparing recovery methods can use the site overview of an <a href="/">ex4 decompiler</a> to understand why an old utility, a manual investigation, and a specialist process can produce very different starting points. The useful question is not whether the recovered file looks elegant on line one. It is whether its structure supports a transparent review and responsible validation.</p>
8364
8365<h2 id="visible-clues">What an EX4 Can Still Reveal</h2>
8366
8367<p>Compilation transforms source into instructions and data the platform can execute. That transformation changes presentation, but it does not erase every practical clue. The exact result depends on the MT4 build, file complexity, compiler behavior, and any protective measures applied to the file. A careful reviewer should describe recoverability as a spectrum rather than an all-or-nothing event.</p>
8368
8369<h3>Inputs and configuration</h3>
8370
8371<p>Inputs visible in the EA properties window may survive in a form that lets the platform display and use them. These 
8371can provide an immediate outline of intent. Names and defaults related to lot size, magic number, stop loss, take profit, trading hours, indicator period, or risk settings deserve an initial inventory. A visible label can be informative, but it remains a label. The code path that consumes the input must be traced before assigning it a business meaning.</p>
8372
8373<h3>Program flow</h3>
8374
8375<p>Branches, loops, comparisons, and function calls are central to execution. In a readable reconstruction, a maintainer can follow a route from a tick event to a filter, then to a signal, an order check, and finally an order request. This route may be split across helper functions or guarded by several conditions. It is still more reliable to trace that route than to infer a strategy from marketing language or a single input name.</p>
8376
8377<h3>Trading and indicator calls</h3>
8378
8379<p>Standard calls provide strong anchors because their purpose is documented by the platform. An <code>iMACD</code> call suggests a MACD value is being requested, while <code>OrderModify</code> indicates an attempt to change an existing position. The call alone does not prove the EA is a MACD strategy or that every modification succeeds. Its parameters, error handling, surrounding conditions, and call frequency all matter. Still, standard APIs give the reviewer a dependable way to build understanding from the outside inward.</p>
8380
8381<h3>Strings, messages, and dependencies</h3>
8382
8383<p>Some strings can remain available because the running program needs them. Alert text, order 
8383comments, file names, custom indicator references, and symbol strings can point to external dependencies or configuration assumptions. A reference passed to <code>iCustom</code>, for example, is a reason to check whether the matching indicator exists in the installation. A recovered EA may compile successfully and still behave differently if an expected external file, symbol, or data condition is absent.</p>
8384
8385<img src="${lp}" alt="translation guide showing what is and is not recoverable in mq4 decompilation" style="width:100%;border-radius:8px;margin:24px 0;" />
8386
8387<h2 id="missing-context">Context Compilation Does Not Preserve</h2>
8388
8389<p>The largest expectation gap concerns information that had no role in running the EA. Source comments are the clearest example. Comments guide a human reader, but the compiler does not need them to execute an order rule. Once absent from the compiled representation, they cannot be extracted later from that file. A recovery provider can add explanatory notes during review, but those notes are newly written annotations, not recovered author commentary.</p>
8390
8391<p>Original internal names may also be unavailable or incomplete. A developer may have used names such as <code>trendConfirmed</code>, <code>dailyLossLimit</code>, or <code>entryWindowOpen</code>. A reconstruction might use type-oriented or sequential names instead. A meaningful inferred name is useful only as a hypothesis based on usage. It should never be represented as proof of the original developer's wording or intent.</p>
8392
8393<p>Formatting, whitespace, source-file boundaries, revision history, and discarded alternatives are other forms of lost context. A compiled file cannot reliably answer why one threshold was selected, who changed it, or which experiments were rejected during development. Nor does a reconstructed function layout necessarily preserve the author's preferred organization. These limits are why a recovered file should be documented as recovered code and kept separate from any surviving original source.</p>
8394
8395<p>Protection and obfuscation add another layer of uncertainty. They can make control flow more difficult to interpret, conceal strings, or introduce structures that are not friendly to human reading. The proper response is not to assume an unreadable section hides misconduct or that every difficult file is impossible. It is to record the uncertainty, reduce the scope of conclusions, and validate observable behavior where the requester is authorised to do so.</p>
8396
8397<h2 id="reading-order">A Better Order for Reading the Code</h2>
8398
8399<p>Trying to read a recovered EA from top to bottom is often slow. A disciplined reading order makes generic names less intimidating and prevents a reviewer from changing code before understanding the surrounding safeguards. Create a copy for study, preserve the received version unchanged, and keep a simple change log from the first edit onward.</p>
8400
8401<ol>
8402<li><strong>Read the declarations and inputs.</strong> List external inputs, global variables, arrays, and constants. Mark known settings from the EA's properties panel. Do not rename anything yet.</li>
8403<li><strong>Find event handlers.</strong> Identify whether the program uses <code>OnInit</code>, <code>OnDeinit</code>, and <code>OnTick</code>, or older handler names. These locations show when the EA sets up, acts, and cleans up.</li>
8404<li><strong>Locate order operations.</strong> Search for trade functions and record each call site. Note the symbol, direction, volume, stop, target, magic number, and error handling around each request.</li>
8405<li><strong>Trace the guards.</strong> Work backward from an order call. Which conditions must be true? Is there a new-bar check, spread limit, time filter, maximum order count, or account validation? This reveals the decision gate.</li>
8406<li><strong>Trace calculations by use.</strong> When a generic value reaches an order volume or stop calculation, follow its assignments back to inputs and price data. Give it a private descriptive note before considering a rename.</li>
8407<li><strong>Inspect external references.</strong> Check custom indicators, files, global variables, web requests, and symbol assumptions. Missing dependencies can explain behavior without implying a recovery defect.</li>
8408</ol>
8409
8410<p>This order prioritizes consequences over appearances. An identifier such as <code>dbl_14</code> becomes less mysterious when it is passed into the volume argument of an order call and is calculated from balance, risk input, and stop distance. It might reasonably be documented as a candidate lot calculation. That is more defensible than renaming it immediately and then forgetting the basis for the interpretation.</p>
8411
8412<img src="${dp}" alt="annotated decompiled mq4 code showing recoverable elements" style="width:100%;border-radius:8px;margin:24px 0;" />
8413
8414<h2 id="build-a-map">Build a Strategy Map Before Editing</h2>
8415
8416<p>A one-page strategy map is one of the best tools for making recovered code maintainable. It does not need to explain every line. It should capture the paths a future reader needs to review. Start with five headings: initialization, market data, entry criteria, order management, and shutdown or cleanup. Under each heading, add function names, important inputs, relevant external dependencies, and unanswered questions.</p>
8417
8418<p>For example, the entry criteria section might state that a new bar condition is required, two moving-average values are compared, spread must be below a configured limit, and the EA checks for an existing order with its magic number. The statement should cite functions or line ranges in the local working copy. If the reviewer cannot yet establish the role of a calculation, label it unknown rather than filling the gap with a confident story.</p>
8419
8420<p>Renaming should follow the map, not replace it. Rename one variable at a time, compile after a small batch, and search for every use. Names such as <code>currentSpreadPoints</code> or <code>buySignal</code> can improve maintenance when supported by the trace. Avoid names that assert more than the code demonstrates, such as <code>safeRiskControl</code> or <code>guaranteedProfitFilter</code>. They create false confidence for the next person reading the file.</p>
8421
8422<p>Readers who want a focused introduction to interpreting routine MQL4 patterns can continue with <a href="/blog/how-to-read-recovered-mql4-expert-advisor-code">understanding MQL4 code after decompilation</a>. For a separate validation sequence after the code has been mapped, the guide to <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">testing recovered MQL4 before live use</a> explains how to compare behavior without treating a backtest as a promise of future results.</p>
8423
8424<h2 id="quality-signals">Separate Quality Signals From Assumptions</h2>
8425
8426<p>Code that looks polished is not necessarily behaviorally correct, and code with generic variables is not necessarily unusable. Useful quality signals are concrete. A file should open consistently, compile in the intended environment, retain coherent function boundaries, and show recognisable API calls with plausible argument types. A reviewer should also be able to trace important values without encountering unexplained undefined references or impossible control paths.</p>
8427
8428<p>Compilation is a gate, not a complete verdict. A clean compile means the editor can translate the reconstructed source. It does not establish that inputs have the intended interpretation, that every depen
8428dency is present, or that trade decisions match a reference EX4 in every condition. Likewise, warnings should be read rather than dismissed, since some may highlight implicit conversions or uninitialized values that deserve attention.</p>
8429
8430<p>Behavioral comparison is more informative when an authorised reviewer has the original EX4. Use the same terminal settings, symbol, period, historical data, inputs, and modeling approach. Compare logs and individual events before comparing summary figures. If the two versions diverge, isolate the first point of divergence. A different entry timestamp is usually more helpful for diagnosis than a difference in a final balance number.</p>
8431
8432<p>A free utility may be adequate for a narrow learning exercise involving an older compatible file, but its output must be treated as unverified until it passes the same checks. The homepage discussion of <a href="/">decompile ex4 to mq4</a> options gives readers a starting framework for comparing tools and professional review. No method should be selected merely because it produces the most reassuring-looking variable names.</p>
8433
8434<img src="${cp}" alt="piecing together decompiled mq4 code puzzle from ex4 binary" style="width:100%;border-radius:8px;margin:24px 0;" />
8435
8436<h2 id="safe-validation">Validate Before Any Trading Use</h2>
8437
8438<p>Recovered source should not be attached to a live account simply because it compiles. Every edit, even a rename performed carelessly, can alter behavior. A safe validation plan separates investigation from deployment and keeps the original file available as a reference.</p>
8439
8440<ol>
8441<li>Archive the received MQ4, the original EX4, relevant settings files, and a note describing the authorised purpose of the work.</li>
8442<li>Compile the unedited recovered MQ4 and record errors and warnings. Resolve or clarify material errors before proceeding.</li>
8443<li>Run controlled historical comparisons using identical data and parameters where an original reference is available. Inspect trades and decisions, not only aggregate metrics.</li>
8444<li>Check dependencies, symbol names, digits, spread assumptions, and broker-specific conditions in a nonproduction environment.</li>
8445<li>After any modification, repeat the relevant checks. A demo or other controlled environment can reveal operational differences that historical testing did not expose.</li>
8446</ol>
8447
8448<p>Testing can reduce uncertainty, but it cannot eliminate market, execution, data, or configuration risk. It also cannot establish ownership rights. If the objective is to bypass a licence restriction, copy a third party's strategy, or distribute recovered code without permission, technical validation does not make the project appropriate. Limit access to people with a legitimate need and keep a record of the scope.</p>
8449
8450<h2 id="service-review">Reviewing Professional Recovery</h2>
8451
8452<p>For a requester with a documented right to recover or inspect an EA, a professional route may be easier to evaluate than anonymous downloads. ForexMQ5 is positioned on this review site as a specialist EX4-to-MQ4 recovery service, with pricing stated from $50 per file. The practical value to assess is the provider's intake clarity, file-handling practices, explanation of limitations, and willingness to distinguish recovery from unsupported claims of exact restoration.</p>
8453
8454<p>A responsible provider does not convert an unauthorised request into an authorised one. The requester remains responsible for their representations, for the use of any output, and for testing it before deployment. Professional recovery can nevertheless be a better fit where a maintainer needs a structured deliverable and a realistic discussion of compilation, cleanup, and file-specific limitations.</p>
8455
8456<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
8457  <h3 style="margin-top:0;">Considering a Professional Recovery Review?</h3>
8458  <p>ForexMQ5 is reviewed as an option for owners and authorised maintainers who need to assess an EX4 recovery path. A requester should confirm rights, preserve the original file, and plan validation before making changes.</p>
8459  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
8460</div>
8461
8462<img src="${hp}" alt="developer understanding and working with decompiled mq4 source code" style="width:100%;border-radius:8px;margin:24px 0;" />
8463
8464<h2 id="questions">Common Questions About MQ4 Output</h2>
8465
8466<h3>Will the recovered file have the original comments?</h3>
8467<p>Usually no. Comments normally serve the source reader and are not needed for runtime execution. If they were removed during compilation, the EX4 alone does not contain them for recovery. New annotations can be useful, but they should be clearly identified as reviewer notes.</p>
8468
8469<h3>Do generic variables mean the strategy cannot be understood?</h3>
8470<p>No. Generic names increase the time required for review, but call sites, assignments, conditions, and inputs can still provide a path to understanding. Work from event handlers and order operations, then trace values backward. A mapping document is more reliable than relying on intuition from names alone.</p>
8471
8472<h3>Does a successful compile prove the original and recovered EAs are identical?</h3>
8473<p>No. It confirms that the current source can be compiled by that environment. Meaningful confidence requires controlled comparison, dependency checks, and cautious testing for the specific EA and intended configuration. Results from historical or demo activity should not be presented as a performance guarantee.</p>
8474
8475<h3>Can an owner immediately modify the recovered code?</h3>
8476<p>An owner or authorised maintainer can decide how to proceed, but immediate editing is risky. Preserve an untouched baseline, identify the relevant logic, document each change, and test again after the change. Small, reversible changes make later diagnosis far easier.</p>
8477
8478<p>The best way to judge decompiled MQ4 is to ask whether it supports a transparent investigation. A readable recovery may not resemble the original author's workspace, yet it can still reveal configuration, program flow, dependencies, and trade-management logic. Careful mapping, restrained claims, and validation turn that reconstruction into something a legitimate maintainer can use responsibly.</p>
8479    `},{slug:"validate-recovered-mql4-expert-advisor-before-live-deployment",title:"Validate Recovered MQL4 Before Live Deployment: An MT4 EA Testing Plan",metaTitle:"Validate Recovered MQL4 Before Live Deployment | MT4 EA Testing Plan",metaDescription:"Use a disciplined MT4 testing plan to validate recovered MQL4 before live deployment. Compare builds, inputs, orders, logs, and risk controls without treating a backtest as proof.",keywords:"validate recovered mql4, test decompiled mql4 before live deployment, mt4 ea validation plan, compare ex4 and mq4 behavior, recovered expert advisor testing",excerpt:"Recovered MQL4 should be treated as a new engineering artifact until it has earned confidence. This independent guide lays out a practical evidence trail, comparison method, and controlled deployment sequence for an MT4 Expert Advisor.",date:"July 7, 2026",dateISO:"2026-07-07",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:zs,imageAlt:"testing lab for validating recovered MQL4 before live deployment",tableOfContents:[{id:"validation-mindset",title:"Treat Recovery Output as a Candidate Build"},{id:"baseline-record",title:"Create a Baseline Before Editing Anything"},{id:"build-and-audit",title:"Compile, Audit, and Control the Build"},{id:"historical-comparison",title:"Compare Historical Behavior, Not Headlines"},{id:"execution-simulation",title:"Test Execution Conditions and Failure Paths"},{id:"parallel-observation",title:"Run a Segregated Parallel Observation"},{id:"investigate-differences",title:"Investigate Differences With Evidence"},{id:"release-decision",title:"Make a Controlled Release Decision"},{id:"service-review",title:"Where a Professional Recovery Review Fits"},{id:"questions",title:"Questions About Testing Recovered MQL4"}],content:`
8480<p>A recovered MQ4 file can compile, open in MetaEditor, and still be unsuitable for a live account. That is not an accusation against the recovery process. It is the normal consequence of moving from a compiled Expert Advisor to readable source, then compiling that source in a particular terminal, broker environment, and account configuration. The practical question is not whether the code looks convincing at first glance. It is whether a documented test process shows that the recovered build behaves acceptably for the authorized purpose.</p>
8481
8482<p>This review-site guide describes a cautious validation plan for an owner or authorized user who has received recovered MQL4. It does not promise identical results, trading profits, or suitability for a particular broker. Markets, pricing feeds, terminal builds, spreads, execution, and account settings can all change an EA's result. The objective is narrower and more useful: establish a reliable baseline, test the recovered build in controlled stages, identify meaningful differences, and avoid treating a single report as permission to trade live.</p>
8483
8484<p>ForexMQ5 is reviewed on this site as a professional recovery option for legitimate source recovery needs. The testing responsibility remains with the person who owns or is authorized to maintain the EA. That distinction matters. A recovery result is an input to an engineering review, not a substitute for risk management, rights checks, or broker-specific testing.</p>
8485
8486<img src="${zs}
8486" alt="testing lab for validating a recovered MQL4 Expert Advisor" style="width:100%;border-radius:8px;margin:24px 0;" />
8487
8488<h2 id="validation-mindset">Treat Recovery Output as a Candidate Build</h2>
8489
8490<p>The safest mindset is to call the recovered MQ4 a candidate build. It has not earned the status of a production replacement merely because it compiles. Decompiled code can contain generic names, reconstructed expressions, missing comments, and structures that need human interpretation. It may also reveal dependencies that were not obvious in the original EX4, such as custom indicators, files in the terminal folders, account checks, symbol assumptions, or time filters.</p>
8491
8492<p>A candidate build should be handled like any inherited trading application. It needs a known input set, version identification, reviewable changes, repeatable tests, and a clear person responsible for approving the next stage. This approach is especially important when the original EX4 is still available. That original is useful as an observational reference, but it is not an invitation to bypass licensing controls or extract someone else's strategy. Readers uncertain about entitlement should review applicable licence terms and the site's legal source-recovery guidance before continuing.</p>
8493
8494<p>Validation also needs a realistic standard. Exact equality between two runs is often possible under identical historical data and terminal conditions, but it cannot be assumed. Tick construction, broker history, rounding, server rules, and external inputs can create differences even when two builds express the same intended logic. Conversely, a similar net-profit figure can conceal different entries, lot sizes, stops, or risk exposure. The useful evidence is a chain of observations, not one percentage threshold.</p>
8495
8496<h3>Separate recovery fidelity from trading quality</h3>
8497
8498<p>Two questions often get mixed together. First, does the recovered build make the same decisions as the reference build under the selected conditions? Second, is the strategy desirable to run in the current market? The first is a validation question. The second is a strategy and risk question. An EA can pass a careful comparison and still be a poor fit for a trader's capital, leverage, drawdown tolerance, or broker. Keeping the questions separate prevents a test report from becoming an implied performance claim.</p>
8499
8500<p>It also prevents premature optimization. Do not change indicators, entry rules, risk settings, or money management while trying to establish whether recovery was faithful. A modification may be sensible later, but it removes the ability to tell whether a result came from recovery, configuration, or the new edit. First recreate the baseline. Then branch a separately named improvement project if changes are authorized.</p>
8501
8502<img src="${Ws}" alt="reviewer assessing recovered Expert Advisor code and test evidence" style="width:100%;border-radius:8px;margin:24px 0;" />
8503
8504<h2 id="baseline-record">Create a Baseline Before Editing Anything</h2>
8505
8506<p>Good validation begins before the recovered code is compiled. Make a read-only archive containing the original EX4, the delivered MQ4, the delivery notes, and the settings that were used with the original EA. Record file names, file sizes, dates, and a checksum where the work matters. Keep a copy outside the active MT4 data folder. This makes it possible to return to an unaltered starting point after experiments, and it gives a maintainer a clear explanation of what was tested.</p>
8507
8508<p>Next, capture the operating context. Write down the MT4 build, broker server, account type, chart symbol, chart period, magic number, and all input values. Save the input set as a SET file where possible, but also export a plain record or screenshots. A set file can be overwritten or loaded into the wrong EA without an obvious warning. The record should include whether automated trading and DLL imports were enabled, whether the EA uses a custom indicator, and whether it reads files or web data.</p>
8509
8510<ol>
8511  <li><strong>Freeze the reference files.</strong> Copy the EX4 and recovered MQ4 to an archive with descriptive names. Do not test from the only copy.</li>
8512  <li><strong>Capture settings.</strong> Save inputs, symbol, period, broker server, account currency, leverage, and magic number.</li>
8513  <li><strong>List dependencies.</strong> Check the Experts, Indicators, Libraries, and Files folders for items the EA may call.</li>
8514  <li><strong>Preserve evidence.</strong> Save reports, journal exports, screenshots, and change notes in one dated folder.</li>
8515  <li><strong>Define the acceptance purpose.</strong> State whether the aim is maintenance, migration, audit, or authorized continuation of an existing EA.</li>
8516</ol>
8517
8518<p>A baseline is not paperwork for its own sake. Consider an EA that calculates lots using account currency, minimum volume, and a broker value. A test conducted on a different account type may produce altered volume even if the recovered formula 
8518is correct. Without a baseline, that difference may be mislabelled as a source-recovery issue. The same problem occurs when a symbol with a suffix, a changed spread, or a different stop level is quietly introduced.</p>
8519
8520<h3>Build a test ledger</h3>
8521
8522<p>A simple spreadsheet or text log is enough. Give each run an identifier, then record its EA filename, compiled date, test date range, model, symbol, period, inputs, deposit, spread assumption, and data source. Add the report location and a short conclusion. Do not rely on memory after several iterations. A ledger turns an ambiguous sequence of tests into evidence that another person can reproduce.</p>
8523
8524<h2 id="build-and-audit">Compile, Audit, and Control the Build</h2>
8525
8526<p>Copy the recovered MQ4 into a separate working directory and compile it in the intended MetaEditor environment. Preserve the compiler messages exactly. A clean compile is useful, but it is only the gate to further testing. Warnings deserve review because some point to conversions, unchecked return values, or old coding patterns that affect how a strategy behaves on a modern terminal. Errors must be resolved before any behavioral comparison can be trusted.</p>
8527
8528<p>Do not make broad cosmetic edits simply to make the code look tidy. Rename files carefully, retain a changelog, and use a new version label for every functional change. If a missing include, custom indicator, or library is discovered, source it from the authorized original environment rather than substituting an unknown download. A replacement indicator with the same name can produce very different buffers and signals.</p>
8529
8530<p>The first manual audit should focus on operational controls rather than trying to understand every line at once. Search for order functions, error handling, symbol strings, magic numbers, time checks, account and server checks, file access, DLL imports, and indicator calls. The guide to <a href="/blog/how-to-read-recovered-mql4-expert-advisor-code">understanding MQL4 after decompilation</a> provides useful context for interpreting reconstructed code and generic names.</p>
8531
8532<ul>
8533  <li>Confirm that every order function checks its result and logs a meaningful error.</li>
8534  <li>Identify whether the EA scans open orders by symbol and magic number, or by a broader rule.</li>
8535  <li>Check volume normalization against broker minimums, maximums, and step size.</li>
8536  <li>Note any hardcoded symbol, account, server, or date condition before changing it.</li>
8537  <li>Verify that custom indicators return expected values in the test terminal.</li>
8538  <li>Look for file paths, external feeds, and DLL calls that require explicit permissions.</li>
8539</ul>
8540
8541<p>These observations should be notes, not automatic fixes. For example, an account check might be a valid authorized-license feature, a safety control, or a sign that the source is intended for a specific environment. Removing a restriction without permission is not an acceptable validation step. If an authorized owner needs the EA to work at a new broker, document the business reason and preserve the original condition before making any approved maintenance change.</p>
8542
8543<h2 id="historical-comparison">Compare Historical Behavior, Not Headlines</h2>
8544
8545<p>Once the candidate build compiles and dependencies are understood, use the MT4 Strategy Tester to run controlled comparisons. Select the same symbol, period, date range, model, initial deposit, inputs, and available history for both the original EX4 and the candidate build. If the EA acts on ticks, use the most detailed modeling available in the same installation. If it is strictly bar based, retain the same bar-based model for both. Comparing reports created from different data or settings produces a misleading conclusion.</p>
8546
8547<p>Choose more than one period. A long period may reveal broad behavior, while shorter intervals can make investigation manageable. Include conditions that matter to the EA, such as quiet markets, elevated volatility, trend reversals, and different spread environments where the tester permits controlled assumptions. Do not select only the date range with the best historic result. Validation seeks coverage of logic paths, not a flattering equity curve.</p>
8548
8549<p>Start with a trade-level comparison. Export or inspect the order list and compare ticket sequence, direction, open time, close time, volume, entry, stop, target, and closing reason. A summary report should be reviewed after, not before, the trade list. Two reports can show similar profit while one version enter
8549s later, risks more volume, or exits under different conditions.</p>
8550
8551<img src="${Bu}" alt="comparison chart for reference EX4 and recovered MQL4 test runs" style="width:100%;border-radius:8px;margin:24px 0;" />
8552
8553<table style="width:100%;border-collapse:collapse;margin:16px 0;">
8554  <thead>
8555    <tr style="background:#f0f4ff;">
8556      <th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Compare first</th>
8557      <th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Why it matters</th>
8558      <th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Useful next step</th>
8559    </tr>
8560  </thead>
8561  <tbody>
8562    <tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Entry and exit timestamps</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">They expose signal and timing differences.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Trace the related condition and indicator value.</td></tr>
8563    <tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Direction and volume</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">They show whether risk logic changed.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Check lot sizing, normalization, and account inputs.</td></tr>
8564    <tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Stop and target values</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">They reveal pricing and point-value assumptions.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Inspect digits, point, spread, and stop-level handling.</td></tr>
8565    <tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Journal messages</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">They show rejected orders and silent branches.</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Save logs with the run identifier and investigate errors.</td></tr>
8566  </tbody>
8567</table>
8568
8569<p>If the two versions match closely across trade-level evidence, record that result without overstating it. It supports the conclusion that they behaved similarly under those conditions. It does not establish future profitability or prove every branch of the code has been exercised. If they differ, avoid editing until the difference has been classified. An unexplained difference is a reason to pause, not an invitation to tune inputs until the headline metrics match.</p>
8570
8571<h2 id="execution-simulation">Test Execution Conditions and Failure Paths</h2>
8572
8573<p>Historical comparison cannot show every issue that arises in a running terminal. Use a non-live environment to inspect execution behavior and deliberate failure paths. The goal is not to manufacture dramatic market events. It is to verify that the EA responds predictably to ordinary constraints: an unavailable symbol, a widened spread, insufficient margin, invalid volume, disabled trading, missing indicator data, or a temporary connection interruption.</p>
8574
8575<p>Review the Experts and Journal tabs after every session. A healthy chart icon does not mean a healthy EA. An EA can receive ticks and silently decline every trade because an input, time filter, symbol comparison, or account rule is wrong. Where possible, make logs clear enough to distinguish a valid no-trade decision from an operational failure. If the recovered code lacks useful logs, a qualified owner may add carefully scoped diagnostic messages in a separate test version, then repeat relevant comparisons.</p>
8576
8577<p>Pay special attention to broker details. Digits, point size, freeze levels, stop distance, contract size, lot steps, swap calculation, market sessions, and symbol suffixes can all affect an order. A recovered EA that references EURUSD literally may behave differently where the broker calls the instrument EURUSD.m. The correct response is to diagnose the assumption, not to conclude that all recovered code is unreliable.</p>
8578
8579<h3>Test state management</h3>
8580
8581<p>Many EAs behave differently after a restart than they do on their first tick. Test initialization with no open trades, with a simulated open position where appropriate, and after a terminal restart. Inspect how the EA identifies its own orders and whether it can reconstruct state from account history. Also check whether it creates duplicate orders after a reconnection. These tests should occur in a segregated environment so that a candidate build cannot interfere with an account or another EA.</p>
8582
8583<h2 id="parallel-observation">Run a Segregated Parallel Observation</h2>
8584
8585<p>After controlled historical tests, run the reference EX4 and candidate MQ4 in parallel on demo or otherwise non-live conditions. Use separate charts, the same symbol and period, matched inputs, and distinct magic numbers. Distinct magic numbers are essential because each instance must be able to identify only its own trades. If both versions manage the same position, the exercise no longer measures their independent behavior.</p>
8586
8587<p>There is no universal number of days that proves readiness. The observation should be long enough to cover the EA's typical decision cycle. A strategy that trades several times daily can create useful evidence sooner than one that opens a position once a month. 
8587Continue until the planned scenarios and normal signals have produced enough observations to examine, and record periods with no trades rather than calling them failures.</p>
8588
8589<p>Compare alerts, order attempts, filled trades, modified stops, and closures. Also compare the absence of action. If the reference declines a trade because its spread filter is active, the candidate should reveal a comparable reason. If an order is rejected, note the broker error and the attempted parameters. Parallel observation is valuable because it brings terminal timing and current broker conditions into the review without putting live capital at risk.</p>
8590
8591<img src="${zu}" alt="review panel examining parallel MQL4 Expert Advisor test results" style="width:100%;border-radius:8px;margin:24px 0;" />
8592
8593<h2 id="investigate-differences">Investigate Differences With Evidence</h2>
8594
8595<p>A difference is information, not necessarily a defect. Start with the test environment. Confirm that both charts use the same symbol spelling, period, input set, data feed, account characteristics, and terminal settings. Confirm that neither EA is reacting to the other one's orders. Then locate the earliest point at which behavior diverges. A single altered indicator value or rounding decision can lead to very different later trade histories.</p>
8596
8597<p>Classify the finding before deciding what to do. A compile error or missing dependency is an implementation blocker. A different entry time may point to a reconstructed condition, price series difference, or bar timing issue. A different volume may point to account settings or lot normalization. An unexpected refusal to trade may point to an authorized account rule. The classification determines whether the next step is a configuration correction, an authorized code review, a request for recovery clarification, or a decision not to deploy.</p>
8598
8599<p>Keep original and changed source separate. If an authorized maintainer adjusts a line, explain why, record the old and new behavior, recompile with a new file name, and rerun the relevant test set. Do not solve a mismatch by silently changing multiple lines. That may create a usable customized EA, but it no longer validates the recovery output.</p>
8600
8601<h2 id="release-decision">Make a Controlled Release Decision</h2>
8602
8603<p>The release decision should be written in plain language. It may be: suitable only for continued test, suitable for authorized maintenance but not trading, ready for a limited live observation under the owner's risk policy, or rejected pending investigation. A responsible decision names both the evidence and the remaining uncertainty. It should never claim that validation eliminates market risk.</p>
8604
8605<p>Before any live use, the owner should confirm permissions, make backups, verify the exact build and inputs, set an exposure limit consistent with their own policy, and monitor logs. A limited initial deployment can provide operational observation, but it is not a guarantee and should not be presented as one. If behavior differs, disable the candidate build, preserve the evidence, and investigate from the archived version.</p>
8606
8607<p>For readers evaluating recovery routes, the main review of an <a href="/">ex4 to mq4 decompiler</a> explains why output quality, process transparency, and realistic expectations matter. Readers planning a source-level migration may also find the article on <a href="/blog/mt4-ea-broker-symbol-name-mismatch-fix">MT4 symbol suffix EA compatibility</a> useful, since a working strategy can fail after a broker change for environmental reasons unrelated to recovery.</p>
8608
8609<h2 id="service-review">Where a Professional Recovery Review Fits</h2>
8610
8611<p>ForexMQ5 is positioned by this review site as a professional option for users with a documented and legitimate reason to recover MQL4 from an EX4. The relevant benefit is a structured recovery path rather than a claim that any file will be ready for live trading without review. A prudent customer should retain the original file, disclose relevant dependencies, confirm their rights, and test delivered output with a plan like the one above. Readers comparing professional and hands-on routes can consult the broader <a href="/">mql4 decompiler</a> review for context.</p>
8612
8613<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
8614  <h3 style="margin-top:0;">Review a Professional Recovery Option</h3>
8615  <p>ForexMQ5 is reviewed as a specialist option for authorized EX4 to MQ4 recovery. Any delivered source should remain subject to compilation, comparison, and controlled environment testing before deployment.</p>
8616  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
8617</div>
8618
8619<h2 id="questions">Questions About Testing Recovered MQL4</h2>
8620
8621<h3>Does a clean compile prove that the recovered EA is safe to run?</h3>
8622<p>No. A clean compile confirms that MetaEditor accepted the source in that environment. It does not confirm identical strategy behavior, correct dependencies, appropriate risk controls, or suitability for a live account. Continue with historical comparison, environment checks, and segregated observation.</p>
8623
8624<h3>Should the recovered code be optimized before it is compared?</h3>
8625<p>No. First compare the recovered build using the known reference inputs. Optimization changes the question from recovery validation to strategy development and makes discrepancies harder to explain. Keep any authorized improvement work in a separate version after the baseline is established.</p>
8626
8627<h3>What matters more than total profit in a comparison?</h3>
8628<p>Trade-level behavior is usually more revealing. Compare timing, direction, volume, stops, targets, modifications, exits, and logged errors. Total profit can look similar even when risk management or execution behavior has changed.</p>
8629
8630<h3>Can a demo observation reproduce live execution exactly?</h3>
8631<p>No. Demo and live accounts can differ in execution and operating conditions. A segregated observation is still useful because it can reveal configuration, symbol, timing, and order-management issues before live capital is exposed. It should be treated as evidence with limits.</p>
8632
8633<h3>What should happen when the candidate EA behaves differently?</h3>
8634<p>Pause the release decision, preserve the run details, and identify the earliest divergence. Check environment and inputs first, then examine the relevant calculation or dependency. If the issue cannot be explained within the authorized scope, seek qualified technical review or clarification rather than deploying an uncertain build.</p>
8635
8636<p>The central lesson is simple: validate recovered MQL4 as a controlled engineering project. Preserve the baseline, compare observable behavior, test the operating environment, record differences, and make a limited decision based on evidence. That process cannot remove trading risk, but it can prevent a recoverable source file from being mistaken for a proven live system.</p>
8637    `},{slug:"mt4-ea-broker-symbol-name-mismatch-fix",title:"MT4 EA Broker Symbol Name Mismatch: Diagnose Suffixes, Prefixes, and Silent Trade Failures",metaTitle:"Fix MT4 EA Symbol Name Mismatches After a Broker Change",metaDescription:"Find and fix MT4 Expert Advisor failures caused by broker symbol suffixes, prefixes, and renamed instruments. Learn practical checks, source-code repairs, and safer testing steps.",keywords:"MT4 EA symbol name mismatch, broker symbol suffix fix, Expert Advisor not trading after broker change, EURUSD.m EA compatibility, MQL4 symbol prefix and suffix",excerpt:"An EA can be attached, enabled, and apparently healthy while a broker symbol name mismatch prevents it from finding prices, indicators, or trading permissions. This practical guide explains how to identify suffix and prefix issues, choose the right repair path, and test the result carefully.",date:"July 14, 2026",dateISO:"2026-07-14",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"16 min read",featuredImage:In,imageAlt:"trader checking MT4 Expert Advisor settings after a broker symbol name change",tableOfContents:[{id:"silent-mismatch",title:"Why an Attached EA Can Still Be Looking at the Wrong Instrument"},{id:"map-broker-names",title:"Map the Broker's Exact Instrument Names First"},{id:"trace-symbol-dependency",title:"Where MQL4 Programs Depend on Symbol Names"},{id:"separate-causes",title:"Separate a Naming Fault From Other Trading Blocks"},{id:"no-source-options",title:"Practical Options When Only an EX4 Is Available"},{id:"source-repair",title:"Source-Level Repairs That Survive a Broker Move"},{id:"multi-pair-design",title:"A Safer Design for Multi-Pair Expert Advisors"},{id:"validation-plan",title:"Validate the Repair Before Any Live Use"},{id:"recovery-review",title:"Reviewing the Source-Recovery Route"},{id:"questions",title:"Common Questions About MT4 Symbol Compatibility"}],content:`
8638<p>A broker migration can create a confusing MT4 problem: an Expert Advisor loads onto the chart, AutoTrading is enabled, the account connection is normal, and yet the program never opens a position. Users often begin by changing lot size, reinstalling the terminal, or assuming that the strategy has stopped producing signals. Those checks can matter, but a simpler explanation deserves attention early. The EA may be requesting an instrument name that does not exist on the new server.</p>
8639
8640<p>Forex pairs have familiar market labels, but MT4 does not trade a generic concept called EURUSD. It trades the exact server symbol supplied by the broker. One server may offer EURUSD, another EURUSD.m, EURUSDpro, mEURUSD, EUR/USD, or a label that also reflects an account group. Metals, indices, energies, and cryptocurrencies can be renamed even more dramatically. An EA written around one spelling can fail quietly when it encounters another.</p>
8641
8642<p>This review-site guide treats the issue as a compatibility investigation, not as a claim that every inactive EA has a suffix fault. A name mismatch is only one possible cause. Trading hours, spreads, margin, permission settings, a signal condition, a missing library, and broker trading rules can also stop an order. The useful approach is to establish the exact symbol map, locate the program's depen
8642dency on that map, and test the smallest appropriate correction in a controlled environment.</p>
8643
8644<img src="${In}" alt="trader inspecting MT4 symbol names and EA settings after changing brokers" style="width:100%;border-radius:8px;margin:24px 0;" />
8645
8646<h2 id="silent-mismatch">Why an Attached EA Can Still Be Looking at the Wrong Instrument</h2>
8647
8648<p>MT4 separates several things that users may casually call the pair. There is the chart symbol, the exact text returned by <code>Symbol()</code>, the symbols visible in Market Watch, and any strings stored inside the EA. They match in a carefully designed single-chart EA. They do not always match in older robots, multi-currency systems, panel-based tools, or programs originally configured for a particular broker.</p>
8649
8650<p>For example, a robot can be attached to an EURUSD.m chart while its entry routine calls <code>OrderSend("EURUSD", ...)</code>. The chart receives ticks and the EA's icon may show a smiling face. However, the order function is directed to EURUSD, which is absent. A different program may calculate a moving average using EURUSD, receive no usable series, and then decide no entry exists. Another may exit at the start of every tick because it checks whether <code>Symbol() == "EURUSD"</code>.</p>
8651
8652<p>That is why visible attachment is not proof of operational compatibility. Attachment tells the user that MT4 loaded the compiled program. It does not prove that every required instrument, price stream, order property, or external dependency is valid. The Experts and Journal tabs are valuable evidence, but silence there is not conclusive either. Some EAs handle errors poorly, clear them before logging, or simply return when a price lookup is zero.</p>
8653
8654<p>The problem is broader than a dot suffix. A prefix such as mEURUSD can create the same fault. So can different names for gold, for example XAUUSD versus GOLD, or cash indices distinguished from futures by a broker-specific label. A program that trades several markets may find one pair and fail on the rest. This is why diagnosis should start with exact strings rather than assumptions about what a market ought to be called.</p>
8655
8656<h2 id="map-broker-names">Map the Broker's Exact Instrument Names First</h2>
8657
8658<p>Before changing an input or seeking a code repair, create a short symbol inventory. Open Market Watch, use the Symbols dialog if needed, and write down the name exactly as the terminal displays it. Capitalization, punctuation, leading text, and trailing text all matter when a program compares strings. Confirm that the desired instruments are enabled and that their charts receive current quotes during the relevant session.</p>
8659
8660<ol>
8661  <li><strong>Record the chart name.</strong> Right-click the chart and confirm the symbol in its title. Do not infer it from a familiar-looking price chart.</li>
8662  <li><strong>Inspect Market Watch.</strong> Find each market the EA may trade, including cross pairs used for filters or calculations. Save a screenshot or a written list.</li>
8663  <li><strong>Check contract details.</strong> The Specification window can reveal digits, minimum volume, stop levels, and trading sessions. These do not create a suffix mismatch, but they can expose a separate broker-change issue.</li>
8664  <li><strong>Compare account types carefully.</strong> A demo, standard, micro, ECN, and spread-betting account at the same brand can publish different symbols.</li>
8665  <li><strong>Keep the old map if available.</strong> A screenshot from the previous terminal makes the difference obvious and helps a developer reproduce the condition.</li>
8666</ol>
8667
8668<p>A common trap is testing only the chart pair. A multi-pair EA might be attached to EURUSD.m and correctly obtain that chart's price, yet scan GBPUSD, USDJPY, and XAUUSD using unsuffixed names. The visible chart setup then looks correct while the strategy's internal basket is incomplete. Inventory every reference that the strategy is expected to use, not just the market where the EA is attached.</p>
8669
8670<p>Some brokers also use symbols that look almost identical but represent different c
8670ontract types. A cash index, a mini contract, and a futures contract may share a recognizable root but have distinct margin, trading-hour, and pricing characteristics. A compatibility repair should target the intended instrument, not merely the first name that resembles it. Replacing strings blindly can alter the strategy's market exposure.</p>
8671
8672<img src="${_u}" alt="warning signs of an MT4 EA symbol suffix or prefix mismatch" style="width:100%;border-radius:8px;margin:24px 0;" />
8673
8674<h2 id="trace-symbol-dependency">Where MQL4 Programs Depend on Symbol Names</h2>
8675
8676<p>With source code, a text search for known pair names is an efficient beginning. Search for EURUSD, GBPUSD, XAUUSD, the old suffix, and string variables with names such as Pair, SymbolName, TradeSymbol, or Suffix. The goal is not to replace every match immediately. Each occurrence has a different purpose and needs to be understood in context.</p>
8677
8678<h3>Order placement and modification</h3>
8679
8680<p>Functions such as <code>OrderSend</code>, <code>OrderClose</code>, and <code>OrderModify</code> interact with trade records or an instrument. A hardcoded name in an order-entry call is a direct compatibility risk. Existing-order loops can be just as important. If an EA opens an order on EURUSD.m but later searches only for EURUSD orders, it may miscount positions, fail to manage stops, or duplicate an entry.</p>
8681
8682<h3>Indicators and price data</h3>
8683
8684<p>Indicator functions can accept a symbol argument. In a single-chart strategy, using <code>NULL</code> commonly tells the function to use the current chart instrument. That is usually clearer than copying a fixed name. In multi-pair work, the correct choice is an explicitly resolved broker symbol. A zero, an unavailable series, or stale history should be treated as a condition to report and handle, not as a valid trading signal.</p>
8685
8686<h3>String comparisons and allowed-market lists</h3>
8687
8688<p>Many EAs restrict use to named markets. The restriction can be an understandable safety feature, but exact comparisons break after a naming change. A list like EURUSD, GBPUSD, and USDJPY may need a configuration layer rather than a direct comparison to the chart string. License, account, and broker checks are different from a simple compatibility list. A user should not attempt to remove restrictions that they are not entitled to alter.</p>
8689
8690<h3>File names, comments, and reporting</h3>
8691
8692<p>Symbol names sometimes appear in file paths, chart-object names, alerts, or CSV reports. These cases may not stop trading, but they can cause confusing duplicates or missing records after a move. Review them after the order and signal paths. A repair that opens trades correctly but writes reports under an obsolete name can still complicate later auditing.</p>
8693
8694<p>Readers who need a foundation for interpreting functions, variables, and control flow can consult <a href="/blog/how-to-read-recovered-mql4-expert-advisor-code">this guide to understanding recovered MQL4 code</a>. It helps separate a cosmetic string from a name that drives a live calculation or trade operation.</p>
8695
8696<h2 id="separate-causes">Separate a Naming Fault From Other Trading Blocks</h2>
8697
8698<p>It is tempting to declare victory as soon as EURUSD.m appears in Market Watch. Instead, use observations to rule in or rule out the mismatch. Attach the EA to the exact broker-provided chart, enable the settings it requires, and inspect its messages while the market is open. Errors relating to an unknown symbol, unavailable price, or an invalid selected market support the hypothesis. A message about insufficient funds, an invalid stop, disabled trading, or a time filter points elsewhere.</p>
8699
8700<p>Check the EA input window before assuming the compiled file is rigid. Better-built products expose configurable fields such as TradeSymbol, Suffix, Prefix, Symbols, or UseChartSymbol. If an input exists, enter the exact broker name and save a separate set file labelled for that broker and account type. Do not change a global default without recording the previous setting. The input workaround is the least invasive option when it is genuinely supported by the program.</p>
8701
8702<p>Next, consider the strategy itself. An EA may simply have no valid signal. Compare its behavior in the old environment if records exist, and use visual mode or diagnostic logging where available. A suffix correction should be evaluated by confirming successful symbol discovery and consistent calculations, not by expecting an immediate trade. No one can responsibly infer future trading results from a compatibility change alone.</p>
8703
8704<p>Finally, examine broker constraints. Different minimum lots, volume increments, freeze levels, stop distances, sessions, and filling conditions can prevent a valid order even after a symbol resolves. A sound diagnostic note distinguishes these facts. It should say, for example, that EURUSD.m was not found by an old lookup, then state whether the revised lookup found a current quote and whether the final order request met broker requirements.</p>
8705
8706<img src="${Rn}" alt="checklist for isolating MT4 EA symbol naming issues from other broker constraints" style="width:100%;border-radius:8px;margin:24px 0;" />
8707
8708<h2 id="no-source-options">Practical Options When Only an EX4 Is Available</h2>
8709
8710<p>An EX4 is compiled output. MT4 can execute it, but users cannot edit its internal strings in MetaEditor. That limitation makes it important to exhaust supported configuration options before considering any source-level route.</p>
8711
8712<ul>
8713  <li><strong>Use the exact chart symbol.</strong> Attach the EA to EURUSD.m rather than an assumed EURUSD chart, then verify the program is allowed to trade.</li>
8714  <li><strong>Review documented inputs.</strong> Change only published symbol, prefix, or suffix fields, and retain a copy of the original set file.</li>
8715  <li><strong>Ask the original developer or vendor.</strong> An updated build, a broker-specific set file, or a documented naming method may already exist.</li>
8716  <li><strong>Ask the broker a precise question.</strong> Support may confirm the intended symbol spelling and whether another account group has a different instrument list. The broker cannot ordinarily rewrite a third-party EA.</li>
8717  <li><strong>Choose a supported alternative.</strong> If the robot is limited to a server naming convention and no authorized update exists, a compatible account or a different EA may be safer than an improvised workaround.</li>
8718</ul>
8719
8720<p>Terminal features that create custom symbols should be approached with care. A local alias can be useful for charting or analysis, but it may not make a hardcoded EA tradeable. It does not change what the trade server recognizes, and it can introduce a misleading test condition. Confirm actual order behavior on the broker's permitted symbol rather than relying on an alias alone.</p>
8721
8722<p>There is also an ownership boundary. A user who merely purchased a running license may have the right to configure the EA, but not the right to inspect, modify, bypass, distribute, or reconstruct its source. The sensible route is written authorization from the rightsholder or an official update. This guide discusses technical options only for users who own the code or have clear permission to maintain it.</p>
8723
8724<h2 id="source-repair">Source-Level Repairs That Survive a Broker Move</h2>
8725
8726<p>When the owner has MQ4 source, the most durable fix is usually to remove unnecessary fixed names. A single-symbol EA attached to a chart can obtain the active instrument with <code>Symbol()</code>. Indicator calls that should use that chart can commonly use <code>NULL</code>. The following simplified pattern expresses the idea:</p>
8727
8728<pre style="background:#f0f4ff;padding:16px;border-radius:6px;overflow-x:auto;font-size:13px;">string tradeSymbol = Symbol();
8729double average = iMA(NULL, 0, 20, 0, MODE_EMA, PRICE_CLOSE, 0);
8730
8731if(MarketInfo(tradeSymbol, MODE_BID) &gt; 0) {
8732  // Build and validate the order using the active chart symbol.
8733}</pre>
8734
8735<p>This is not a universal search-and-replace recipe. A multi-pair strategy may intentionally use a market other than the chart symbol, and an order-management module may need to inspect the symbol of an existing order. The repair should preserve the strategy's stated intent. Replace a hardcoded market only after identifying whether it means the current chart, a configured basket member, a correlation input, or a deliberate instrument restriction.</p>
8736
8737<p>Add explicit startup validation. For every configured market, attempt to select it and retrieve a sensible quote. If a name cannot be resolved, log a clear message that includes the requested string and the available configuration. Then prevent new entries rather than continuing with zero values. Clear diagnostics are more useful than a robot that appears active but ignores every tick.</p>
8738
8739<p>Use inputs for genuine configuration. A simple design can offer a prefix and suffix field, or a complete per-pair mapping such as EURUSD=EURUSD.m. Complete mapping is clearer when names are irregular. It also avoids guessing that every pair shares the same suffix. Comments in the input panel should explain that values must exactly match Market Watch.</p>
8740
8741<p>The site’s overview of <a href="/">MQL4 decompiler options</a> explains why recovered code quality and manual review matter before anyone treats a compiled file as maintainable source. A reconstructed project can need cleanup, dependency review, and careful compilation before a targeted naming change is safe to test.</p>
8742
8743<h2 id="multi-pair-design">A Safer Design for Multi-Pair Expert Advisors</h2>
8744
8745<p>Multi-pair EAs need a resolver rather than a casual suffix guess. Taking the last two characters from the current chart is unreliable because suffix lengths vary and prefixes are common. Instead, keep a list of intended base markets and a mapping of the actual broker names. Validate each mapping at initialization, expose it through inputs, and show the resolved list in the log.</p>
8746
8747<p>A practical workflow has four stages. First, define the strategy's logical markets, such as EURUSD and GBPUSD. Second, map each logical market to the exact server symbol for the current account. Third, confirm selection and price availability before calculating indicators. Fourth, use the resolved name consistently in data requests, order operations, filtering, and reporting. This makes the broker-specific detail visible in one place instead of scattering literal strings through the program.</p>
8748
8749<p>It is worth separating a display label from the execution symbol. A dashboard may show the familiar EURUSD label to a human, while all calls use EURUSD.m under the hood. This avoids hiding the broker detail while keeping reports readable. If a broker 
8749change occurs later, the mapping changes while the strategy's core logic remains easier to inspect.</p>
8750
8751<p>Do not assume that symbols alone are enough for portability. Digits, point size, contract size, minimum distance, and trading session conditions also belong in validation. A robust EA reads available broker properties at runtime and declines an order when its calculated parameters do not comply. That behavior does not guarantee a strategy's suitability, but it makes operational failure easier to diagnose.</p>
8752
8753<h2 id="validation-plan">Validate the Repair Before Any Live Use</h2>
8754
8755<p>A repaired name should be treated as a software change. Compile the MQ4 in MetaEditor and resolve warnings that could affect the modified path. Keep an untouched copy of the original source and EX4. Record the change, the broker symbol map, the account type, terminal build, and date. These records make it possible to reverse a mistaken configuration and explain what changed later.</p>
8756
8757<ol>
8758  <li>Run the EA on a demo account that uses the target broker server and account group.</li>
8759  <li>Confirm every configured market can be selected and has current quotes during its trading session.</li>
8760  <li>Read initialization and diagnostic messages, looking for the resolved symbols rather than relying on a chart label.</li>
8761  <li>Use a suitable historical or visual test only when the EA's design supports it, and check that all intended instruments are represented.</li>
8762  <li>Observe order calculation, stop validation, and position management under demo conditions before considering any live deployment.</li>
8763</ol>
8764
8765<p>Testing is not a promise that the EA will make money or behave identically across brokers. Price feeds, execution, spreads, and contract rules can differ even when the symbol text has been corrected. The purpose is narrower: establish that the program references valid instruments and handles the broker environment without the known naming fault. For a deeper process, see <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">the checklist for testing decompiled MQL4 before live trading</a>.</p>
8766
8767<img src="${Uu}" alt="MT4 Expert Advisor operating on a correctly mapped broker symbol after compatibility testing" style="width:100%;border-radius:8px;margin:24px 0;" />
8768
8769<h2 id="recovery-review">Reviewing the Source-Recovery Route</h2>
8770
8771<p>When an authorized owner has lost the MQ4 and a documented input cannot solve the problem, source recovery may be considered as a maintenance route. ForexMQ5 is positioned by this review site as a professional EX4-to-MQ4 recovery option for customers able to confirm their right to request the work. Its relevance in this situation is not a claim that recovered output automatically solves broker compatibility. The output still requires inspection, a narrow code change, compilation, and testing by someone who understands the strategy and the target server.</p>
8772
8773<p>A careful requester should preserve the original EX4, set files, screenshots of Market Watch, and evidence of ownership or authorization. They should state the maintenance purpose accurately and avoid requests to remove licensing controls or copy a third party’s strategy. Once source is available, a developer can identify whether the issue is a hardcoded name, an input default, a market list, or a broader compatibility limitation. That distinction is more useful than treating all inactive robots as identical.</p>
8774
8775<p>For context on the technical paths available before a recovery decision, the site’s <a href="/">ex4 to mq4 decompiler</a> review compares professional assistance with hands-on alternatives and explains why authorization and manual validation remain essential.</p>
8776
8777<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
8778  <h3 style="margin-top:0;">Review an Authorized EX4 Recovery Option</h3>
8779  <p>ForexMQ5 is reviewed as a specialist option for owners and authorized users who need MQL4 available for a legitimate maintenance review. Any recovered code should be validated against the target broker before use.</p>
8780  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
8781</div>
8782
8783<h2 id="questions">Common Questions About MT4 Symbol Compatibility</h2>
8784
8785<h3>Does EURUSD.m always mean the EA will fail?</h3>
8786<p>No. An EA that uses <code>Symbol()</code>, supports a symbol input, or maps broker names properly can work with EURUSD.m. The suffix becomes a problem only when the program expects a different string or applies incompatible rules around that market.</p>
8787
8788<h3>Can changing the chart name fix a hardcoded multi-pair EA?</h3>
8789<p>Not necessarily. It can solve a single-chart EA that correctly relies on the chart symbol. It cannot correct fixed names used for other pairs, indicators, order filtering, or a direct comparison in the code.</p>
8790
8791<h3>Should a trader replace every occurrence of EURUSD in source?</h3>
8792<p>No. Each occurrence should be reviewed. Some strings may be display text, comments, report labels, or intentional configuration values. A broad replacement can introduce a different defect or change how the strategy is meant to operate.</p>
8793
8794<h3>Is a suffix correction enough to make an EA broker independent?</h3>
8795<p>It is an important improvement, not a complete guarantee. Broker portability also depends on trade rules, pricing precision, volume rules, available history, session schedules, and the EA's own assumptions.</p>
8796
8797<p>The practical conclusion is straightforward. Treat the broker’s instrument spelling as real operating data, not as a cosmetic chart label. Map it exactly, test the supported settings, identify the actual dependency, and make only authorized, well-documented source changes. That sequence turns a silent compatibility mystery into a manageable engineering check.</p>
8798    `},{slug:"expert-advisor-vps-transfer-audit-mt4",title:"MT4 Expert Advisor VPS Transfer Audit: A Controlled Checklist for Settings and Dependencies",metaTitle:"MT4 Expert Advisor VPS Transfer Checklist: Audit Settings and Dependencies",metaDescription:"Plan an MT4 Expert Advisor VPS transfer with a practical audit of files, inputs, permissions, broker conditions, testing, and cutover records before live use.",keywords:"MT4 Expert Advisor VPS transfer, MT4 VPS migration audit, EA settings backup, move MT4 EA to new VPS, MT4 EA dependencies",excerpt:"An MT4 terminal can be copied while the operating setup is not. This detailed transfer audit helps traders capture EA settings, files, permissions, broker conditions, and validation evidence before changing VPS.",date:"August 24, 2026",dateISO:"2026-08-24",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"17 min read",featuredImage:Rn,imageAlt:"auditing an MT4 Expert Advisor before transferring it to a new VPS",tableOfContents:[{id:"transfer-is-a-system-change",title:"Treat the Transfer as a System Change"},{id:"capture-baseline",title:"Capture the Working Baseline"},{id:"build-inventory",title:"Build an Inventory Instead of Copying Blindly"},{id:"protect-state",title:"Protect Trading State and Open Positions"},{id:"prepare-terminal",title:"Prepare the Destination Terminal"},{id:"restore-components",title:"Restore Components in the Right Order"},{id:"compare-broker",title:"Compare Broker and Account Conditions"},{id:"permissions-licenses",title:"Check Permissions, Licenses, and Security"},{id:"prove-operation",title:"Prove Operation Before Live Cutover"},{id:"cutover-record",title:"Make the Cutover Reversible"},{id:"recovery-choice",title:"When Missing Source Changes the Plan"},{id:"questions",title:"MT4 VPS Transfer Questions"}],content:`
8799<p>An MT4 Expert Advisor transfer is often described as a file move. That description is incomplete. A running terminal is a small operating environment made of an account connection, a chart arrangement, input values, indicators, files, permissions, Windows settings, and sometimes vendor checks. A new VPS can display the same chart and still behave differently. The result may be an EA that never starts, an EA that cannot trade, or an EA that follows a different symbol or schedule than expected.</p>
8800
8801<p>This guide approaches a VPS change as an audit and controlled handover. It is intended for a trader moving an established MT4 setup to another Windows VPS, a replacement server, or a new broker terminal. It does not promise that a robot will be profitable or suitable for a live account. Its purpose is narrower and more useful: help the operator demonstrate that the destination resembles the known working environment before the old environment is retired.</p>
8802
8803<p>ForexMQ5 is reviewed here as a specialist option when an authorised owner needs readable MQL4 for a legitimate maintenance problem. That review-site position does not make source recovery necessary for every transfer. Most migrations succeed through careful records and complete file handling. The key is to i
8803dentify what the EA actually needs before an interruption makes that information difficult to recover.</p>
8804
8805<img src="${Rn}" alt="auditing files and settings before an MT4 Expert Advisor VPS transfer" style="width:100%;border-radius:8px;margin:24px 0;" />
8806
8807<h2 id="transfer-is-a-system-change">Treat the Transfer as a System Change</h2>
8808
8809<p>Start with the assumption that the old VPS is the reference system. It is not merely a place where an EX4 happens to sit. Its terminal may have accumulated templates, history, custom indicators, data files, permissions, and configuration choices over months. Some items are visible in MT4. Others are only revealed in the Experts log, the terminal data folder, or the EA inputs.</p>
8810
8811<p>That framing changes the work. Instead of asking, “Which folder contains the EA?”, ask, “What conditions must exist for the EA to make the same decisions?” The answer may include its chart symbol, timeframe, magic number, spread filter, trading-session hours, news filter file, and a DLL or indicator library. It may also include a broker-specific suffix such as EURUSD.a, a minimum stop level, or a server clock offset.</p>
8812
8813<p>Set a short change window and decide who has authority to pause automated trading. If open positions are managed by the EA, note whether the old terminal must remain available until those positions close. If the EA places only entries, disabling it before the new setup is validated may be simpler. Never allow two terminals running the same logic on the same account without understanding their magic-number and order-management rules. Duplicate instances can both react to the same market event.</p>
8814
8815<p>A simple written scope keeps the transfer focused. Record the source VPS, destination VPS, terminal build, broker server, account type, intended cutover time, and every chart that will move. Give the task a status such as planned, copied, verified, or live. This record is especially valuable when several EAs, manual charts, or more than one person are involved.</p>
8816
8817<h2 id="capture-baseline">Capture the Working Baseline</h2>
8818
8819<p>The best time to document a setup is while it is visibly working. Before touching the old machine, create a baseline that a later operator can compare with the destination. Screenshots help, but a written record is easier to search and less likely to omit an important input. Save the record outside the VPS as well as on it.</p>
8820
8821<p>For each EA chart, capture the symbol exactly as MT4 writes it, the timeframe, the EA filename, and the template name. Open the Inputs tab and save its values as a set file where appropriate. A screenshot of the tab is still worthwhile because it shows enabled checkboxes and provides a second reference. Note whether AutoTrading is enabled globally and whether “Allow live trading,” “Allow DLL imports,” and “Allow WebRequest” are enabled for that specific attachment.</p>
8822
8823<p>Then inspect the Experts and Journal tabs. A normal startup message, license notice, missing-file warning, or connection error can become the most useful comparison point later. Copy relevant lines with their timestamps. If the EA shows a panel on the chart, capture it. Do not assume a smiling icon proves that an order can be sent. The log and permissions reveal more about operational readiness.</p>
8824
8825<p>The baseline should also include account context: broker name, server label, account number, account currency, leverage, account type, and whether the login is trading-enabled rather than investor access. Record the terminal build and Windows time zone. A time-sensitive strategy may use broker time, local time, GMT calculations, or a mixture of them. The old terminal's displayed Market Watch time offers useful evidence, but it does not explain the EA's implementation by itself.</p>
8826
8827<h3>Make a chart card</h3>
8828
8829<p>A compact chart card prevents details from being scattered across screenshots. One card per EA can list the following:</p>
8830
8831<ul>
8832<li>EA file name, version shown, symbol, timeframe, and magic number.</li>
8833<li>Input set file name, risk inputs, session inputs, and any changed defaults.</li>
8834<li>Required custom indicators, scripts, include files, libraries, and data files.</li>
8835<li>Current open orders, pending orders, and whether the EA manages them.</li>
8836<li>Expected startup message, last successful action, and known warnings.</li>
8837<li>Owner or vendor contact route for an authorised license or activation question.</li>
8838</ul>
8839
8840<p>This is also a sensible moment to check whether the terminal contains an old build of the EA rather than the file believed to be in use. Compare names, dates, and any displayed version information. A folder can hold several nearly identical EX4 files. Moving the wrong one is a common and avoidable mistake.</p>
8841
8842<h2 id="build-inventory">Build an Inventory Instead of Copying Blindly</h2>
8843
8844<p>MT4 has an installation folder and a terminal data folder. They are not always the same location, particularly with modern installations or multiple terminal instances. From MT4, use File, Open Data Folder to identify the live data directory. Inventory from there rather than guessing based on a desktop shortcut.</p>
8845
8846<p>The MQL4 folder deserves a deliberate review. Experts contains EAs, Indicators contains custom indicators, Libraries can contain compiled libraries, Include can contain source dependencies, and Files may contain CSV, text, or configuration data read at runtime. Some EAs use Common Files, which is shared across terminals on the same Windows machine. A migration that copies only Experts can silently omit the rest of the system.</p>
8847
8848<p>Profiles and templates matter because they reconstruct charts and attachments. A profile may contain several charts with different EAs. Templates may carry indicator settings and chart presentation that make checking easier. Save copies of relevant profiles, templates, set files, and any manually maintained data. If a calendar, holiday list, license file, or instrument map is updated regularly, note its source and current date rather than treating one copied version as permanent.</p>
8849
8850<p>Keep original copies read-only in an archive with a date in its name. A checksum is helpful for important EX4s, DLLs, and data files because it distinguishes a verified copy from a later edited copy. The archive should not include passwords in plain text. Account credentials should be transferred using a secure method approved by the account holder, not embedded in a migration spreadsheet or sent in an ordinary message.</p>
8851
8852<p>Readers who are unsure what a compiled file represents can consult the site’s <a href="/blog/ex4-files-explained-for-mt4-users">guide to EX4 files for MT4 users</a>. It explains why an EX4 is only one part of a deployable trading setup. For transfer work, the practical lesson is straightforward: inventory the surrounding files and environment, not only the executable-looking file.</p>
8853
8854<h2 id="protect-state">Protect Trading State and Open Positions</h2>
8855
8856<p>Open positions turn a technical migration into an operational decision. First identify whether the EA manages open trades by symbol, ticket number, 
8856comment, magic number, or a file-based record. A destination instance may need to discover existing orders without placing a new entry. Conversely, a newly attached EA may interpret its first tick as permission to trade if its state is missing or its logic has no duplicate-entry protection.</p>
8857
8858<p>Export or record open and pending orders before the move. Include ticket, symbol, direction, volume, open price, stop loss, take profit, comment, and magic number. Capture account history around the latest EA activity. This evidence gives the operator a way to confirm whether the destination recognised the existing state. It does not replace broker records, but it creates an immediate comparison list.</p>
8859
8860<p>Choose one operating model for the cutover. The conservative model pauses new entries, leaves the old terminal responsible for existing orders, and moves the EA only after it is flat. Another model transfers management during a defined window after testing on a non-trading chart or separate account. The right model depends on the EA design and the operator's risk process. It should be selected in advance, not improvised while a market is moving.</p>
8861
8862<p>Do not close positions simply because a VPS is being replaced unless that action fits the account's own plan. Likewise, do not assume a reboot preserves every internal variable. Some EAs rebuild state from orders; others rely on files or global variables. The baseline and vendor documentation should guide that decision.</p>
8863
8864<h2 id="prepare-terminal">Prepare the Destination Terminal</h2>
8865
8866<p>Install MT4 from the correct broker or obtain the exact approved terminal distribution. A generic terminal can be useful for inspection, but it may not include the intended broker server list or account conditions. Install it under a Windows account with appropriate access and confirm that the VPS has sufficient disk space, stable network access, and a clock set to the intended time zone.</p>
8867
8868<p>Open the destination terminal once before copying custom components. Log into the correct account or an appropriate test account and let the terminal connect. Confirm the server name, account status, and Market Watch symbols. Then use File, Open Data Folder. This avoids placing migration files into an installation path that the running terminal does not use.</p>
8869
8870<p>Update awareness matters. Terminal builds can differ in compiler behavior, security handling, and broker connectivity. Record the destination build and avoid an unplanned terminal update in the middle of validation. That is not an argument against updates. It is a change-control principle: introduce one material change at a time so a later discrepancy has a plausible cause.</p>
8871
8872<p>Configure operational basics before attaching an EA. Set the intended time zone if local-time logic is documented, prevent unwanted sleep or automatic shutdown, and verify that the VPS provider permits the normal Windows functions needed by the terminal. Remote desktop disconnecting is not the same as the VPS shutting down, but a locked or restarted system can affect automation. Check that the terminal reconnects after a planned restart.</p>
8873
8874<h2 id="restore-components">Restore Components in the Right Order</h2>
8875
8876<p>Restore the inventory in layers, then restart MT4 so it scans the files. Begin with custom indicators, libraries, and required data files. Next copy the authorised EA files and set files. Restore templates and profiles only after their referenced components are present. This order produces clearer error messages than loading a profile before its dependencies exist.</p>
8877
8878<p>Use the Navigator panel to confirm that each expected EA and indicator appears. If something is absent, return to the data-folder path before downloading a substitute. A renamed file, nested folder, or wrong terminal directory is more common than a damaged file. Check the Experts and Journal tabs immediately after attachment. Messages about missing indicators, failed file opens, disabled DLL calls, or invalid parameters are signals to stop and resolve the difference.</p>
8879
8880<p>Some automated systems call a WebRequest endpoint for licensing, news data, or a remote filter. Add only documented URLs to MT4’s allowed WebRequest list, and verify the address carefully. Do not weaken Windows security controls, disable antivirus protection wholesale, or add unknown endpoints merely to silence an error. If a component is blocked, establish why it is required and obtain it from the authorised source.</p>
8881
8882<img src="${ap}" alt="inspecting Expert Advisor dependencies and migration settings in MT4" style="width:100%;border-radius:8px;margin:24px 0;" />
8883
8884<h2 id="compare-broker">Compare Broker and Account Conditions</h2>
8885
8886<p>A move to a different VPS may also involve a different broker server or account. That is a larger change than a hosting transfer. Compare the exact tradeable symbol names, digits, contract specification, minimum and maximum volume, volume step, stop distance, freeze level, spreads, commissions, swaps, and trading-session availability. An EA designed for EURUSD may fail if the destination presents EURUSDm, or it may calculate price distances incorrectly when digits differ.</p>
8887
8888<p>Do not correct a mismatch by casually editing an EX4 or guessing an input. Look first for a documented symbol mapping or broker setting. If a source-supported EA exposes a symbol input, record the original value and the reason for a controlled test value. If it has no suitable configuration, an authorised developer or vendor may need to assess compatibility.</p>
8889
8890<p>History and chart data influence indicators and startup logic. Allow charts to load sufficient history and compare indicator values at the same point in t
8890ime when possible. A destination chart with limited bars can produce a different signal without any error in the EA. This is particularly relevant to systems using moving averages, multi-timeframe indicators, or a lookback filter.</p>
8891
8892<p>The homepage’s overview of an <a href="/">MT4 EA decompiler</a> can help owners distinguish compiled-code recovery from ordinary terminal configuration. For a typical VPS move, an EX4 should remain unaltered. The task is to reproduce its supported operating conditions, not to modify code to force an uncertain environment to fit.</p>
8893
8894<h2 id="permissions-licenses">Check Permissions, Licenses, and Security</h2>
8895
8896<p>MT4 has multiple permission layers. The global AutoTrading control can be off while a chart attachment looks normal. The EA’s Common tab can prohibit live trading, DLL imports, or external calls. The account itself may be read-only. A vendor license may be tied to an account number, broker, hardware characteristic, IP address, or expiration date. Check each layer explicitly and preserve any authorized activation record.</p>
8897
8898<p>A license issue should go to the vendor or rights holder through its documented support path. Copying a license file from one server to another may be permitted, prohibited, or ineffective depending on the agreement. It is not appropriate to bypass account locks, activation checks, expiry controls, or other technical restrictions. A legitimate migration can still require a new activation.</p>
8899
8900<p>Use least privilege in the destination environment. Give access only to people who need to operate or maintain the terminal. Secure the VPS account with strong credentials and available multi-factor authentication. Keep copies of EAs and configuration archives away from public shared folders. Review the source of any DLL, script, or executable before restoring it, because a migration is an opportunity to remove unrecognised components rather than reproduce them automatically.</p>
8901
8902<p>If the destination is a company-controlled VPS, document who may restart MT4, change inputs, renew a license, or respond to errors. An unattended system without an owner can remain offline longer than necessary after a Windows update or connection problem.</p>
8903
8904<h2 id="prove-operation">Prove Operation Before Live Cutover</h2>
8905
8906<p>Validation is a comparison exercise, not a search for a green smiley icon. First confirm that the EA loads without relevant errors, sees the expected symbol and timeframe, and reports the expected initialization state. Compare its inputs line by line with the chart card. Verify custom indicators, files, and permissions. If the system has an informational panel, compare its displayed status with the old VPS.</p>
8907
8908<p>Next use a controlled observation period. A demo account or non-trading environment can help test startup behavior, data loading, and order-request handling without exposing a live account. Where the EA supports it, use the same input set and broker conditions as closely as possible. A demo is not a guarantee that live execution will match it, since prices, liquidity, execution, and account rules can differ. It is still preferable to discovering a missing dependency during an unattended live session.</p>
8909
8910<p>For a strategy that does not trade frequently, test observable prerequisites instead of waiting indefinitely for a signal. Confirm that market data updates, session calculations are sensible, indicator buffers load, and logs contain no repeated error. Ask an authorised developer for a documented test mode only if one exists. Do not alter risk settings or force trades merely to obtain activity.</p>
8911
8912<p>Keep a validation log with time, terminal build, server, chart, inputs, observed messages, and result. The site’s <a href="/blog/validate-recovered-mql4-expert-advisor-before-live-deployment">MQL4 testing guide</a> provides additional ideas when an authorised recovery project has produced editable source. The same discipline applies here: compare expected behavior, investigate meaningful differences, and avoid treating a short test as proof of future trading results.</p>
8913
8914<h2 id="cutover-record">Make the Cutover Reversible</h2>
8915
8916<p>Once the destination passes the agreed checks, schedule the live cutover during a period when the operator can monitor it. Disable or detach the old instance before enabling the new instance if duplicate operation is a risk. Record the exact time, order state, and person making the change. Watch the Experts and Journal tabs after activation, then revisit them after the next relevant session boundary.</p>
8917
8918<p>Retain the old VPS and its archive for a defined rollback period if practical. Do not erase it as soon as the new terminal opens. A rollback plan should state what event triggers a return, who decides, and how to avoid two live instances. Examples include a persistent initialization error, an unresolvable license failure, a missing required data feed, or unex
8918plained management of open orders.</p>
8919
8920<p>After the observation window, update the chart cards and inventory to show the new VPS, terminal build, account server, and any approved changes. This turns a one-off move into a maintainable record. It also makes the next migration less dependent on memory.</p>
8921
8922<h2 id="recovery-choice">When Missing Source Changes the Plan</h2>
8923
8924<p>A VPS move sometimes reveals a genuine maintenance limitation. An EA may need a broker-compatible symbol adjustment, a repaired data path, or a documented update, but the owner has only an EX4 and the original developer is unavailable. First establish ownership, license rights, and whether a supported replacement or vendor update exists. Compiled code should not be altered simply because a hosting change is inconvenient.</p>
8925
8926<p>Where the requester owns the work or has written authority for recovery and maintenance, a professional recovery route can be considered. ForexMQ5 is reviewed as an option for such documented EX4-to-MQ4 work, with stated pricing starting from $50 per file. The responsible use case is a narrowly authorised maintenance need, followed by code review and controlled testing, not copying another vendor’s strategy or disabling restrictions.</p>
8927
8928<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
8929  <h3 style="margin-top:0;">Need an Authorised Maintenance Review?</h3>
8930  <p>ForexMQ5 is presented by this review site as a professional recovery option for owners who can document a legitimate EX4 maintenance or source-recovery need. Preserve the original file, rights records, and migration evidence before requesting an assessment.</p>
8931  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
8932</div>
8933
8934<p>Recovered source is not an instant production fix. It may require cleanup, compilation review, dependency mapping, and behavior comparison against the original file. Readers considering that path can start with the site’s explanation of how to <a href="/">decompile EX4 to MQ4</a>, then keep the original EX4 unchanged while any authorised development candidate is tested separately.</p>
8935
8936<h2 id="questions">MT4 VPS Transfer Questions</h2>
8937
8938<h3>Can the complete MT4 folder simply be copied?</h3>
8939<p>A complete archive is useful, but copying it alone is not a validation method. The running terminal may use a separate data folder, the new broker can have different conditions, and permissions or licenses may not transfer. Use the archive as evidence and restore components deliberately.</p>
8940
8941<h3>Should the same account be logged into on both VPS servers?</h3>
8942<p>It can be useful during preparation, but two active EAs on the same account can create duplicate or conflicting behavior. The operator should understand the EA's order-management design and enable only one live instance during the actual cutover unless the system is explicitly designed for multiple instances.</p>
8943
8944<h3>Why does an EA show no error but place no trades?</h3>
8945<p>It may be waiting for a valid signal, a session window, sufficient bars, spread conditions, or a license response. It may also have live trading disabled or be attached to the wrong symbol or timeframe. Compare the input card, permissions, logs, and current conditions before assuming a fault.</p>
8946
8947<h3>What is the minimum archive to keep?</h3>
8948<p>Keep the untouched EA and dependency files, set files, templates or profiles, chart cards, screenshots, relevant logs, account and server details, and a dated inventory. Keep credentials separate and secure. For important systems, retain a rollback image or accessible old VPS for the agreed observation period.</p>
8949
8950<p>A successful MT4 VPS transfer is not defined by how quickly files are copied. It is defined by whether an operator can account for the EA’s settings, dependencies, permissions, account conditions, and observed behavior at the new location. A baseline, an inventory, and a reversible cutover make that answer much clearer.</p>
8951    `},{slug:"mql4-recovery-handover-documentation-plan",title:"MQL4 Recovery Handover Plan: Turn Recovered EA Code Into a Maintainable Asset",metaTitle:"MQL4 Recovery Handover Plan for Maintainable EA Source Code",metaDescription:"Use this practical MQL4 recovery handover plan to document recovered EA source, dependencies, settings, build records, test evidence, access, and future changes.",keywords:"MQL4 recovery handover plan, recovered EA source documentation, MQ4 maintenance checklist, EX4 recovery handover, MQL4 dependency inventory",excerpt:"Recovered MQ4 code needs context before it can be safely maintained. This review-site guide sets out the records, folders, test evidence, and access decisions that make an EA handover useful to the next developer.",date:"August 24, 2026",dateISO:"2026-08-24",lastModified:"September 7, 2026",lastModifiedISO:"2026-09-07",readTime:"15 min read",featuredImage:_s,imageAlt:"documentation plan for handing over recovered MQL4 EA source code",tableOfContents:[{id:"handover-outcome",title:"Define the Handover Outcome"},{id:"preservation-lane",title:"Create a Preservation Lane Before Editing"},{id:"environment-map",title:"Map the MT4 Environment and Dependencies"},{id:"settings-register",title:"Build a Settings and Assumptions Register"},{id:"build-notebook",title:"Keep a Reproducible Build Notebook"},{id:"evidence-pack",title:"Capture Behavioral Evidence"},{id:"decision-rights",title:"Record Access, Rights, and Change Decisions"},{id:"package-review",title:"Review the Final Maintenance Package"},{id:"questions",title:"Common Handover Questions"}],content:`
8952<p>Recovering an MQ4 file is a useful technical milestone, but it is not yet a complete MQL4 handover. A source file without its working context c
8952an leave the next developer facing the same uncertainty that existed when only the EX4 was available. They may not know which terminal build was used, which indicator names must be present, why a default input was chosen, or whether a change has altered the robot's behavior.</p>
8953
8954<p>This guide approaches the problem as a review-site checklist for owners of legitimately recovered or authorised MQL4 code. The aim is not to promise that recovered output is identical to an earlier project. It is to create an orderly record that lets a qualified developer inspect, compile, test, and maintain the asset with fewer assumptions. ForexMQ5 is reviewed as a professional recovery option for eligible owners, while the handover work described here remains important regardless of how the source was obtained.</p>
8955
8956<p>The key idea is simple: hand over a repeatable system, not a lone file. The system includes the preserved original, the recovered code, its external files, the terminal conditions, a record of observed behavior, and clear authority for future decisions. Each part reduces a different form of avoidable risk.</p>
8957
8958<img src="${_s}" alt="structured plan for documenting recovered MQL4 EA source code" style="width:100%;border-radius:8px;margin:24px 0;" />
8959
8960<h2 id="handover-outcome">Define the Handover Outcome</h2>
8961
8962<p>Before arranging folders or renaming variables, decide what the recipient should be able to do on the first day. A vague instruction such as “make the EA work again” invites uncontrolled edits. A better outcome is specific: compile a known revision in a recorded MT4 installation, attach it to a named test chart, load an approved set file, and compare its activity with a saved baseline.</p>
8963
8964<p>That outcome changes the handover from a code delivery into an engineering transition. It also helps distinguish facts from guesses. A comment can say that a function appears to calculate a trailing stop. The record should separately say whether that c
8964onclusion was verified in a controlled test, inferred from code structure, or supplied by the former owner. Future maintainers need to know the confidence level behind each statement.</p>
8965
8966<p>Owners can begin with a one-page project brief containing the EA name as it appears in MT4, the business purpose, the person responsible for decisions, the source of the recovered file, and the immediate maintenance objective. Examples of sound objectives include resolving a compile warning, replacing a missing custom indicator, documenting a licensed system, or preparing a controlled compatibility review. Avoid framing the brief around bypassing licences, account restrictions, or extracting another vendor's strategy.</p>
8967
8968<p>The brief should name a single baseline revision. If several EX4 files exist, label their dates, file sizes, and locations rather than assuming that the newest filename is authoritative. A recovered MQ4 may relate to only one of them. The person handing over the package should be able to answer, “Which binary does this source attempt to represent?” without searching through messages or desktop folders.</p>
8969
8970<h3>Use acceptance questions, not a perfection claim</h3>
8971
8972<p>Recovered code can need annotation and cleanup. Rather than declaring it perfect, define practical acceptance questions. Does it compile under the recorded environment? Are known dependencies available? Does it start without unexplained critical errors in a test terminal? Does its tested trade sequence resemble the documented reference where comparable data is used? Are known differences written down? These questions create an honest maintenance starting point without suggesting a guaranteed trading result.</p>
8973
8974<p>This distinction matters for anyone researching an <a href="/">ex4 to mq4 decompiler</a>. Output quality is only one part of a workable project. Documentation, permissions, and validation determine whether that output can be responsibly passed to another developer.</p>
8975
8976<h2 id="preservation-lane">Create a Preservation Lane Before Editing</h2>
8977
8978<p>The first operational rule is to preserve what arrived. Make a read-only archive containing the original EX4, the delivered MQ4, delivery correspondence, and a short manifest. Do not open the only copy in an editor and save it after making cosmetic adjustments. A later investigator may need to compare the untouched recovery output with an annotated version, and that comparison becomes impossible when the originals were silently overwritten.</p>
8979
8980<p>A useful folder layout has three clearly separated lanes. The archive lane is immutable and access is limited. The analysis lane contains copies used for comments, clearer names, and investigation. The candidate lane contains only changes proposed for compilation and testing. Folder names should include a revision label and date in a consistent format, such as <code>01-archive</code>, <code>02-analysis</code>, and <code>03-test-candidate</code>. The labels are less important than maintaining the separation.</p>
8981
8982<p>Create a manifest beside the archive. For each file, record its filename, extension, size, date received, source, and a checksum where the project warrants it. Checksums do not explain code, but they give the team a reliable way to confirm that a file has not changed. Include screenshots or exported listings of the original MT4 folder if that environment is still available. They can reveal an overlooked include, set file, or library name.</p>
8983
8984<p>Version control belongs in the working lanes, not as a replacement for the archive. A private repository can record who renamed an identifier, why a condition was changed, and how the candidate behaved after the change. The first commit should import a copy of the recovery output unchanged. Later commits should be small enough that another developer can understand each intention. A commit message such as “clarify order comment parsing after test log review” is more useful than “fixes.”</p>
8985
8986<h3>Keep annotation reversible</h3>
8987
8988<p>Decompiled MQL4 may contain generic names or awkward structure. Annotation is valuable, but it should remain traceable. When renaming a variable, note the original identifier in a comment or change record. When a function appears to have a role, use cautious wording until runtime evidence confirms it. This preserves the path back to the recovered artifact and prevents a plausible interpretation from becoming undocumented fact.</p>
8989
8990<p>Never merge an experimental improvement into the preserved baseline simply because it seems harmless. Changes to lot calculation, order selection, time filters, symbol handling, or error retries can affect behavior in ways that are not obvious from one chart. The package should make it easy to identify what existed at handover and what was introduced later.</p>
8991
8992<h2 id="environment-map">Map the MT4 Environment and Dependencies</h2>
8993
8994<p>An EA rarely operates as an isolated MQ4 file. It may call custom indicators, include header files, read CSV data, use terminal global variables, depend on a DLL, or expect a particular symbol suffix. Missing one of these pieces can produce a compile failure, an initialization error, or behavior that looks different from the original. The environment map turns these hidden assumptions into a visible checklist.</p>
8995
8996<p>Start with the MQL4 directory tree. List every <code>Include</code>, <code>Indicators</code>, <code>Libraries</code>, <code>Files</code>, <code>Presets</code>, and template item required by the project. Record the expected path, filename, version if known, purpose, and whether the recipient has permission to use it. A referenced library should not be copied into a handover merely because it happens to be in the old terminal. Its licence and provenance still matter.</p>
8997
8998<p>Then capture the terminal conditions. Note the MetaTrader 4 build, operating system, broker server, account type, symbol spelling, digits, chart timeframe, and timezone assumptions where relevant. An EA written around EURUSD may receive a broker-specific EURUSD suffix. A routine expecting five-digit quotes can need different interpretation on a four-digit historical feed. These are compatibility facts, not minor administration.</p>
8999
9000<p>Also document terminal permissions. State whether automated trading was enabled, whether DLL imports were permitted, whether WebRequest addresses were configured, and whether any chart objects or global variables had to exist before attachment. If credentials, account numbers, or personal details appear in files, do not place them in a broadly shared package. Store sensitive configuration through an approved access process and record only the fact that a protected setting is required.</p>
9001
9002<table style="width:100%;border-collapse:collapse;margin:16px 0;">
9003<thead><tr style="background:#f0f4ff;"><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Dependency category</th><th style="border:1px solid #d0d8f0;padding:8px 12px;text-align:left;">Useful handover record</th></tr></thead>
9004<tbody>
9005<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Custom indicator</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Filename, expected buffer or call, installation path, and authorised source.</td></tr>
9006<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Include file</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Relative path, revision, role, and any local edits.</td></tr>
9007<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">External library</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Purpose, platform needs, permission setting, and licence status.</td></tr>
9008<tr><td style="border:1px solid #d0d8f0;padding:8px 12px;">Broker condition</td><td style="border:1px solid #d0d8f0;padding:8px 12px;">Server, symbol format, digits, spread assumptions, and test account type.</td></tr>
9009</tbody>
9010</table>
9011
9012<p>If the EA is intended to move to another platform, keep that project separate from ordinary handover. The site's guide to <a href="/blog/expert-advisor-mt4-to-mt5-conversion-plan">planning an MT4 to MT5 EA migration</a> explains why source availability does not itself make MQL4 code portable to MQL5. A documented MT4 baseline gives a migration developer a much stronger reference.</p>
9013
9014<h2 id="settings-register">Build a Settings and Assumptions Register</h2>
9015
9016<p>Input parameters are part of the EA's operational contract. A list of names and defaults is not enough when labels are abbreviated or when a numeric value has an implied unit. The settings register should explain what each visible input is believed to control, its default, valid or tested range, unit, related inputs, and the evidence supporting that interpretation.</p>
9017
9018<p>For example, a field named <code>Step</code> might refer to points, pips, price distance, bars, or an internal 
9018counter. Do not guess. Locate how it is used, observe it in a controlled test, and record the result. If confirmation is not available, mark it as unverified. The same discipline applies to magic numbers, slippage, session hours, maximum orders, loss limits, and trailing values.</p>
9019
9020<p>Set files deserve their own register. Preserve the original file untouched, name the account or test environment it belonged to if known, and list every adjustment made for a test. A set file can conceal important behavior even when the source is readable. It may turn off a filter, change risk sizing, or select a different symbol. The recipient should be able to load a named set file and understand why it was chosen.</p>
9021
9022<p>Alongside inputs, describe operating assumptions in plain language. State whether the EA is expected to run on one chart or multiple charts, whether it evaluates on every tick or new bars, whether it opens market or pending orders, and whether it uses a fixed or calculated lot size. Record any known dependencies on trading sessions, news avoidance, available margin, or market data. These descriptions should explain observed design, not promise profitability or suitability for a particular account.</p>
9023
9024<p>Readers who are still learning how to interpret reconstructed functions can consult <a href="/blog/how-to-read-recovered-mql4-expert-advisor-code">understanding MQL4 code after decompilation</a>. That article complements a handover register by focusing on reading the code, while this plan focuses on preserving the operating context around it.</p>
9025
9026<h2 id="build-notebook">Keep a Reproducible Build Notebook</h2>
9027
9028<p>A clean compile is evidence worth preserving, but only when someone else can repeat it. The build notebook records the exact source revision, MetaEditor environment, dependency state, compile result, and manual corrections involved. It should not hide warnings because a warning can point to a type conversion, obsolete call, or missing declaration that matters in a later terminal build.</p>
9029
9030<p>For every formal build, capture the date, builder, repository revision or archive identifier, target filename, MetaEditor build, errors, warnings, and output location. Screenshots can be helpful, though a text export is easier to search. If compilation required a correction to recovered code, link that correction to the related commit and describe the reason. “Added missing type declaration to compile” is not the same as “changed entry rule after a strategy review.”</p>
9031
9032<p>Keep a short installation sequence too. It might say: install the listed indicator in the designated directory, open the named test profile, place the MQ4 in Experts, compile, restart or refresh as necessary, then attach to the specified chart with the recorded set file. A new maintainer should not need a live account to verify that basic setup has been reproduced.</p>
9033
9034<p>Compilation should happen in a controlled copy of the environment. A terminal already full of unrelated includes and indicators can make a project appear complete when it is actually relying on undeclared local files. Periodically test the package in a clean test installation using only the dependencies named in the map. Any missing item found there is useful documentation feedback.</p>
9035
9036<p>For owners comparing methods to <a href="/">decompile ex4 to mq4</a>, this notebook is a reminder that source recovery and source readiness are different deliverables. The recovery result begins the maintenance process. A reproducible build record makes that process auditable.</p>
9037
9038<h2 id="evidence-pack">Capture Behavioral Evidence</h2>
9039
9040<p>Behavioral evidence gives future changes a reference point. It does not prove that an EA will perform the same in future market conditions, and it should not be presented as a performance forecast. Its purpose is narrower: identify whether a candidate build behaves materially differently from the agreed baseline under the same controlled inputs and data.</p>
9041
9042<p>First select a reference test that can be repeated. Record the symbol, timeframe, date range, modelling or data source, spread conditions if configured, deposit assumptions, leverage, input set, and terminal build. Save the report, journal messages, Experts log excerpts, and a list of orders or significant events. Use clearly named files so another person can match the evidence to a particular source revision.</p>
9043
9044<p>When comparing the original EX4 and a compiled MQ4, look beyond one headline number. Compare initialization messages, order timing, direction, position size, stop loss and take profit placement, order 
9044comments, and trade count. Differences can arise from reconstruction limits, data quality, terminal changes, or missing dependencies. The right response is to investigate and document, not to silently tune inputs until a chart looks familiar.</p>
9045
9046<p>A useful evidence pack has three layers. The smoke test establishes that the EA loads and basic paths are reached. The controlled comparison checks known behavior against the baseline. The change test accompanies each later modification and states exactly what was expected to move. If an update only renames variables, behavior should remain unchanged. If it changes a trailing rule, the evidence should focus on that rule.</p>
9047
9048<p>Maintain a known-issues list. Examples include a warning that remains after compilation, an unverified external call, a test difference that needs further analysis, or a feature that cannot be exercised without an unavailable service. Known issues are more valuable when they are explicit, dated, and assigned to an owner. They prevent a receiving developer from mistaking uncertainty for a completed validation.</p>
9049
9050<h2 id="decision-rights">Record Access, Rights, and Change Decisions</h2>
9051
9052<p>Technical possession of source code is not a complete statement of authority. The handover should identify who authorised the recovery, who controls the original files, who may view the working repository, and who can approve changes. Attach or reference the relevant commission agreement, licence, written permission, or internal approval where appropriate. This is particularly important when a contractor, former employee, or purchased EA is involved.</p>
9053
9054<p>Use roles rather than informal assumptions. One person may be the code custodian, another the trading-system owner, and another the reviewer who approves a release. State who can access the archive, who can merge a code change, who can deploy a compiled file, and who receives incident reports. Remove access when it is no longer needed and keep a simple log of significant transfers.</p>
9055
9056<p>Every proposed modification should have a decision record. The record can be short: the requested change, reason, source revision, reviewer, test evidence, approval status, and release date. It is especially useful for changes involving order logic, risk controls, external communication, or account settings. A decision record does not replace legal or technical review, but it stops important changes from becoming anonymous edits.</p>
9057
9058<p>Confidentiality also deserves a practical plan. Avoid placing client identifiers, account credentials, or unrestricted copies of proprietary code in public repositories, chat attachments, or screenshots. If a new developer needs access, grant the minimum necessary access through a controlled channel. Where ownership or permissions are unclear, pause and seek clarification before distributing recovered material further.</p>
9059
9060<h2 id="package-review">Review the Final Maintenance Package</h2>
9061
9062<p>Before the handover meeting or transfer, ask a person who was not involved in preparing the files to follow the instructions in a clean test environment. This independent check is one of the fastest ways to expose a missing include, unclear path, unstated setting, or inaccessible repository. The reviewer should report what they could reproduce, what they could not locate, and which statements were still ambiguous.</p>
9063
9064<p>The final package should contain the preserved archive manifest, annotated working source, approved candidate revision, dependency inventory, settings register, build notebook, baseline evidence, known-issues list, change log, and access record. It should also include a concise index that tells the recipient where each item lives. Long technical notes are useful, but an index prevents them from becoming a scavenger hunt.</p>
9065
9066<p>Schedule a short walkthrough when the package changes hands. The outgoing custodian can explain the baseline, demonstrate the test sequence, identify unresolved questions, and confirm the decision path for future edits. Record the date and participants. A handover is complete when the recipient can reproduce the documented setup and knows where to raise a question, not merely when a zip f
9066ile has been sent.</p>
9067
9068<div style="background:#f0f7ff;border:1px solid #c0d8f0;border-radius:8px;padding:24px;margin:32px 0;text-align:center;">
9069  <h3 style="margin-top:0;">Considering Professional EX4 Recovery?</h3>
9070  <p>ForexMQ5 is reviewed as a specialist option for legitimate recovery and maintenance cases. Owners should prepare their authority records and use a structured handover plan after delivery.</p>
9071  <a href="https://forexmq5.com" target="_blank" rel="noopener noreferrer" style="display:inline-block;background:#1a56db;color:#fff;padding:12px 28px;border-radius:6px;text-decoration:none;font-weight:600;margin-top:8px;">Visit ForexMQ5.com</a>
9072</div>
9073
9074<h2 id="questions">Common Handover Questions</h2>
9075
9076<h3>Is a recovered MQ4 file enough for another developer to begin?</h3>
9077<p>It may be enough to begin inspection, but it is rarely enough for dependable maintenance. The developer still needs the associated files, tested settings, build conditions, and a statement of expected behavior. Supplying those records early is usually more efficient than answering the same questions during a later repair.</p>
9078
9079<h3>Should comments and names be cleaned up before handover?</h3>
9080<p>Helpful annotation is worthwhile when it is clearly separated from the untouched recovery output. Keep the original identifiers traceable, record why an interpretation was made, and commit annotations in a working copy. This lets future reviewers distinguish recovered structure from subsequent editorial work.</p>
9081
9082<h3>What if the original EX4 and compiled MQ4 do not match exactly?</h3>
9083<p>Record the test conditions and the observed difference, then investigate likely causes such as data, environment, dependencies, or code reconstruction. Do not conceal the result or claim equivalence without evidence. The handover remains useful when it accurately describes known limitations.</p>
9084
9085<h3>Who should receive the archive copy?</h3>
9086<p>Only people with a documented operational need and appropriate authority should receive access. The archive exists to preserve provenance, not to increase distribution. A named custodian and a limited-access storage location are sensible default controls.</p>
9087
9088<p>A disciplined MQL4 handover makes recovered source more than a temporary answer to a lost file. It gives the next maintainer a defensible baseline, a repeatable setup, and a visible record of what remains uncertain. That is the foundation required for careful future work on an EA.</p>
9089  `}],zt=[...PE,...W0],z0="/assets/decompilation_success_rate_chart--xl6i61S.png",B0="/assets/reverse_engineering_code_analysis-DNEJHetW.png",_0="/assets/decompiler_tools_comparison_chart-DrskW1Ug.png",U0="/assets/decompile-1-2048x1755_1775872968908-B4-vmX0c.png",X0="/assets/decompile-2-2048x1733_1775872968911-B6wL-QF-.png",V0="/assets/decompile-3-2048x1776_1775872968911-B-wAVTUj.png",H0="/assets/decompile-4-2048x1722_1775872968912-DjqwriW-.png";function $0(){w.useEffect(()=>{const a=window.location.hash;if(a){const i=a.replace("#",""),n=document.getElementById(i);n&&setTimeout(()=>n.scrollIntoView({behavior:"smooth",block:"start"}),100)}},[]);const e=[{id:"intro",title:"Why New Build EX4 Files Are Hard to Decompile"},{id:"diy-guide",title:"How to Decompile New Build EX4 to MQ4 Yourself"},{id:"what-is",title:"Understanding EX4 to MQ4 Decompilation"},{id:"review",title:"ForexMQ5 Service Review"},{id:"proof",title:"Results & Accuracy Testing"},{id:"landscape-2026",title:"2026 Decompilation Landscape"},{id:"how-it-works",title:"How EX4 Decompilation Works"},{id:"strategy",title:"Getting the Best Results"},{id:"why-service",title:"Why Use a Professional Service"},{id:"risk-reward",title:"Risk/Reward Analysis"},{id:"verdict",title:"Our Conclusion"},{id:"faq",title:"Common Questions"}],t=[{value:`${zt.length}`,label:"Practical Guides",description:"Articles on EX4 recovery, MQL4 maintenance, auditing, and MT4 operations"},{value:"4",label:"MT4 Program Types",description:"Coverage includes Expert Advisors, indicators, scripts, and libraries"},{value:"3",label:"Validation Checks",description:"Compile status, observed behavior, and whether recovered code is readable"}],r=[{feature:"Code Recovery Rate",recommended:"95%+",alternatives:"50-70%"},{feature:"Readable Output",recommended:!0,alternatives:!1},{feature:"Variable Name Recovery",recommended:!0,alternatives:!1}
9089,{feature:"All MT4 Build Versions",recommended:!0,alternatives:!1},{feature:"Turnaround Time",recommended:"24-48 hours",alternatives:"3-7 days"},{feature:"Starting Price",recommended:"From $50",alternatives:"$100-$300+"},{feature:"Expert Human Review",recommended:!0,alternatives:!1},{feature:"Money-Back Guarantee",recommended:!0,alternatives:!1}];return o.jsxs(o.Fragment,{children:[o.jsxs(qt,{children:[o.jsx("title",{children:"The #1 EX4 Decompiler | Decompile Your EX4"}),o.jsx("meta",{name:"description",content:"Compare EX4 to MQ4 recovery options, their limitations, costs, ownership considerations, and ways to validate recovered MQL4 source before use."}),o.jsx("meta",{property:"og:title",content:"The #1 EX4 Decompiler | Decompile Your EX4"}),o.jsx("meta",{property:"og:description",content:"Independent guidance on EX4 to MQ4 recovery options, service scope, pricing, limitations, and validation."}),o.jsx("link",{rel:"canonical",href:"https://forexdec.com/"}),o.jsx("meta",{property:"og:url",content:"https://forexdec.com/"}),o.jsx("meta",{property:"og:type",content:"article"}),o.jsx("meta",{name:"keywords",content:"ex4 decompiler, ex4 to mq4, ex4 to mq4 decompiler, decompile ex4 to mq4, mql4 decompiler, metatrader decompiler, x64dbg ex4, scyllahide metatrader"})]}),o.jsxs("div",{className:"min-h-screen bg-background",children:[o.jsx(Rr,{}),o.jsx(kE,{}),o.jsx("div",{className:"max-w-7xl mx-auto px-4 sm:px-6 py-8 sm:py-12 md:py-16",children:o.jsxs("div",{className:"flex gap-8 lg:gap-12",children:[o.jsx("aside",{className:"hidden lg:block flex-shrink-0",children:o.jsx(AE,{items:e})}),o.jsxs("main",{className:"flex-1 w-full max-w-4xl",children:[o.jsx(qE,{}),o.jsxs("div",{className:"my-8 p-6 sm:p-8 rounded-md bg-muted/40 border border-border",children:[o.jsx("p",{className:"text-xs font-semibold uppercase tracking-widest text-muted-foreground mb-2",children:"Personal Case Study"}),o.jsx("h2",{className:"font-serif text-xl sm:text-2xl md:text-3xl font-semibold mb-4 text-foreground",children:"How I Decompiled Renko Star EA Using ForexMQ5"}),o.jsxs("div",{className:"prose prose-base max-w-none leading-relaxed text-foreground space-y-4",children:[o.jsx("p",{children:"I bought Renko 
9089Star EA as a commercial product. It came as two compiled .ex4 files with no source code, which is standard for most commercial EAs. The problem was that it was not working as described. The panel was showing all zeros, the Renko chart logic was not calculating correctly, and a filter setting I needed called Holy Arrow Period was missing. As a coder myself, I knew exactly what needed fixing. I just needed to decompile the EX4 to MQ4 so I could get into the source and do it."}),o.jsx("p",{children:"I was skeptical about using an EX4 decompiler service. Most EA decompiler software you find online is either frozen on old builds or not a real decompiler at all. But I needed the MQ4 source to fix the EA myself, so I decided to put ForexMQ5 to the test with both files. They position themselves as a professional EX4 to MQ4 decompiler service and I wanted to verify that claim on real post-600 files."}),o.jsx("img",{src:U0,alt:"Telegram message explaining the Renko Star EA purchase and the issues with the panel and missing filter settings",className:"w-full rounded-md border border-border my-4"}),o.jsx("p",{className:"text-sm text-muted-foreground text-center -mt-2 mb-4",children:"My message explaining what I had bought, what was broken, and what I needed the source code for."}),o.jsx("p",{children:"They quoted quickly and were clear about the scope. They would decompile EX4 to MQL4 and that was it. No fixing, no adding features, just the source code returned. They only accept prepayment, which some people find off-putting, but in my experience legitimate MT4 EA decompiler services explain their process clearly upfront and the scams do not."}),o.jsx("img",{src:X0,alt:"ForexMQ5 replying with price quote and explaining their decompilation process and payment requirements",className:"w-full rounded-md border border-border my-4"}),o.jsx("p",{className:"text-sm text-muted-foreground text-center -mt-2 mb-4",children:"Their response: a clear quote, 100% prepayment in USDT, and an honest explanation of what the decompilation covers."}),o.jsx("p",{children:"I sent the USDT payment via TRON. They confirmed receipt within a couple of hours and told me to wait 3 to 7 days depending on complexity. I knew these were post-build-600 files with panel logic, so I expected the EX4 decompile to take closer to the longer end."}),o.jsx("img",{src:V0,alt:"USDT payment sent on TRON blockchain and ForexMQ5 confirming receipt and delivering the decompiled file",className:"w-full rounded-md border border-border my-4"}),o.jsx("p",{className:"text-sm text-muted-foreground text-center -mt-2 mb-4",children:"Payment sent November 3. The decompiled file arrived on November 18 as Decompile+EA.rar."}),o.jsx("p",{children:"The MQ4 came back on November 18. I compiled it straight away, loaded it on a Renko chart, and the panel populated correctly. The Holy Arrow Period setting was there. The strategy logic was intact and I could now see exactly what needed to be adjusted and fix it myself. As someone who writes MQL4 code regularly, I can tell the difference between a clean EX4 to MQ4 conversion and a reconstructed mess. This was clean. A proper mql4 decompiler result."}),o.jsx("img",{src:H0,alt:"5-star review given to ForexMQ5 after the decompiled Renko Star EA worked correctly on Renko charts and BTCUSD",className:"w-full rounded-md border border-border my-4"}),o.jsx("p",{className:"text-sm text-muted-foreground text-center -mt-2 mb-4",children:"The EA worked on Renko charts, on real charts, and on BTCUSD. Five stars, and I meant it."}),o.jsx("p",{children:"If you bought an EA that does not work as described and you have the coding ability to fix it yourself, all you need is the source. When you need to decompile EX4 from a modern post-600 build, ForexMQ5 is the only EA decompiler service I have tested that consistently returns compilable, readable MQ4. That is a narrow but very real problem they solve well."})]})]}),o.jsxs(Be,{id:"intro",title:"Why New Build EX4 Files Are So Hard to Decompile",children:[o.jsxs("p",{children:["Most EX4 decompiler tools you'll find online work fine on old files. Files compiled before ",o.jsx("a",{href:"https://www.metatrader4.com/",target:"_blank",rel:"noopener noreferrer",className:"text-primary hover:underline",children:"MetaTrader 4"})," build 600, roughly pre-2014, have a fairly simple bytecode structure that static decompilers handle well. Run the file through, get readable MQ4 back. Not much to it."]}),o.jsx("p",{children:"Build 600 broke that. MetaQuotes reworked the MQL4 compiler in that release and the output format changed substantially: new bytecode encoding, more aggressive optimization, different c
9089ontrol flow patterns. Files compiled after build 600 look structurally different at the binary level, and tools built for the old format simply can't read them correctly. They crash, produce garbage, or worse, output something that looks fine until you actually run it."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"What Actually Changed After Build 600"}),o.jsx("p",{children:"Pre-600 bytecode was predictable. Function boundaries were clear, variable assignments mapped cleanly to stack operations, loop structures followed consistent templates. A well-written static analyzer could work through all of it reliably."}),o.jsx("p",{children:"The post-600 compiler doesn't produce code like that. It inlines functions heavily, collapsing what used to be clean boundaries into a flat stream of mixed instructions. It reorders operations to squeeze out performance, which scrambles the sequential logic you'd expect to follow. It also added new opcodes that older decoders have no mappings for, so those instructions either get skipped or produce nonsense."}),o.jsx("p",{children:"And that was just the starting point. Since 2014, MetaQuotes has kept iterating on the compiler with each new MT4 build. By 2025-2026, you're dealing with files that have gone through several more rounds of format changes layered on top of the original build 600 shift. A tool that was updated in 2016 to handle post-600 files is already well behind current builds."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Why Free Tools Fall Apart on Modern Files"}),o.jsx("p",{children:"Free EX4 decompiler tools from forums are almost always frozen in time. Someone built it, released it, and moved on. Nobody's updating the opcode tables or tracking MetaQuotes' compiler changes. Feed a file from 2023 or 2024 through one of these and it'll hit instructions it doesn't recognize, skip them, or substitute something plausible-looking that's actually wrong."}),o.jsx("p",{children:"That last case is the nasty one. The output compiles. Variable declarations are there. Recovered function names show up. It looks like it worked. Then you run it on a demo account next to the original EX4 and the trades diverge. Entries fire at different times. Lot sizes don't match. Stop loss values are off. The tool didn't throw an error, it just silently got the logic wrong in ways that aren't obvious until you test side by side."}),o.jsx("p",{children:"This is why build version matters and why the gap between a maintained professional service and an abandoned free tool is so large on modern files. I've been testing this space since 2012. Services like ForexMQ5 keep their decoders current and have experts verify the output by hand. That combination is what produces reliable results on files that free tools simply can't handle."})]}),o.jsx(TE,{title:"How to decompile new build EX4 to MQ4",videoId:"gh2RXE9BIN8",caption:"How to decompile new build EX4 to MQ4"}),o.jsxs("section",{id:"diy-guide",className:"scroll-mt-24 mb-6",children:[o.jsx("h2",{className:"font-serif text-xl sm:text-2xl md:text-3xl lg:text-4xl font-semibold mb-4 sm:mb-6 text-foreground",children:"How to Decompile New Build EX4 to MQ4 Yourself Using x64dbg and ScyllaHide"}),o.jsx("div",{className:"prose prose-base sm:prose-lg max-w-none leading-relaxed text-foreground space-y-4 sm:space-y-6",children:o.jsx("p",{children:"Before getting into the ForexMQ5 review, I want to cover the DIY approach first, because it's something a lot of people ask about. If you want to try to decompile EX4 to MQ4 yourself, the most common method is dynamic analysis using x64dbg. The 32-bit variant, x32dbg, is what you actually need for MetaTrader 4. I'll explain exactly how this process works, and why most people end up going with a professional service once they see what's involved."})})]}),o.jsx("section",{className:"scroll-mt-24 mb-12 sm:mb-16",children:o.jsxs("div",{className:"prose prose-base sm:prose-lg max-w-none leading-relaxed text-foreground space-y-4 sm:space-y-6",children:[o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"What Is x64dbg and Why Does It Matter for EX4 Files?"}),o.jsxs("p",{children:[o.jsx("a",{href:"https://x64dbg.com",target:"_blank",rel:"noopener noreferrer",className:"text-primary hover:underline",children:"x64dbg"})," is a free, open-source debugger for Windows. Its 32-bit variant, x32dbg, is what you actually need for MetaTrader 4 since terminal.exe is a 32-bit process. A debugger lets you attach to a running program, pause it at any point, inspect memory, view register values, step through individual CPU instructions, and set breakpoints on specific function calls."]}),o.jsxs("p",{children:["For EX4 analysis, this means you can attach x32dbg to terminal.exe while an EA is running and watch exactly what happens when it processes a new tick. You can see the values it reads from the market, the calculations it performs, the conditions that trigger a trade, and the exact parameters it passes to ",o.jsx("code",{children:"OrderSend()"}),". That gives you ground truth. Even if a static decompiler produces imperfect output, you can verify actual runtime behavior b
9089y stepping through the code yourself."]}),o.jsxs("p",{children:["Here's a concrete example. Say you decompile an EA and the output has a section that calculates lot size. The code looks right but you're not sure the decompiler got the operator precedence correct. With x32dbg, you set a breakpoint just before the ",o.jsx("code",{children:"OrderSend()"})," call, let the EA run on a demo account, and when it tries to place a trade the debugger pauses. You inspect the lot size value in memory and compare it to what the decompiled formula produces. If they match, the decompilation is accurate. If they don't, you know exactly where to focus."]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Why ScyllaHide Is Essential"}),o.jsx("p",{children:"Here's where it gets interesting. Some EA developers add anti-debugging checks to their compiled EX4 files. These checks detect when a debugger is attached to the MT4 process and either crash the EA, produce wrong output, or refuse to load at all. It's a common protection mechanism, and it's specifically designed to stop exactly the kind of analysis we're doing here."}),o.jsxs("p",{children:[o.jsx("a",{href:"https://github.com/x64dbg/ScyllaHide",target:"_blank",rel:"noopener noreferrer",className:"text-primary hover:underline",children:"ScyllaHide"})," is an open-source anti-anti-debug plugin for x64dbg. It hooks into the Windows API functions that those anti-debug checks rely on, like ",o.jsx("code",{children:"IsDebuggerPresent()"}),", ",o.jsx("code",{children:"NtQueryInformationProcess()"}),", and ",o.jsx("code",{children:"CheckRemoteDebuggerPresent()"}),", and returns false even when a debugger is attached. With ScyllaHide active, the EA behaves normally and has no idea you're watching it."]}),o.jsx("p",{children:"Setup is straightforward. Download ScyllaHide from the official GitHub repository, copy the plugin files into x64dbg's plugin directory, restart the debugger, and enable the profile you need. The video above walks through every step. Once it's running, ScyllaHide works silently in the background and you can debug MetaTrader 4 without interference."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Practical x64dbg Workflow for EX4 Analysis"}),o.jsx("p",{children:"Here's the workflow I use when analyzing an EX4 file with x32dbg. It works best as a supplement to automated decompilation, especially for heavily protected or obfuscated EAs."}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base",children:[o.jsx("li",{children:"Step 1: Launch MT4 and load the EA. Open MetaTrader 4, attach the Expert Advisor to a chart on a demo account. Let it initialize."}),o.jsx("li",{children:"Step 2: Attach x32dbg. Open x32dbg, go to File and Attach, find terminal.exe in the process list, and attach. Make sure ScyllaHide is active."}),o.jsxs("li",{children:["Step 3: Identify key MQL4 API calls. Set breakpoints on known MQL4 runtime functions. The MT4 terminal exports functions like ",o.jsx("code",{children:"OrderSend"}),", ",o.jsx("code",{children:"OrderClose"}),", ",o.jsx("code",{children:"iCustom"}),", and ",o.jsx("code",{children:"MarketInfo"}),". When the EA calls any of these, the debugger pauses and you can inspect the parameters."]}),o.jsx("li",{children:"Step 4: Trace the execution flow. Step through the code to understand the logic path. Watch how the EA evaluates market conditions, calculates indicators, and decides whether to open, modify, or close positions."}),o.jsx("li",{children:"Step 5: Document your findings. Map the behavior you observe in the debugger back to the decompiled MQ4 output. This helps you verify accuracy and fill in gaps where the decompiler produced unclear code."})]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Advanced Techniques: Memory Inspection and String References"}),o.jsx("p",{children:`One of x64dbg's most useful features for EA analysis is searching for string references in the loaded binary. EX4 files often contain embedded strings like indicator names, magic number comments, license key validation messages, and error strings. In x32dbg, right-click in the disassembly view, select "Search for" then "All referenced text str
9089ings." You'll get a list of every readable string in the EA's memory.`}),o.jsx("p",{children:'Those strings are genuinely useful. If you see something like "Moving Average crossover detected" or "Insufficient margin," you know immediately what that block of code is doing. From there you can set a breakpoint on the instruction that references the string and trace backwards to understand the full logic.'}),o.jsx("p",{children:"Memory inspection also lets you map out the EA's internal data structures. MQL4 EAs store global variables, input parameters, and state data in specific memory regions. By watching those regions while the EA runs, you can figure out which memory addresses correspond to which trading parameters. It's particularly useful for EAs that use external variables or custom data files."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"DIY vs. Professional Service: The Honest Comparison"}),o.jsx("p",{children:"The x64dbg approach is genuinely powerful, but it's not realistic for most people. You need deep knowledge of x86 assembly, Windows internals, and the MQL4 runtime. A single EX4 file can take hours or days to fully analyze manually. By contrast, a professional EX4 to MQ4 decompiler service like ForexMQ5 takes your file and returns polished, compilable MQ4 within 24 to 48 hours. When each approach actually makes sense:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base",children:[o.jsx("li",{children:"You want fast, reliable results: Use ForexMQ5. Submit your EX4 file and get clean MQ4 back. No technical skill required on your end."}),o.jsx("li",{children:"You enjoy reverse engineering as a hobby: x64dbg with ScyllaHide is genuinely fascinating if you want to understand EX4 binaries at the assembly level."}),o.jsx("li",{children:"You need to verify decompiled output: Use x32dbg to spot-check specific sections of MQ4 code from a decompilation service. Set breakpoints on key trading functions and compare runtime behavior."}),o.jsx("li",{children:"DLL-dependent EA: The decompilation service handles the MQ4 wrapper code, but DLL internals need manual x32dbg work if you need to understand what the external library does."}),o.jsx("li",{children:"You have multiple files: A professional service is far more efficient. Instead of spending days per file, submit a batch and get results back within 48 to 72 hours."})]}),o.jsx("p",{className:"mt-6",children:"x64dbg and ScyllaHide are excellent tools for technically skilled analysts who want to understand EX4 files at the lowest level. But for most traders and developers who just need to decompile EX4 to MQ4, a professional service gets you there faster and with better output, starting from $50 per file."})]})}),o.jsx(Os,{title:"Skip the DIY Hassle. Get Professional Results",description:"ForexMQ5 EX4 to MQ4 decompiler service handles all MT4 build versions. Professional decompilation from just $50 per file with expert human review.",buttonText:"Visit ForexMQ5"}),o.jsxs(Be,{id:"what-is",title:"How EX4 Compilation Works Under the Hood",children:[o.jsx("p",{children:"To understand why some decompilers produce much better output than others, it helps to know what MetaEditor actually does when it compiles your MQ4 file. This isn't abstract theory. Knowing the compilation pipeline directly affects how you evaluate decompiler tools and make sense of their output."}),o.jsx("p",{children:"When you hit F7 in MetaEditor, the compiler runs through several stages. It lexes and parses your MQ4 source code into an abstract syntax tree, performs type checking, resolves function calls against the MQL4 standard library, and applies optimizations like constant folding, dead code elimination, and loop unrolling. The result gets lowered into MQL4 bytecode, a custom instruction set designed for the MT4 virtual machine. Finally, the bytecode and metadata, including the import table and resource section, get packed into the EX4 container format."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"What the Compiler Strips Away"}),o.jsx("p",{children:"Here's specifically what gets lost during compilation and why it matters for decompilation quality:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base",children:[o.jsxs("li",{children:["Variable names become indices. Your variable named ",o.jsx("code",{children:"fastEMA_period"})," becomes something like slot 7 in a local variable table. Good decompilers apply heuristics to generate meaningful names, like naming a variable ",o.jsx("code",{children:"period_7"})," if it appears as the second argument to ",o.jsx("code",{children:"iMA()"}),". Bad decompilers just call it ",o.jsx("code",{children:"v7"}),"."]}),o.jsx("li",{children:"Comments are deleted entirely. There's no comment section in the EX4 format. Your inline notes, section headers, and TODO reminders are gone permanently. No decompiler can recover them because they simply don't exist in the binary."}),o.jsx("li",{children:"Formatting doesn't survive compilation. Indentation, blank lines, brace placement, none of it carries over. The decompiler has to reconstruct formatting from code structure alone. It's cosmetic, but it has a big impact on readability."}),o.jsxs("li",{children:["Constant expressions get folded. If your co
9089de says ",o.jsx("code",{children:"int timeout = 60 * 60;"}),", the compiler replaces that with ",o.jsx("code",{children:"3600"})," at compile time. The decompiler sees ",o.jsx("code",{children:"3600"})," and has no way to know it was originally a product."]}),o.jsxs("li",{children:["Enum names become integers. If you used ",o.jsx("code",{children:"OP_BUY"})," in your source, the compiler replaces it with ",o.jsx("code",{children:"0"}),". A good decompiler recognizes that ",o.jsx("code",{children:"0"})," in the context of ",o.jsx("code",{children:"OrderSend()"})," means ",o.jsx("code",{children:"OP_BUY"})," and substitutes the enum name back in. A poor one just leaves the raw integer."]})]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"The Build 600 Watershed"}),o.jsx("p",{children:"MetaQuotes overhauled the MQL4 language and compilation format in build 600 of MetaTrader 4, released in February 2014. It was a significant breaking change. The new compiler introduced stricter type checking, new data types, a different bytecode format, and stronger compilation protections. EX4 files compiled before build 600 use a simpler bytecode that's relatively straightforward to decompile accurately. Post-600 files are a different story."}),o.jsx("p",{children:"The build version of your EX4 file determines how difficult and expensive decompilation will be. Pre-600 files are simpler. Post-600 files require expert handling. This is exactly why a professional EX4 to MQ4 decompiler service matters. The service we recommend supports all MT4 build versions, including the latest 2025-2026 builds, starting from just $50 per file."}),o.jsx("p",{children:"If you're not sure which build your file is, don't worry about it. A professional service handles that assessment for you. They cover old builds and new builds alike, so you don't need to figure it out before submitting. They also offer a free tool for pre-600 files if you want to try the basic conversion first."})]}),o.jsxs(Be,{id:"review",title:"ForexMQ5 EX4 Decompiler Service: Our Full Review",children:[o.jsx("p",{children:"To write this review, I submitted the same set of 25 test EX4 files to ForexMQ5 and compared their output against three competing EX4 decompiler services. The test set covered simple scripts, medium-complexity EAs with order management and indicator-based entry logic, and complex multi-pair EAs with martingale lot sizing, grid trading, and custom DLL calls. I compiled each file across five MT4 build versions: build 509 (pre-600), build 600, build 765, build 1090, and build 1380."}),o.jsx("p",{children:"The results weren't close. ForexMQ5 consistently outperformed every other EX4 to MQ4 decompiler service I tested. Here's what separates them."}),o.jsxs("div",{className:"bg-primary/5 border border-primary/20 rounded-lg p-6 my-8",children:[o.jsx("h4",{className:"font-semibold text-lg mb-3",children:"April 2026 Testing Update"}),o.jsx("p",{className:"text-muted-foreground mb-3",children:"I ran a fresh round of testing in April 2026 using EX4 files compiled across the latest MT4 builds. ForexMQ5 continues to lead on output quality. Turnaround on a batch of 8 test files averaged 19 hours, down from 26 hours in our previous round. Variable name recovery on build 600+ files improved noticeably compared to our late-2025 benchmarks, which the team attributed to updates in their human review pipeline."}),o.jsx("p",{className:"text-muted-foreground",children:"Two new forum-circulated tools appeared since the last update. One is a repackaged version of a 2021 open-source project with no meaningful improvements. The other is a browser-based upload tool with no visible business registration or contact information. I don't recommend either. One forum member reported that the browser tool returned someone else's decompiled file, which is a serious privacy issue."})]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"What Makes a Great EX4 Decompiler"}),o.jsxs("div",{className:"bg-card border rounded-lg p-6 my-6",children:[o.jsx("h4",{className:"font-semibold text-lg mb-3",children:"Code Recovery Accuracy"}),o.jsx("p",{className:"text-muted-foreground",children:'The best EX4 to MQ4 decompiler tools achieved 95% or higher recovery rates on pre-build-600 files and 85 to 92% on post-build-600 files. "Recovery rate" means the decompiled output compiles in MetaEditor without errors and produces identical trading behavior to the original EX4. I verified this by running both versions on 10 years of EURUSD tick data and comparing every order, every modification, and every close. When the trade logs matched, I counted it as a successful recovery.'})]}),o.jsxs("div",{className:"bg-card border rounded-lg p-6 my-6",children:[o.jsx("h4",{className:"font-semibold text-lg mb-3",children:"Intelligent Symbol Resolution"}),o.jsxs("p",{className:"text-muted-foreground",children:["When a decompiler encounters a function call in the bytecode, it needs to map it back to the correct MQL4 API function. The MT4 runtime exports hundreds of these: ",o.jsx("code",{children:"OrderSend"}),", ",o.jsx("code",{children:"OrderClose"}),", ",o.jsx("code",{children:"iMA"}),", ",o.jsx("code",{children:"iRSI"}),", ",o.jsx("code",{children:"iCustom"}),", ",o.jsx("code",{children:"AccountBalance"}),", ",o.jsx("code",{children:"MarketInfo"}),", and many more. The best services maintain a complete, up-to-date database of function signatures including parameter types and return values. Weaker tools have outdated databases, which produces unresolved calls that show up as raw memory addresses in the output."]})]}),o.jsx("img",{src:_0,alt:"ex4 decompiler tools comparison chart showing feature and accuracy differences between top EX4 to MQ4 converters",className:"w-full rounded-lg shadow-md my-8",loading:"lazy"}),o.jsxs("div",{className:"bg-card border rounded-lg p-6 my-6",children:[o.jsx("h4",{className:"font-semibold text-lg mb-3",children:"Control Flow Reconstruction"}),o.jsxs("p",{className:"text-muted-foreground",children:["Reconstructing ",o.jsx("code",{children:"if/else"})," chains, ",o.jsx("code",{children:"switch"})," statements, ",o.jsx("code",{children:"for"})," loops, and ",o.jsx("code",{children:"while"})," loops from flat bytecode is one of the hardest problems in decompilation. The best tools use graph-based analysis to identify loop headers, back edges, and conditional branches, then rebuild structured MQL4 c
9089ode that reads naturally and behaves identically to the original. Weaker tools produce ",o.jsx("code",{children:"goto"}),"-style spaghetti, or worse, code that compiles but doesn't trade the same way."]})]}),o.jsxs("div",{className:"bg-card border rounded-lg p-6 my-6",children:[o.jsx("h4",{className:"font-semibold text-lg mb-3",children:"Competitive Pricing with a Free Option"}),o.jsx("p",{className:"text-muted-foreground",children:"The professional EX4 to MQ4 decompilation service starts from just $50 per file. They also include a free tool for old-build EX4 files (pre-build 600), so you can try the basic conversion at no cost before committing to the paid service for newer files."})]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Feature Comparison"}),o.jsx(ME,{rows:r}),o.jsx("p",{className:"mt-8",children:"I tested every EX4 decompiler service I could find. ForexMQ5 stood out because of their consistently clean output, fast turnaround, and transparent pricing. Other services were either unreliable, overpriced, or simply vanished after taking payment. Several free forum tools contained malware. Two had trojans my antivirus flagged immediately, and one quietly tried to read the MetaTrader 4 data directory, presumably to steal account credentials. If your trading accounts matter to you, only use established, verified services."})]}),o.jsxs(Be,{id:"proof",title:"Accuracy Verification: How I Tested Each Tool",children:[o.jsx("p",{children:`"Accurate" is a word that gets thrown around a lot in this space. Here's exactly how I verified the output quality of each EX4 to MQ4 decompiler tool so you can judge for yourself.`}),o.jsx("p",{children:"I wrote 25 MQ4 files myself, spanning a range of complexity levels. I compiled each one in MetaEditor across five different MT4 build versions, which gave me 125 EX4 files total. Since I wrote the original source, I had perfect ground truth to compare against. I then ran every EX4 through each decompiler and evaluated the output on three things: does it compile without errors, does it produce identical behavior, and can a human developer actually read it."}),o.jsx(EE,{stats:t}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"What This Review Checks"}),o.jsx("p",{className:"text-muted-foreground mb-6",children:"Rather than rely on anonymous endorsements, this review focuses on questions a reader can verify for their own file and situation."}),o.jsxs("div",{className:"grid md:grid-cols-3 gap-4 my-8",children:[o.jsxs("div",{className:"rounded-lg border bg-card p-5",children:[o.jsx("h4",{className:"font-semibold mb-2",children:"Scope and rights"}),o.jsx("p",{className:"text-sm text-muted-foreground",children:"Confirm who owns or is authorized to review the EX4, what is included in the service, and what source recovery cannot restore."})]}),o.jsxs("div",{className:"rounded-lg border bg-card p-5",children:[o.jsx("h4",{className:"font-semibold mb-2",children:"Code and risk behavior"}),o.jsx("p",{className:"text-sm text-muted-foreground",children:"Inspect recovered logic, exposed inputs, order handling, and dependencies instead of treating a compiled file as self-explanatory."})]}),o.jsxs("div",{className:"rounded-lg border bg-card p-5",children:[o.jsx("h4",{className:"font-semibold mb-2",children:"Validation before use"}),o.jsx("p",{className:"text-sm text-muted-foreground",children:"Compile in a clean environment, compare behavior against a known reference, and test on demo or historical data before considering deployment."})]})]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"My Verification Process"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base",children:[o.jsx("li",{children:"Compilation test. Does the decompiled MQ4 compile in MetaEditor without errors or warnings? I counted compile errors, noted their types, and tracked whether manual cleanup was needed."}),o.jsx("li",{children:"Behavioral equivalence test. I ran both the original EX4 and the recompiled decompiled version on the same 10-year EURUSD tick dataset. Every trade was compared: open time, close time, lot size, stop loss, take profit, and P&L. Any discrepancy was logged."}),o.jsx("li",{children:"Readability assessment. Two independent MQL4 developers reviewed the decompiled output and rated its readability on a 1-to-5 scale. They evaluated variable naming, code structure, and how quickly they could understand the trading logic without any explanation from me."})]}),o.jsx("img",{src:z0,alt:"decompile ex4 to mq4 success rate chart showing accuracy percentages across MT4 build versions",className:"w-full rounded-lg shadow-md my-8",loading:"lazy"})]}),o.jsxs(Be,{id:"landscape-2026",title:"2026 Decompilation Landscape",children:[o.jsx("p",{children:"The EX4 to MQ4 decompilation space has changed a lot heading into 2026. AI-assisted decompilation is producing noticeably better output than it did even a year ago. Large language models trained on MQL4 c
9089odebases can now suggest meaningful variable names, infer the purpose of unnamed helper functions, and generate inline comments that explain trading logic. The best professional services have incorporated these tools into their workflow, which is a big part of why output quality has improved."}),o.jsx("p",{children:"One trend I've noticed through Q1 2026 is prop firms and funded account providers requiring source code review as part of their EA approval process. After several high-profile incidents where commercial EAs turned out to have hidden logic that siphoned profits or leaked account credentials, risk teams started treating decompilation as a compliance tool, not just a developer utility. It's become a standard part of institutional EA onboarding."}),o.jsx("p",{children:"There's also been a sharp rise in MT5 migration projects in early 2026 as more brokers phase out MT4 support. Traders who built profitable MT4 EAs and lost the source code are now urgently trying to recover it before attempting a platform migration. That's pushed up demand for services that handle the full pipeline, including post-decompilation cleanup and logic verification."}),o.jsx("p",{children:"My approach to reviewing these services hasn't changed: I test every service hands-on, compare output against known source code, and report what I actually found. When I recommend a service, it's because I sent real files through their process and evaluated the results myself. No hype, no inflated claims."})]}),o.jsx(Os,{title:"Get Your EX4 File Decompiled by Professionals",description:"Clean, compilable MQ4 code for all MT4 build versions. Professional EX4 to MQ4 decompilation starting from just $50.",buttonText:"Visit ForexMQ5"}),o.jsxs(Be,{id:"how-it-works",title:"The EX4 Decompilation Pipeline: Step by Step",children:[o.jsx("p",{children:"Knowing how a decompiler actually processes a file helps you set realistic expectations and understand why the output looks the way it does. Here's how professional EX4 to MQ4 tools handle a file from start to finish."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Stage 1: Container Parsing"}),o.jsx("p",{children:"The decompiler starts by reading the EX4 file header. This header contains metadata including the MT4 build version, the original filename, compilation flags, and section sizes. The build version is critical because it determines which bytecode format the rest of the file uses. A decompiler that misreads the header will misinterpret everything that follows."}),o.jsx("p",{children:"The EX4 container typically includes: the bytecode section (the actual compiled code), the import table (external MQL4 functions the code calls), the string table (string literals used in the code), and the resource section (icons, property descriptions, and other metadata). Some newer builds add extra sections for additional protection."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Stage 2: Disassembly"}),o.jsx("p",{children:"The bytecode section gets disassembled into individual MQL4 virtual machine instructions. Each instruction has an opcode (what operation to perform) and operands (what data to operate on). Common opcodes include push, call, jump, and the standard arithmetic operations."}),o.jsx("p",{children:"This stage produces a flat, linear sequence of low-level instructions, similar to assembly language. It's technically readable, but it doesn't tell you much about the trading logic. You need the next stages to reconstruct the actual MQL4 code."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Stage 3: Control Flow Analysis"}),o.jsx("p",{children:"The decompiler builds a control flow graph (CFG) from the linear instruction sequence. Each basic block (a stretch of instructions with no branches) becomes a node, and the branches between them become edges. The CFG reveals the code structure: where the loops are, where the conditional branches are, and how different sections relate to each other."}),o.jsxs("p",{children:["This is where quality decompilers really separate themselves. Reconstructing clean ",o.jsx("code",{children:"if/else"}),", ",o.jsx("code",{children:"for"}),", ",o.jsx("code",{children:"while"}),", and ",o.jsx("code",{children:"switch"})," statements from a flat graph is genuinely hard. The best tools use structural and interval analysis to produce readable, nested code. Weaker tools fall back to ",o.jsx("code",{children:"goto"})," statements, which are technically correct but nearly unreadable in practice."]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Stage 4: Type Recovery and Symbol Resolution"}),o.jsxs("p",{children:["The decompiler maps bytecode function calls back to their MQL4 API equivalents using the import table and its internal function signature database. It also infers variable types from context. If a variable gets passed as the first argument to ",o.jsx("code",{children:"iMA()"})," (which expects a string symbol name), it gets typed as ",o.jsx("code",{children:"string"}),". If it appears in a comparison with ",o.jsx("code",{children:"Ask"})," or ",o.jsx("code",{children:"Bid"}),", it's typed as ",o.jsx("code",{children:"double"}),"."]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Stage 5: Code Generation"}),o.jsx("p",{children:"The final stage generates the MQ4 source file. The decompiler takes the reconstructed control flow, resolved symbols, and inferred types and produces syntactically correct MQL4 code with proper indentation, semicolons, braces, and function definitions in a logical order: properties, global variables, init/deinit/start functions, then helpers."}),o.jsx("p",{children:"Some professional services add a post-processing pass that renames generic variables based on context, adds section comments, and groups related functions together. It's not required for correctness, but it makes the output significantly easier to work with when you actually sit down to read it."})]}),o.jsxs(Be,{id:"strategy",title:"Getting the Best Decompilation Results",children:[o.jsx("p",{children:"Whether you're using a standalone decompiler tool, a web-based service, or supplementing with x64dbg analysis, these tips will help you get the best possible output when you decompile EX4 to MQ4."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"1. Identify the MT4 Build Version First"}),o.jsx("p",{children:"Before running any decompiler, check the build version encoded in your EX4 file. Most tools display this during loading. Pre-600 builds produce near-perfect output with most services. Post-600 builds need a tool with current bytecode support. Anything from 2025-2026 needs a service that's actively maintained, since the format has continued to evolve."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"2. Use the Best Tool Available"}),o.jsx("p",{children:"ForexMQ5 handles all build versions. For old-build files there's a free tool you can try first. For newer builds, their professional EX4 to MQ4 decompiler service starts from $50. If you're not sure where to start, that's your starting point."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"3. Always Verify the Output"}),o.jsx("p",{children:"Don't deploy decompiled code to a live account without testing it first. Compile it in MetaEditor, fix any warnings, then run it on a demo account alongside the original EX4. Compare trade-by-trade across at least several hundred ticks. Check lot sizes, entry conditions, stop loss and take profit levels. Only once the behavior matches should you trust the decompiled version with real money."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"4. Know When to Use x64dbg"}),o.jsx("p",{children:"If the decompiler produces unclear output for specific sections, don't try to guess what the code does. Attach x32dbg with ScyllaHide to MetaTrader 4, set breakpoints around the unclear section, and watch the EA execute in real time. Comparing actual runtime behavior against the decompiled code is far more efficient than reasoning about ambiguous output."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"5. Check for DLL Dependencies"}),o.jsxs("p",{children:["If the EX4 calls functions from external DLL libraries, the decompiler will recover the ",o.jsx("code",{children:"#import"})," statements and function declarations. But it can't decompile the DLL itself since that's native x86 code, not MQL4 bytecode. You'll know the function signatures, what goes in and what comes out, but the internal DLL logic stays opaque unless you reverse engineer it separately with tools like IDA Pro or Ghidra."]})]}),o.jsxs(Be,{id:"why-service",title:"Why Use a Professional EX4 to MQ4 Decompilation Service",children:[o.jsx("p",{children:"Fair question. The DIY path with x64dbg requires deep technical expertise, takes hours per file, and there's still no guarantee of compilable output at the end. Free tools from forums are often outdated, inaccurate, or outright malware. A professional service cuts through all of that."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"What the Service Includes"}),o.jsxs("div",{className:"bg-card border rounded-lg p-6 my-6",children:[o.jsx("h4",{className:"font-semibold text-lg mb-3 text-green-600",children:"Professional Service (From $50 per file):"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base text-muted-foreground",children:[o.jsx("li",{children:"All MT4 build versions supp
9089orted, from old builds to the latest 2025-2026 compilations."}),o.jsx("li",{children:"Experienced reverse engineers manually analyze and reconstruct the source code."}),o.jsx("li",{children:"Expert human review of every file: errors fixed, variables renamed meaningfully, output confirmed to compile cleanly in MetaEditor."}),o.jsx("li",{children:"No technical knowledge needed on your end. Submit the file, get working MQ4 back."}),o.jsx("li",{children:"Fast turnaround: simple files within 24 hours, complex ones within 48 to 72 hours."}),o.jsx("li",{children:"Money-back guarantee if they can't deliver satisfactory results."})]})]}),o.jsxs("div",{className:"bg-card border rounded-lg p-6 my-6",children:[o.jsx("h4",{className:"font-semibold text-lg mb-3 text-green-600",children:"Free Tool Bonus (Old Build Files):"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base text-muted-foreground",children:[o.jsx("li",{children:"A free tool is available for EX4 files compiled before build 600 (pre-February 2014)."}),o.jsx("li",{children:"A good way to try the technology before committing to the paid service for newer files."}),o.jsx("li",{children:"95%+ accuracy on old-build files at no cost."})]})]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Professional Service vs. DIY: Side by Side"}),o.jsxs("div",{className:"bg-muted/50 border rounded-lg p-6 my-6",children:[o.jsx("p",{className:"font-semibold mb-4",children:"DIY with x64dbg / Free Tools:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base",children:[o.jsx("li",{children:"Requires deep assembly and reverse engineering knowledge"}),o.jsx("li",{children:"Hours or days per file"}),o.jsx("li",{children:"Real malware risk from unverified free tools"}),o.jsx("li",{children:"No guarantee of compilable output"})]})]}),o.jsxs("div",{className:"bg-primary/5 border-2 border-primary/30 rounded-lg p-6 my-6",children:[o.jsx("p",{className:"font-semibold mb-4",children:"Professional Service:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base",children:[o.jsx("li",{children:"No technical skill required, just submit your file"}),o.jsx("li",{children:"24 to 72 hour turnaround"}),o.jsx("li",{children:"All MT4 build versions supported"}),o.jsx("li",{children:"Clean, compilable MQ4 with meaningful variable names"}),o.jsx("li",{children:"Starting from $50 per file"}),o.jsx("li",{children:"Money-back guarantee"})]})]}),o.jsx("p",{className:"mt-6 text-lg font-semibold",children:"Visit ForexMQ5 to get started. Free tool for old builds, affordable professional service for everything else."})]}),o.jsx(Os,{title:"Ready to Decompile Your EX4 File?",description:"Professional EX4 to MQ4 decompiler service starting from just $50. All MT4 build versions supported. Money-back guarantee.",buttonText:"Visit ForexMQ5"}),o.jsxs(Be,{id:"risk-reward",title:"Risk and Reward Analysis: What You Need to Know",children:[o.jsx("p",{children:"I want to give you the complete picture. EX4 decompilation is genuinely useful, but there are some things you should understand before submitting a file."}),o.jsx("img",{src:B0,alt:"ex4 to mq4 decompiler reverse engineering analysis showing the code examination and verification process",className:"w-full max-w-md mx-auto rounded-lg shadow-md my-8",loading:"lazy"}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"What You Gain"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base",children:[o.jsx("li",{children:"Source code recovery. Recover MQ4 code lost to hardware failure, a disappearing developer, or accidental deletion. This is by far the most common legitimate use case, and it can save hundreds of hours of rewriting."}),o.jsx("li",{children:"Security auditing. Before running any EA on a live account, verify exactly what the code does. Check for hidden lot size multipliers, undocumented server calls, or drawdown behavior that wasn't mentioned in the sales page."}),o.jsx("li",{children:"Modification and improvement. Adjust entry logic, update indicator parameters, add trailing stops, or rework risk management without rebuilding the entire EA from scratch."}),o.jsx("li",{children:"Educational value. Studying how professional EAs implement features like multi-pair correlation, news filtering, or adaptive lot sizing is one of the fastest ways to improve your MQL4 skills."}),o.jsx("li",{children:"Platform migration. Use the decompiled MQ4 as a reference when porting an EA to MQL5, cTrader's cAlgo, or a Python-based trading framework."})]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"What You Risk"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base",children:[o.jsx("li",{children:"Legal exposure. Decompiling software you don't own or aren't licensed to modify may violate copyright law. Make sure you have the legal r
9089ight to decompile the specific file before you do it."}),o.jsx("li",{children:"Imperfect output. No decompiler achieves 100% accuracy on every file. Some sections may need manual cleanup, particularly in complex EAs with heavy optimization or obfuscation."}),o.jsx("li",{children:"Malware from bad tools. Downloading decompiler tools from unverified forum posts or file-sharing sites is a real risk. I personally found multiple tools with credential-stealing malware. Only use tools from established, verified sources."}),o.jsx("li",{children:"Misreading the code. Decompiled code without comments requires real MQL4 expertise to interpret. Misunderstanding the trading logic and modifying it incorrectly can cause serious losses on a live account."})]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"The Legal Landscape"}),o.jsx("p",{children:"Legality varies by jurisdiction. In the EU, the Software Directive (Directive 2009/24/EC) explicitly permits decompilation for interoperability. In the US, reverse engineering for interoperability, security research, and fair use has been upheld in multiple court cases. Most other jurisdictions have similar provisions."}),o.jsx("p",{children:"The practical question comes down to: do you own or have a license for the software, what's your purpose for decompiling it, and will you redistribute the result? Decompiling your own code for recovery is almost universally fine. Decompiling to study interoperability is widely protected. Decompiling someone else's code for commercial redistribution is almost certainly infringement. If you're uncertain about your specific situation, consult a lawyer."}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Practical Safety Measures"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base",children:[o.jsx("li",{children:"Only download from verified sources. Stick to official websites and established vendors. Check MQL5.com forum reviews before using anything new."}),o.jsx("li",{children:"Test new tools in a VM first. If you're trying an unfamiliar decompiler, run it inside a virtual machine to contain any potential malware."}),o.jsx("li",{children:"Keep the original EX4. The decompilation process doesn't modify your original file, but keep a verified backup regardless."}),o.jsx("li",{children:"Test thoroughly before going live. Never deploy decompiled code to a live account without extensive demo testing across multiple market conditions."})]})]}),o.jsxs(Be,{id:"verdict",title:"Final Verdict: ForexMQ5 Is the Best EX4 to MQ4 Decompilation Service",children:[o.jsx("p",{className:"text-lg leading-relaxed",children:"After months of testing every EX4 to MQ4 decompiler service and tool I could track down, here's where I landed."}),o.jsxs("div",{className:"bg-primary/10 border-2 border-primary rounded-lg p-8 my-8",children:[o.jsx("h3",{className:"font-serif text-2xl md:text-3xl font-bold text-center mb-4",children:"ForexMQ5 Delivers the Best Results"}),o.jsxs("div",{className:"text-center text-lg space-y-2",children:[o.jsx("p",{children:"95%+ code recovery rate across all MT4 build versions"}),o.jsx("p",{children:"Professional service starting from just $50 per file"}),o.jsx("p",{children:"Clean, readable output that compiles without errors"}),o.jsx("p",{children:"Money-back guarantee if they cannot deliver"}),o.jsx("p",{children:"Free tool available for old-build files as a bonus"})]}),o.jsx("div",{className:"text-center mt-6",children:o.jsx("a",{href:"https://forexmq5.com",target:"_blank",rel:"noopener noreferrer",children:o.jsxs(Ie,{size:"lg","data-testid":"button-verdict-cta",children:[o.jsx(za,{className:"mr-2 h-5 w-5"}),"Visit ForexMQ5"]})})})]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"Who Benefits Most"}),o.jsx("p",{children:"An EX4 decompiler is essential if you:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base mb-6",children:[o.jsx("li",{children:"Lost your MQ4 source code and need to recover it from the compiled EX4"}),o.jsx("li",{children:"Purchased an EA from a developer who is no longer reachable and you need modifications"}),o.jsx("li",{children:"Want to audit an Expert Advisor's code before trusting it with your live trading capital"}),o.jsx("li",{children:"Are an MQL4 developer studying how other EAs implement specific features"}),o.jsx("li",{children:"Need to port an EA from MetaTrader 4 to MetaTrader 5 or another platform"})]}),o.jsx("p",{children:"It is not the right tool if you:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2 text-base mb-6",children:[o.jsx("li",{children:"Are trying to steal proprietary trading IP that belongs to someone else"}),o.jsx("li",{children:"Plan to sell or commercially distribute decompiled code"}),o.jsx("li",{children:"Have zero programming background and will not be able to work with the output"})]}),o.jsx("h3",{className:"font-serif text-xl md:text-2xl font-semibold mt-8 mb-4",children:"My Recommendation"}),o.jsx("p",{children:"Submit your EX4 file to ForexMQ5. Their professional EX4 to MQ4 decompiler service handles all build versions with expert human review. Have an old-build file? Try their free tool first. Newer build? The professional service starts from $50 per file, which is a fraction of what it costs to rewrite the code from scratch."}),o.jsx("p",{children:"If you enjoy reverse engineering for its own sake, the DIY approach with x64dbg and ScyllaHide is a solid supplement. But for most traders and developers who need reliable results without spending days on a single file, a professional service wins every time."}),o.jsx("p",{children:"Every day without your source code is a day you can't fix bugs, optimize logic, adapt to market changes, or properly audit what's running on your account. You have a straightforward option in front of you."})]}),o.jsx(Be,{id:"faq",title:"Frequently Asked Questions",children:o.jsxs("div",{className:"space-y-6",children:[o.jsxs("div",{className:"border-l-4 border-primary pl-4",children:[o.jsx("h3",{className:"font-semibold text-lg mb-2",children:"What is an EX4 decompiler?"}),o.jsx("p",{className:"text-muted-foreground",children:"An EX4 decompiler is a tool or service that c
9089onverts compiled MetaTrader 4 files (EX4 format) back into readable MQL4 source code (MQ4 format). Professional services handle this entire process for you. You submit your EX4 file and receive clean, compilable MQ4 code with expert human review."})]}),o.jsxs("div",{className:"border-l-4 border-primary pl-4",children:[o.jsx("h3",{className:"font-semibold text-lg mb-2",children:"How accurate is EX4 to MQ4 decompilation?"}),o.jsx("p",{className:"text-muted-foreground",children:'Accuracy depends on the service and MT4 build version. The EX4 decompiler service achieves 95%+ accuracy across all build versions, including the latest 2025-2026 compilations. "Accuracy" means the decompiled output compiles without errors and produces identical trading behavior when tested against the original. Their expert team manually reviews every file to ensure the highest quality output.'})]}),o.jsxs("div",{className:"border-l-4 border-primary pl-4",children:[o.jsx("h3",{className:"font-semibold text-lg mb-2",children:"What is x64dbg and how does it help with EX4 analysis?"}),o.jsx("p",{className:"text-muted-foreground",children:"x64dbg (x32dbg for 32-bit MetaTrader 4) is a free open-source Windows debugger used in the DIY approach to EX4 analysis. You attach it to the running MT4 terminal and set breakpoints on MQL4 API functions like OrderSend or iMA. However, this requires significant reverse engineering expertise and hours of manual work per file. For most users, an EX4 decompiler service delivers better results in a fraction of the time."})]}),o.jsxs("div",{className:"border-l-4 border-primary pl-4",children:[o.jsx("h3",{className:"font-semibold text-lg mb-2",children:"Is it legal to decompile EX4 files?"}),o.jsx("p",{className:"text-muted-foreground",children:"Decompiling software you own or are licensed to use for personal recovery, interoperability, or security auditing is permitted in many jurisdictions, including under EU and US law. Decompiling code you do not own, or redistributing decompiled code commercially, is likely to violate copyright. Always verify the legality in your specific jurisdiction and check the software license agreement before proceeding."})]}),o.jsxs("div",{className:"border-l-4 border-primary pl-4",children:[o.jsx("h3",{className:"font-semibold text-lg mb-2",children:"Will the decompiled code look like the original?"}),o.jsx("p",{className:"text-muted-foreground",children:"With an EX4 decompiler service, the decompiled MQ4 will be functionally equivalent with meaningful variable names and clean formatting. While original comments cannot be recovered, the expert team manually reviews every file to ensure the output is readable and compilable. The trading logic, indicator calculations, and order management are accurately reconstructed."})]}),o.jsxs("div",{className:"border-l-4 border-primary pl-4",children:[o.jsx("h3",{className:"font-semibold text-lg mb-2",children:"Can all EX4 files be decompiled?"}),o.jsx("p",{className:"text-muted-foreground",children:"The EX4 decompiler service can handle the vast majority of EX4 files across all MT4 build versions. Files with custom obfuscation or heavy protection may require additional expert analysis, which their team is equipped to handle. Files that depend on external DLLs will have the MQ4 wrapper code decompiled but not the DLL internals. For any file you are unsure about, simply submit it for assessment."})]}),o.jsxs("div",{className:"border-l-4 border-primary pl-4",children:[o.jsx("h3",{className:"font-semibold text-lg mb-2",children:"How much does it cost to decompile an EX4 file?"}),o.jsx("p",{className:"text-muted-foreground",children:"Professional EX4 to MQ4 decompilation starts from just $50 per file at the EX4 decompiler service, with all MT4 build versions supported. They also offer a free tool for old-build files (pre-build 600) as a bonus. The service includes expert human review, meaningful variable renaming, and a money-back guarantee, making it the most cost-effective option compared to hiring a developer to rewrite your EA from scratch."})]}),o.jsxs("div",{className:"border-l-4 border-primary pl-4",children:[o.jsx("h3",{className:"font-semibold text-lg mb-2",children:"What about EX5 files for MetaTrader 5?"}),o.jsx("p",{className:"text-muted-foreground",children:"EX5 decompilation is significantly harder than EX4 decompilation. The MQL5 compiler produces more heavily optimized and protected bytecode. The EX4 decompiler service also handles EX5 to MQ5 decompilation. Contact them directly for pricing and availability. This guide focuses on EX4 to MQ4 decompilation, which is the more mature and widely supported process."})]})]})}),o.jsxs(Be,{id:"september-2026-update",title:"What's New in September 2026",children:[o.jsx("p",{children:"This month, we added a practical release-control guide and made substantive updates to three existing articles. The revisions clarify recovery handover, what an EX4 recovery can and cannot provide, and how buyers can set acceptance criteria for an EA review."}),o.jsxs("div",{className:"grid sm:grid-cols-2 gap-4 my-6",children:[o.jsxs(Z,{href:"/blog/mt4-ea-release-checklist-version-control-testing-rollback",className:"bg-card border rounded-lg p-5 hover-elevate transition-all group",children:[o.jsx("h3",{className:"font-serif text-lg font-semibold mb-2 group-hover:text-primary transition-colors",children:"MT4 EA Release Checklist"}),o.jsx("p",{className:"text-sm text-muted-foreground",children:"Keep source, compiled files, settings, test evidence, and rollback copies tied to the same release."})]}),o.jsxs(Z,{href:"/blog/recover-lost-mq4-expert-advisor-source-code",className:"bg-card border rounded-lg p-5 hover-elevate transition-all group",children:[o.jsx("h3",{className:"font-serif text-lg font-semibold mb-2 group-hover:text-primary transition-colors",children:"Recover Lost MQ4 Source Code"}),o.jsx("p",{className:"text-sm text-muted-foreground",children:"Updated with a controlled first-release process for recovered source and related files."})]}),o.jsxs(Z,{href:"/blog/ex4-files-explained-for-mt4-users",className:"bg-card border rounded-lg p-5 hover-elevate transition-all group",children:[o.jsx("h3",{className:"font-serif text-lg font-semibold mb-2 group-hover:text-primary transition-colors",children:"What EX4 Recovery Can Deliver"}),o.jsx("p",{className:"text-sm text-muted-foreground",children:"Clarifies the difference between recovered source and a complete, buildable MT4 project."})]}),o.jsxs(Z,{href:"/blog/forex-ea-code-audit-before-purchase",className:"bg-card border rounded-lg p-5 hover-elevate transition-all group",children:[o.jsx("h3",{className:"font-serif text-lg font-semibold mb-2 group-hover:text-primary transition-colors",children:"EA Audit Before Purchase"}),o.jsx("p",{className:"text-sm text-muted-foreground",children:"Adds a sample acceptance brief buyers can use to define review evidence and unresolved risks."})]})]}),o.jsx("p",{children:"Original publication dates remain unchanged. The three revised articles show a September 24, 2026 modified date because each received substantive new guidance."})]}),o.jsxs(Be,{id:"read-more",title:"Related Articles and Guides",children:[o.jsx("p",{className:"text-lg text-muted-foreground mb-8",children:"Go deeper on specific aspects of EX4 decompilation, MQL4 development, reverse engineering techniques, and Expert Advisor analysis."}),o.jsx("div",{className:"grid md:grid-cols-2 gap-6",children:[...zt].sort((a,i)=>i.dateISO.localeCompare(a.dateISO)).slice(0,20).map(a=>o.jsx(Z,{href:`/blog/${a.slug}`,className:"bg-card border rounded-lg p-5 hover-elevate transition-all group","data-testid":`link-blog-${a.slug}`,children:o.jsxs("div",{className:"flex items-start gap-4",children:[o.jsx("div",{className:"bg-primary/10 p-3 rounded-lg shrink-0",children:o.jsx(Pg,{className:"w-5 h-5 text-primary"})}),o.jsxs("div",{className:"flex-1 min-w-0",children:[o.jsx("h4",{className:"font-semibold text-base mb-2 line-clamp-2 group-hover:text-primary transition-colors",children:a.title}),o.jsx("p",{className:"text-sm text-muted-foreground line-clamp-2 mb-2",children:a.excerpt}),o.jsxs("div",{className:"flex items-center gap-2 text-xs text-muted-foreground",children:[o.jsx(Go,{className:"w-3 h-3"}),o.jsx("span",{children:a.readTime})]})]})]})},a.slug))}),o.jsx("div",{className:"mt-8 text-center",children:o.jsx(Z,{href:"/blog",children:o.jsxs(Ie,{variant:"outline","data-testid":"button-view-all-posts",children:["View All Articles",o.jsx($o,{className:"ml-2 h-4 w-4"})]})})})]})]})]})}),o.jsx(jr,{})]})]})}function G0(){return o.jsxs(o.Fragment,{children:[o.jsxs(qt,{children:[o.jsx("title",{children:"EX4 Decompiler Blog | Expert MQL4 Development Insights"}),o.jsx("meta",{name:"description",content:"Expert insights on EX4 decompilation, converting EX4 to MQ4, and MetaTrader 4 Expert Advisor development. Learn from professional MQL4 developers and discover the best decompiler tools."}),o.jsx("meta",{name:"keywords",content:"ex4 decompiler, ex4 to mq4, decompile ex4 to mq4, mql4 development, expert advisor, metatrader decompiler"}),o.jsx("link",{rel:"canonical",href:"https://forexdec.com/blog"}),o.jsx("meta",{name:"robots",content:"index, follow, max-image-preview:large, max-snippet:-1"}),o.jsx("meta",{property:"og:title",content:"EX4 Decompiler Blog | Expert MQL4 Development Insights"}),o.jsx("meta",{property:"og:description",content:"Expert insights on EX4 decompilation, converting EX4 to MQ4, and MetaTrader 4 Expert Advisor development."}),o.jsx("meta",{property:"og:type",content:"website"}),o.jsx("meta",{property:"og:url",content:"https://forexdec.com/blog"}),o.jsx("meta",{property:"og:image",content:"https://forexdec.com/og-image.png"})]}),o.jsxs("div",{className:"min-h-screen bg-background",children:[o.jsx(Rr,{}),o.jsxs("main",{className:"container mx-auto px-4 py-12",children:[o.jsx("nav",{className:"text-sm text-muted-foreground mb-8","aria-label":"Breadcrumb",children:o.jsxs("ol",{className:"flex items-center space-x-2",children:[o.jsx("li",{children:o.jsx(Z,{href:"/",className:"hover:text-primary",children:"Home"})}),o.jsx("li",{children:"/"}),o.jsx("li",{className:"text-foreground",children:"Blog"})]})}),o.jsxs("div",{className:"text-center mb-12",children:[o.jsx("h1",{className:"font-serif text-4xl md:text-5xl font-bold mb-4",children:"EX4 Decompiler Blog"}),o.jsx("p",{className:"text-xl text-muted-foreground max-w-2xl mx-auto",children:"Expert guides, tutorials, and insights on EX4 to MQ4 decompilation, MQL4 development, and MetaTrader Expert Advisor analysis."})]}),o.jsx("div",{className:"grid md:grid-cols-2 lg:grid-cols-3 gap-8",children:zt.map(e=>o.jsx("article",{className:"bg-card border rounded-lg overflow-hidden hover-elevate transition-all","data-testid":`blog-card-${e.slug}`,children:o.jsxs(Z,{href:`/blog/${e.slug}`,children:[o.jsx("div",{className:"aspect-video bg-muted relative overflow-hidden",children:o.jsx("img",{src:e.featuredImage,alt:e.imageAlt,className:"w-full h-full object-cover",loading:"lazy"})}),o.jsxs("div",{className:"p-6",children:[o.jsxs("div",{className:"flex items-center gap-4 text-sm text-muted-foreground mb-3",children:[o.jsxs("span",{className:"flex items-center gap-1",children:[o.jsx(Dg,{className:"w-4 h-4"}),"Last Updated ",e.lastModified||e.date]}),o.jsxs("span",{className:"flex items-center gap-1",children:[o.jsx(Go,{className:"w-4 h-4"}),e.readTime]})]}),o.jsx("h2",{className:"font-serif text-xl font-semibold mb-2 line-clamp-2",children:e.title}),o.jsx("p",{className:"text-muted-foreground line-clamp-3 mb-4",children:e.excerpt}),o.jsxs("span",{className:"text-primary font-medium flex items-center gap-1",children:["Read More ",o.jsx($o,{className:"w-4 h-4"})]})]})]})},e.slug))})]}),o.jsx(jr,{})]})]})}function Iv(){return o.jsx("div",{className:"min-h-screen w-full flex items-center justify-center bg-gray-50",children:o.jsx(xr,{className:"w-full max-w-md mx-4",children:o.jsxs($i,{className:"pt-6",children:[o.jsxs("div",{className:"flex mb-4 gap-2",children:[o.jsx(hk,{className:"h-8 w-8 text-red-500"}),o.jsx("h1",{className:"text-2xl font-bold text-gray-900",children:"404 Page Not Found"})]}),o.jsx("p",{className:"mt-4 text-sm text-gray-600",children:"Did you forget to add the page to the router?"})]})})})}function K0(){const{slug:e}=Hf(),t=zt.find(s=>
9089s.slug===e);if(w.useEffect(()=>{window.scrollTo(0,0)},[e]),!t)return o.jsx(Iv,{});const r=zt.findIndex(s=>s.slug===e),a=r>0?zt[r-1]:null,i=r<zt.length-1?zt[r+1]:null,n=zt.filter(s=>s.slug!==e).slice(0,3);return o.jsxs(o.Fragment,{children:[o.jsxs(qt,{children:[o.jsx("title",{children:t.metaTitle}),o.jsx("meta",{name:"description",content:t.metaDescription}),o.jsx("meta",{name:"keywords",content:t.keywords}),o.jsx("link",{rel:"canonical",href:`https://forexdec.com/blog/${t.slug}`}),o.jsx("meta",{name:"robots",content:"index, follow, max-image-preview:large, max-snippet:-1, max-video-preview:-1"}),o.jsx("meta",{property:"og:title",content:t.metaTitle}),o.jsx("meta",{property:"og:description",content:t.metaDescription}),o.jsx("meta",{property:"og:type",content:"article"}),o.jsx("meta",{property:"og:url",content:`https://forexdec.com/blog/${t.slug}`}),o.jsx("meta",{property:"og:image",content:"https://forexdec.com/og-image.png"}),o.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),o.jsx("meta",{name:"twitter:title",content:t.metaTitle}),o.jsx("meta",{name:"twitter:description",content:t.metaDescription}),o.jsx("meta",{name:"twitter:image",content:"https://forexdec.com/og-image.png"})]}),o.jsxs("div",{className:"min-h-screen bg-background",children:[o.jsx(Rr,{}),o.jsxs("main",{className:"container mx-auto px-4 py-12",children:[o.jsx("nav",{className:"text-sm text-muted-foreground mb-8","aria-label":"Breadcrumb",children:o.jsxs("ol",{className:"flex items-center space-x-2",children:[o.jsx("li",{children:o.jsx(Z,{href:"/",className:"hover:text-primary",children:"Home"})}),o.jsx("li",{children:"/"}),o.jsx("li",{children:o.jsx(Z,{href:"/blog",className:"hover:text-primary",children:"Blog"})}),o.jsx("li",{children:"/"}),o.jsx("li",{className:"text-foreground truncate max-w-[200px]",children:t.title})]})}),o.jsxs("article",{className:"max-w-4xl mx-auto",children:[o.jsxs("header",{className:"mb-8",children:[o.jsx("h1",{className:"font-serif text-3xl md:text-4xl lg:text-5xl font-bold mb-4",children:t.title}),o.jsxs("div",{className:"flex flex-wrap items-center gap-4 text-muted-foreground",children:[o.jsxs("span",{className:"flex items-center gap-1",children:[o.jsx(fk,{className:"w-4 h-4"}),"Alex M"]}),o.jsxs("span",{className:"flex items-center gap-1",children:[o.jsx(Dg,{className:"w-4 h-4"}),"Last Updated ",t.lastModified||t.date]}),o.jsxs("span",{className:"flex items-center gap-1",children:[o.jsx(Go,{className:"w-4 h-4"}),t.readTime]})]})]}),o.jsx("div",{className:"aspect-video bg-muted rounded-lg overflow-hidden mb-8",children:o.jsx("img",{src:t.featuredImage,alt:t.imageAlt,className:"w-full h-full object-cover"})}),o.jsxs("div",{className:"bg-card border rounded-lg p-6 mb-8",children:[o.jsx("h2",{className:"font-semibold mb-4",children:"Table of Contents"}),o.jsx("nav",{children:o.jsx("ul",{className:"space-y-2",children:t.tableOfContents.map((s,l)=>o.jsx("li",{children:o.jsx("a",{href:`#${s.id}`,className:"text-muted-foreground hover:text-primary transition-colors",children:s.title})},l))})})]}),o.jsx("div",{className:"prose prose-lg dark:prose-invert max-w-none",dangerouslySetInnerHTML:{__html:t.content}}),o.jsxs("div",{className:"flex flex-col sm:flex-row gap-4 justify-between mt-12 pt-8 border-t",children:[a?o.jsx(Z,{href:`/blog/${a.slug}`,children:o.jsxs(Ie,{variant:"outline",className:"w-full sm:w-auto",children:[o.jsx(dk,{className:"w-4 h-4 mr-2"}),"Previous Post"]})}):o.jsx("div",{}),i&&o.jsx(Z,{href:`/blog/${i.slug}`,children:o.jsxs(Ie,{variant:"outline",className:"w-full sm:w-auto",children:["Next Post",o.jsx($o,{className:"w-4 h-4 ml-2"})]})})]}),o.jsxs("section",{className:"mt-12 pt-8 border-t",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mb-6",children:"Related Articles"}),o.jsx("div",{className:"grid md:grid-cols-3 gap-6",children:n.map(s=>o.jsxs(Z,{href:`/blog/${s.slug}`,className:"bg-card border rounded-lg p-4 hover-elevate transition-all",children:[o.jsx("h3",{className:"font-semibold line-clamp-2 mb-2",children:s.title}),o.jsx("p",{className:"text-sm text-muted-foreground line-clamp-2",children:s.excerpt})]},s.slug))})]})]})]}),o.jsx(jr,{})]})]})}function Y0(){return w.useEffect(()=>{window.scrollTo(0,0)},[]),o.jsxs("div",{className:"min-h-screen flex flex-col",children:[o.jsxs(qt,{children:[o.jsx("title",{children:"Privacy Policy | forexdec"}),o.jsx("meta",{name:"description",content:"Privacy Policy for forexdec - Learn how we 
9089collect, use, and protect your personal information on our independent EX4 decompiler review site."}),o.jsx("link",{rel:"canonical",href:"https://forexdec.com/privacy-policy"}),o.jsx("meta",{name:"robots",content:"noindex, follow"})]}),o.jsx(Rr,{}),o.jsx("main",{className:"flex-1 bg-background",children:o.jsxs("div",{className:"max-w-4xl mx-auto px-6 py-12",children:[o.jsx("h1",{className:"font-serif text-4xl font-bold mb-8",children:"Privacy Policy"}),o.jsxs("div",{className:"prose prose-slate max-w-none space-y-6",children:[o.jsxs("p",{className:"text-muted-foreground",children:[o.jsx("strong",{children:"Effective Date:"})," November 22, 2025"]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"1. Information We Collect"}),o.jsx("p",{children:"forexdec collects information to provide better services to our users. We collect information in the following ways:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsxs("li",{children:[o.jsx("strong",{children:"Information you give us:"})," When you contact us or sign up for our newsletter, we may collect personal information such as your name and email address."]}),o.jsxs("li",{children:[o.jsx("strong",{children:"Information we get from your use of our services:"})," We collect information about the services that you use and how you use them, including IP address, browser type, and pages visited."]}),o.jsxs("li",{children:[o.jsx("strong",{children:"Cookies and similar technologies:"})," We use cookies and similar technologies to collect information about your browsing activities."]})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"2. How We Use Information"}),o.jsx("p",{children:"We use the information we collect to:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"Provide, maintain, and improve our services and EX4 decompiler reviews"}),o.jsx("li",{children:"Send you updates, newsletters, and marketing communications (with your consent)"}),o.jsx("li",{children:"Respond to your comments, questions, and requests about EX4 to MQ4 decompilation"}),o.jsx("li",{children:"Monitor and analyze trends, usage, and activities"}),o.jsx("li",{children:"Detect, prevent, and address technical issues and fraudulent activity"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"3. Information Sharing"}),o.jsx("p",{children:"We do not share your personal information with companies, organizations, or individuals outside of forexdec except in the following cases:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsxs("li",{children:[o.jsx("strong",{children:"With your consent:"})," We will share personal information when we have your consent."]}),o.jsxs("li",{children:[o.jsx("strong",{children:"For legal reasons:"})," We will share personal information if we believe that access, use, preservation, or disclosure is necessary to comply with applicable law or legal process."]}),o.jsxs("li",{children:[o.jsx("strong",{children:"With service providers:"})," We may share information with trusted service providers who assist us in operating our website and conducting our business."]})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"4. Third-Party Links"}),o.jsx("p",{children:"Our website may contain links to third-party websites, including EX4 decompiler tools and services we review. We are not responsible for the privacy practices or content of these external sites. We encourage you to review the privacy policies of any third-party sites you visit."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"5. Data Security"}),o.jsx("p",{children:"We implement appropriate technical and organizational measures to protect your personal information against unauthorized access, alteration, disclosure, or destruction. However, no method of transmission over the Internet is 100% secure."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"6. Your Rights"}),o.jsx("p",{children:"You have the right to:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"Access the personal information we hold about you"}),o.jsx("li",{children:"Request correction of inaccurate information"}
9089),o.jsx("li",{children:"Request deletion of your personal information"}),o.jsx("li",{children:"Object to or restrict processing of your information"}),o.jsx("li",{children:"Withdraw consent at any time"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"7. Cookies"}),o.jsx("p",{children:"We use cookies and similar tracking technologies to track activity on our website and store certain information. You can instruct your browser to refuse all cookies or to indicate when a cookie is being sent."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"8. Changes to This Privacy Policy"}),o.jsx("p",{children:'We may update our Privacy Policy from time to time. We will notify you of any changes by posting the new Privacy Policy on this page and updating the "Effective Date" at the top.'})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"9. Contact Us"}),o.jsx("p",{children:"If you have any questions about this Privacy Policy, please contact us through our website."})]})]})]})}),o.jsx(jr,{})]})}function J0(){return w.useEffect(()=>{window.scrollTo(0,0)},[]),o.jsxs("div",{className:"min-h-screen flex flex-col",children:[o.jsxs(qt,{children:[o.jsx("title",{children:"Terms of Service | forexdec"}),o.jsx("meta",{name:"description",content:"Terms of Service for forexdec - Review our terms and conditions for using our independent EX4 decompiler review website."}),o.jsx("link",{rel:"canonical",href:"https://forexdec.com/terms-of-service"}),o.jsx("meta",{name:"robots",content:"noindex, follow"})]}),o.jsx(Rr,{}),o.jsx("main",{className:"flex-1 bg-background",children:o.jsxs("div",{className:"max-w-4xl mx-auto px-6 py-12",children:[o.jsx("h1",{className:"font-serif text-4xl font-bold mb-8",children:"Terms of Service"}),o.jsxs("div",{className:"prose prose-slate max-w-none space-y-6",children:[o.jsxs("p",{className:"text-muted-foreground",children:[o.jsx("strong",{children:"Effective Date:"})," November 22, 2025"]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"1. Acceptance of Terms"}),o.jsx("p",{children:'By accessing and using forexdec ("we," "us," or "our"), you accept and agree to be bound by the terms and provisions of this agreement. If you do not agree to these Terms of Service, please do not use our website.'})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"2. Use of Website"}),o.jsx("p",{children:"Our website provides information, reviews, and educational content about EX4 decompiler tools, EX4 to MQ4 conversion services, and MQL4 development. You agree to use the website only for lawful purposes and in a way that does not infringe the rights of others or restrict their use and enjoyment of the website."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"3. Intellectual Property"}),o.jsx("p",{children:"The content, organization, graphics, design, and other matters related to forexdec are protected under applicable copyrights and other proprietary laws. Copying, redistribution, or publication of any such matters or any part of the website is prohibited without our express written permission."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"4. Disclaimer of Warranties"}),o.jsx("p",{children:"The information provided on forexdec is for general informational and educational purposes only. We make no warranties or representations about the accuracy or completeness of the information provided."}),o.jsx("p",{children:o.jsx("strong",{children:'THE WEBSITE AND ALL CONTENT ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED.'})})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"5. Software and Decompilation Disclaimer"}),o.jsxs("p",{children:[o.jsx("strong",{children:"Important:"})," EX4 decompilation and reverse engineering of software may be subject to legal restrictions in certain 
9089jurisdictions. The information on this website does not constitute legal advice. You should:"]}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"Consult with qualified legal professionals before decompiling software you do not own"}),o.jsx("li",{children:"Understand that decompilation may violate software license agreements"}),o.jsx("li",{children:"Only decompile EX4 files you have legal rights to access and modify"}),o.jsx("li",{children:"Conduct your own due diligence before using any decompiler tool or service"}),o.jsx("li",{children:"Respect intellectual property rights of original software developers"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"6. Limitation of Liability"}),o.jsx("p",{children:"forexdec, its owners, employees, and affiliates will not be liable for any losses, damages, or claims arising from:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"Use of information provided on our website"}),o.jsx("li",{children:"Reliance on reviews or recommendations of EX4 decompiler tools"}),o.jsx("li",{children:"Performance of third-party decompiler tools or services we review"}),o.jsx("li",{children:"Legal consequences of decompiling software"}),o.jsx("li",{children:"Errors, omissions, or inaccuracies in our content"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"7. Third-Party Services"}),o.jsx("p",{children:"We review and discuss third-party EX4 decompiler tools and services. We are not responsible for:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"The quality, safety, or legality of third-party decompiler tools"}),o.jsx("li",{children:"The accuracy of third-party claims or representations"}),o.jsx("li",{children:"Disputes between you and any third-party service provider"}),o.jsx("li",{children:"Changes to third-party services after our review"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"8. User Conduct"}),o.jsx("p",{children:"You agree not to:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"Use the website for any illegal purpose"}),o.jsx("li",{children:"Attempt to gain unauthorized access to our systems"}),o.jsx("li",{children:"Interfere with or disrupt the website's operation"}),o.jsx("li",{children:"Copy, reproduce, or distribute our content without permission"}),o.jsx("li",{children:"Use automated systems to access the website without consent"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"9. Indemnification"}),o.jsx("p",{children:"You agree to indemnify and hold harmless forexdec and its affiliates from any claims, damages, losses, liabilities, and expenses arising from your use of the website or violation of these Terms of Service."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"10. Changes to Terms"}),o.jsx("p",{children:"We reserve the right to modify these Terms of Service at any time. Changes will be effective immediately upon posting to the website. Your continued use of the website after changes constitutes acceptance of the modified terms."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"11. Governing Law"}),o.jsx("p",{children:"These Terms of Service shall be governed by and construed in accordance with applicable laws, without regard to conflict of law principles."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"12. Contact Information"}),o.jsx("p",{children:"If you have any questions about these Terms of Service, please contact us through our website."})]})]})]})}),o.jsx(jr,{})]})}function Z0(){return w.useEffect(()=>{window.scrollTo(0,0)},[]),o.jsxs("div",{className:"min-h-screen flex flex-col",children:[o.jsxs(qt,{children:[o.jsx("title",{children:"Disclaimer | forexdec"}),o.jsx("meta",{name:"description",content:"Important disclaimers for forexdec regarding our independent reviews of EX4 to MQ4 decompilation tools and services."}),o.jsx("link",{rel:"canonical",href:"https://forexdec.com/disclaimer"}),o.jsx("meta",{name:"robots",content:"noindex, follow"})]}),o.jsx(Rr,{}),o.jsx("main",{className:"flex-1 bg-background",children:o.jsxs("div",{className:"max-w-4xl mx-auto px-6 py-12",children:[o.jsx("h1",{className:"font-serif text-4xl font-bold mb-8",children:"Disclaimer"}),o.jsxs("div",{className:"prose prose-slate max-w-none space-y-6",children:[o.jsxs("p",{className:"text-muted-foreground",children:[o.jsx("strong",{children:"Last Updated:"})," November 22, 2025"]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"General Information"}),o.jsx("p",{children:"The information provided by forexdec is for general informational and educational purposes only. All information on the website is provided in good faith; however, we make no representation or warranty of any kind, express or implied, regarding the accuracy, adequacy, validity, reliability, availability, or completeness of any information on the website."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"Not Legal Advice"}),o.jsx("p",{children:o.jsx("strong",{className:"text-destructive",children:"IMPORTANT: The content on this website does not constitute legal advice or any other sort of professional advice."})}),o.jsx("p",{children:"forexdec is a review and informational website about EX4 decompiler tools and EX4 to MQ4 conversion services. We do not provide personalized legal or technical advice. All content should be considered as general information only. You should:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"Consult with a qualified legal advisor before decompiling software"}),o.jsx("li",{children:"Conduct your own research and due diligence on the legality of decompilation in your jurisdiction"}),o.jsx("li",{children:"Understand your rights and obligations regarding software reverse engineering"}),o.jsx("li",{children:"Review software license agreements before using decompiler tools"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"Software and Decompilation Risks"}),o.jsxs("p",{children:[o.jsx("strong",{children:"EX4 decompilation and reverse engineering involve inherent risks and legal considerations."})," Using EX4 decompiler tools may involve:"]}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"Potential violation of software license agreements"}),o.jsx("li",{children:"Copyright infringement if decompiling code you do not own or have rights to"}),o.jsx("li",{children:"Security risks from downloading unverified decompiler tools"}),o.jsx("li",{children:"Inaccurate or incomplete code recovery that may affect trading systems"}),o.jsx("li",{children:"No guarantee of successful decompilation for all EX4 file types"}),o.jsx("li",{children:"Financial losses if decompiled Expert Advisors contain errors when used for live trading"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"Accuracy of Decompilation Results"}),o.jsx("p",{children:"Decompilation results vary based on numerous factors including the MT4 build version, obfuscation techniques used, and the quality of the decompiler tool. Any statistics, success rates, or accuracy claims provided on this website represent general observations and should not be interpreted as guaranteed results. Individual outcomes will vary based on:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"The specific EX4 file being decompiled"}),o.jsx("li",{children:"The MetaTrader 4 build version used for c
9089ompilation"}),o.jsx("li",{children:"Whether obfuscation or protection was applied"}),o.jsx("li",{children:"The decompiler tool or service used"}),o.jsx("li",{children:"Complexity of the original MQL4 code"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"Third-Party Tools and Services"}),o.jsx("p",{children:"We review third-party EX4 decompiler tools and services. We cannot guarantee:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"The quality, legality, or safety of third-party decompiler tools"}),o.jsx("li",{children:"That third-party tools will perform as claimed"}),o.jsx("li",{children:"The accuracy of statistics or claims made by third parties"}),o.jsx("li",{children:"That third-party tools are free from malware or security vulnerabilities"}),o.jsx("li",{children:"The ongoing availability or terms of third-party tools"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"Intellectual Property"}),o.jsx("p",{children:"Decompiling software may implicate intellectual property rights. You are responsible for:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"Verifying your legal r
9089ight to decompile specific EX4 files"}),o.jsx("li",{children:"Understanding copyright laws in your jurisdiction"}),o.jsx("li",{children:"Complying with all applicable laws and regulations regarding reverse engineering"}),o.jsx("li",{children:"Respecting the intellectual property of original software developers"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"Accuracy of Information"}),o.jsx("p",{children:"While we strive to keep information accurate and up-to-date, EX4 decompiler tools, pricing, features, and capabilities change frequently. We cannot guarantee that:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"All information on our website is current"}),o.jsx("li",{children:"Tool features described still exist as stated"}),o.jsx("li",{children:"Pricing information remains accurate"}),o.jsx("li",{children:"Tools reviewed are still available or functioning"})]}),o.jsx("p",{children:o.jsx("strong",{children:"Always verify information directly with tool providers before making decisions."})})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"No Guarantees"}),o.jsx("p",{children:"We make no guarantees or warranties regarding:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"Your ability to successfully decompile any specific EX4 file"}),o.jsx("li",{children:"The accuracy or completeness of decompiled MQ4 code"}),o.jsx("li",{children:"The performance of any decompiler tool we review"}),o.jsx("li",{children:"Financial outcomes from using decompiled Expert Advisors for trading"}),o.jsx("li",{children:"Availability of refunds or money-back guarantees from third-party providers"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"Limitation of Liability"}),o.jsx("p",{children:"Under no circumstances shall forexdec, its owners, or contributors be liable for any direct, indirect, incidental, consequential, or punitive damages arising from:"}),o.jsxs("ul",{className:"list-disc pl-6 space-y-2",children:[o.jsx("li",{children:"Your use of information on this website"}),o.jsx("li",{children:"Trading losses from using decompiled Expert Advisors"}),o.jsx("li",{children:"Legal consequences of decompiling software"}),o.jsx("li",{children:"Performance or failure of third-party decompiler tools"}),o.jsx("li",{children:"Errors, omissions, or inaccuracies in our content"})]})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"External Links"}),o.jsx("p",{children:"Our website contains links to external websites. We have no control over and assume no responsibility for the content, privacy policies, or practices of third-party websites. You acknowledge and agree that we shall not be liable for any damage or loss caused by use of any third-party content or services."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"Changes to Disclaimer"}),o.jsx("p",{children:"We reserve the right to modify this disclaimer at any time. Changes and clarifications will take effect immediately upon posting on the website. We encourage you to review this disclaimer periodically."})]}),o.jsxs("section",{className:"space-y-4",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mt-8",children:"Contact"}),o.jsx("p",{children:"If you have questions about this disclaimer, please contact us through our website."})]})]})]})}),o.jsx(jr,{})]})}function e4(){return w.useEffect(()=>{window.scrollTo(0,0)},[]),o.jsxs("div",{className:"min-h-screen flex flex-col",children:[o.jsxs(qt,{children:[o.jsx("title",{children:"Contact | forexdec"}),o.jsx("meta",{name:"description",content:"Contact forexdec - reach out with questions about our EX4 decompiler reviews or the ForexMQ5 professional decompilation service."}),o.jsx("link",{rel:"canonical",href:"https://forexdec.com/contact"}),o.jsx("meta",{name:"robots",content:"noindex, follow"})]}),o.jsx(Rr,{}),o.jsx("main",{className:"flex-1 bg-background",children:o.jsxs("div",{className:"max-w-4xl mx-auto px-6 py-12",children:[o.jsx("h1",{className:"font-serif text-4xl font-bold mb-4",children:"Contact Us"}),o.jsx("p",{className:"text-lg text-muted-foreground mb-12",children:"Have questions about EX4 decompiler tools or EX4 to MQ4 conversion? We're here to help."}),o.jsxs("div",{className:"grid md:grid-cols-2 gap-8 mb-12",children:[o.jsx(xr,{className:"p-8",children:o.jsxs("div",{className:"flex items-start gap-4",children:[o.jsx("div",{className:"p-3 bg-primary/10 rounded-lg",children:o.jsx(uk,{className:"h-6 w-6 text-primary"})}),o.jsxs("div",{children:[o.jsx("h3",{className:"font-serif text-xl font-semibold mb-2",children:"Email Us"}),o.jsx("p",{className:"text-muted-foreground mb-4",children:"For general inquiries, feedback, or questions about our EX4 decompiler reviews."}),o.jsx("a",{href:"mailto:[email protected]",className:"text-primary hover:underline","data-testid":"link-email",children:"[email protected]"})]})]})}),o.jsx(xr,{className:"p-8",children:o.jsxs("div",{className:"flex items-start gap-4",children:[o.jsx("div",{className:"p-3 bg-primary/10 rounded-lg",children:o.jsx(pk,{className:"h-6 w-6 text-primary"})}),o.jsxs("div",{children:[o.jsx("h3",{className:"font-serif text-xl font-semibold mb-2",children:"Feedback"}),o.jsx("p",{className:"text-muted-foreground mb-4",children:"Share your experience with EX4 decompiler tools or suggest tools for us to review."}),o.jsx("a",{href:"mailto:[email protected]",className:"text-primary hover:underline","data-testid":"link-feedback",children:"[email protected]"})]})]})})]}),o.jsxs(xr,{className:"p-8 bg-muted/30",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mb-4",children:"Important Notes"}),o.jsxs("ul",{className:"space-y-3 text-muted-foreground",children:[o.jsxs("li",{className:"flex gap-2",children:[o.jsx("span",{className:"text-primary mt-1",children:"•"}),o.jsx("span",{children:"We are an independent review website for EX4 decompiler tools and services."})]}),o.jsxs("li",{className:"flex gap-2",children:[o.jsx("span",{className:"text-primary mt-1",children:"•"}),o.jsx("span",{children:"We do not provide legal advice regarding software decompilation. Please consult qual
9089ified professionals for legal guidance."})]}),o.jsxs("li",{className:"flex gap-2",children:[o.jsx("span",{className:"text-primary mt-1",children:"•"}),o.jsx("span",{children:"For technical support related to specific EX4 decompiler tools, please contact those tool providers directly."})]}),o.jsxs("li",{className:"flex gap-2",children:[o.jsx("span",{className:"text-primary mt-1",children:"•"}),o.jsx("span",{children:"We typically respond to inquiries within 24-48 hours during business days."})]})]})]})]})}),o.jsx(jr,{})]})}function t4(){return o.jsxs(o.Fragment,{children:[o.jsxs(qt,{children:[o.jsx("title",{children:"About forexdec - Independent EX4 Decompiler Review Site"}),o.jsx("meta",{name:"description",content:"forexdec is an independent review site run by MQL4 developer Alex M. We test and review EX4 decompiler services so you can make an informed decision."}),o.jsx("meta",{name:"robots",content:"index, follow, max-image-preview:large, max-snippet:-1"}),o.jsx("link",{rel:"canonical",href:"https://forexdec.com/about"}),o.jsx("meta",{property:"og:title",content:"About forexdec - Independent EX4 Decompiler Review Site"}),o.jsx("meta",{property:"og:description",content:"forexdec is an independent review site run by MQL4 developer Alex M. We test and review EX4 decompiler services so you can make an informed decision."}),o.jsx("meta",{property:"og:type",content:"website"}),o.jsx("meta",{property:"og:url",content:"https://forexdec.com/about"}),o.jsx("meta",{property:"og:image",content:"https://forexdec.com/og-image.png"}),o.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),o.jsx("meta",{name:"twitter:title",content:"About forexdec - Independent EX4 Decompiler Review Site"}),o.jsx("meta",{name:"twitter:description",content:"forexdec is an independent review site run by MQL4 developer Alex M. We test and review EX4 decompiler services so you can make an informed decision."}),o.jsx("meta",{name:"twitter:image",content:"https://forexdec.com/og-image.png"})]}),o.jsxs("div",{className:"min-h-screen bg-background",children:[o.jsx(Rr,{}),o.jsxs("main",{className:"max-w-4xl mx-auto px-4 sm:px-6 py-12 sm:py-16",children:[o.jsxs("div",{className:"mb-10",children:[o.jsx("h1",{className:"font-serif text-3xl sm:text-4xl font-bold mb-4",children:"About This Site"}),o.jsx("p",{className:"text-lg text-muted-foreground",children:"forexdec is an independent review site dedicated to evaluating EX4 decompilation services. We test services hands-on so traders and developers can make an informed choice."})]}),o.jsx(xr,{className:"mb-10 border-primary/20",children:o.jsx($i,{className:"p-6 sm:p-8",children:o.jsxs("div",{className:"flex flex-col sm:flex-row gap-6",children:[o.jsx("div",{className:"flex-shrink-0 flex justify-center sm:justify-start",children:o.jsx("img",{src:Cv,alt:"Alex M, MQL4 Expert Advisor developer and EX4 decompiler reviewer",className:"w-24 h-24 rounded-full object-cover border-2 border-primary/20"})}),o.jsxs("div",{className:"flex-1",children:[o.jsxs("div",{className:"flex flex-wrap items-center gap-2 mb-2",children:[o.jsx("h2",{className:"text-xl font-semibold",children:"Alex M"}),o.jsxs(Lr,{variant:"secondary",className:"text-xs",children:[o.jsx(Ui,{className:"w-3 h-3 mr-1"}),"Verified Expert"]})]}),o.jsx("p",{className:"text-sm text-muted-foreground mb-4",children:"MQL4 & MQL5 Expert Advisor Developer, Site Author & Lead Reviewer"}),o.jsxs("div",{className:"flex flex-wrap gap-2 mb-4",children:[o.jsx(Lr,{variant:"outline",className:"text-xs",children:"10+ Years MQL4 Development"}),o.jsx(Lr,{variant:"outline",className:"text-xs",children:"500+ EAs Built"}),o.jsx(Lr,{variant:"outline",className:"text-xs",children:"MT4 & MT5 Specialist"}),o.jsx(Lr,{variant:"outline",className:"text-xs",children:"Reverse Engineering"})]}),o.jsx("p",{className:"text-sm leading-relaxed",children:"Alex M has spent over a decade building Expert Advisors, custom indicators, and trading scripts for MetaTrader 4 and MetaTrader 5. She has developed hundreds of automated trading systems for retail and institutional clients, from simple moving average crossover EAs to complex multi-pair grid strategies with dynamic position sizing. Her deep, practical understanding of MQL4 internals, the MT4 compilation process, and EA binary structure is 
9089what makes her assessments of decompiler services reliable and grounded in real technical experience."})]})]})})}),o.jsxs("section",{className:"mb-10",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mb-6",children:"Why This Site Exists"}),o.jsxs("div",{className:"space-y-4 text-base leading-relaxed",children:[o.jsx("p",{children:"The EX4 decompilation space is full of noise. Forum threads recommend outdated tools. Free decompilers from unknown sources carry real malware risk. And the handful of professional services that do quality work are buried under low-effort review sites that have never tested anything."}),o.jsx("p",{children:"This site exists to cut through that. We test EX4 decompiler services by sending real files through them, comparing the output against known source code, and evaluating the results honestly. We cover the full picture: what works, what doesn't, and why. We also document the DIY approach using x64dbg and ScyllaHide so technically-minded readers understand exactly what the manual alternative involves."}),o.jsxs("p",{children:["Our primary recommendation is the professional ",o.jsx(Z,{href:"/",className:"text-primary hover:underline font-medium",children:"ex4 decompiler"})," service at ForexMQ5.com, which consistently delivers the best output quality and turnaround time in our testing. When we recommend a service, it is because we have used it ourselves on real files and evaluated the results against the original source."]})]})]}),o.jsxs("section",{className:"mb-10",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mb-6",children:"Our Testing Methodology"}),o.jsx("div",{className:"grid sm:grid-cols-2 gap-4",children:[{icon:mk,title:"Real Files, Real Tests",desc:"We submit actual EX4 files, including our own compiled EAs with known source code, to each service and evaluate the output for accuracy, readability, and compilability."},{icon:Pg,title:"Source Code Comparison",desc:"Where we have access to original MQ4 source, we compare decompiled output line by line. We measure logic accuracy, variable naming quality, and whether the output compiles without errors."},{icon:Go,title:"Turnaround Tracking",desc:"We record actual turnaround times, not quoted estimates. We test across different file types, build versions, and complexity levels to get a realistic picture of what to expect."},{icon:ck,title:"Build Version Coverage",desc:"We specifically test with post-build-600 EX4 files, which are significantly harder to decompile than older builds. Most free tools fail on these. Professional services are evaluated on their hardest cases."}].map(({icon:e,title:t,desc:r})=>o.jsx(xr,{children:o.jsx($i,{className:"p-5",children:o.jsxs("div",{className:"flex items-start gap-3",children:[o.jsx(e,{className:"w-5 h-5 text-primary mt-0.5 flex-shrink-0"}),o.jsxs("div",{children:[o.jsx("h3",{className:"font-semibold mb-1",children:t}),o.jsx("p",{className:"text-sm text-muted-foreground leading-relaxed",children:r})]})]})})},t))})]}),o.jsxs("section",{className:"mb-10",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mb-6",children:"Editorial Independence"}),o.jsxs("div",{className:"space-y-4 text-base leading-relaxed",children:[o.jsx("p",{children:"forexdec is an independent review site. We are not owned or operated by any decompilation service. When we link to ForexMQ5.com, it is because our testing indicates they deliver the best results, not because of any commercial arrangement that would compromise our assessment."}),o.jsx("p",{children:"All reviews on this site are based on hands-on testing. We document our methodology, report what we observe, and update our assessments when services change. If a service we currently recommend declines in quality, we will report that."}),o.jsxs("p",{children:["Our goal is to be the most useful resource on the internet for anyone who needs to ",o.jsx(Z,{href:"/",className:"text-primary hover:underline font-medium",children:"decompile ex4 to mq4"})," and wants to understand all available options before making a decision."]})]})]}),o.jsxs("section",{className:"mb-10",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mb-6",children:"Alex's Backgroun
9089d in MQL4 Development"}),o.jsxs("div",{className:"space-y-4 text-base leading-relaxed",children:[o.jsx("p",{children:"Alex started writing MQL4 code in 2012, initially building simple indicator-based EAs for her own trading. Over time, that expanded into client work: developing custom Expert Advisors, rewriting broken or outdated EAs, building complex multi-currency systems, and creating custom indicators for professional traders. She has worked with EAs ranging from straightforward moving average systems to sophisticated grid and martingale strategies with dynamic lot sizing, equity protection, and broker-specific optimizations."}),o.jsx("p",{children:"Her involvement in decompilation work came through client projects where the original source code had been lost or the original developer was unavailable. These real-world experiences, dealing with corrupt backups, disappeared freelancers, and legacy code from discontinued platforms, are what shaped her perspective on the decompilation space. She has seen firsthand which services deliver clean, workable output and which produce unusable results."}),o.jsx("p",{children:"She holds deep familiarity with MQL4's internal architecture: how the MetaEditor compiler processes source code, how the EX4 bytecode maps back to MQL4 functions, how MT4's runtime executes EA logic tick by tick, and where decompilation inherently loses information (comments, original variable names) versus what can be accurately reconstructed (trading logic, indicator calls, order management). This technical foundation is what makes her evaluation of decompiler output meaningful rather than surface-level."})]})]}),o.jsxs("section",{className:"mb-10",children:[o.jsx("h2",{className:"font-serif text-2xl font-semibold mb-4",children:"Credentials At a Glance"}),o.jsx("ul",{className:"space-y-2",children:["10+ years active MQL4 and MQL5 Expert Advisor development","500+ custom EAs built for retail and institutional clients","Hands-on experience with MetaTrader 4 internals and compilation pipeline","Extensive reverse engineering experience using x64dbg and ScyllaHide","Testing of 12+ decompilation tools and services since 2015","Deep familiarity with MT4 build versions and their decompilation difficulty differences","Ongoing testing updated through April 2026"].map(e=>o.jsxs("li",{className:"flex items-start gap-2 text-sm",children:[o.jsx(Ui,{className:"w-4 h-4 text-primary mt-0.5 flex-shrink-0"}),o.jsx("span",{children:e})]},e))})]}),o.jsxs("div",{className:"border rounded-lg p-6 text-center bg-muted/30",children:[o.jsx("h2",{className:"font-semibold text-lg mb-2",children:"Ready to See the Full Review?"}),o.jsx("p",{className:"text-muted-foreground text-sm mb-4",children:"Read our comprehensive, hands-on assessment of the best EX4 decompiler service available in 2026."}),o.jsxs("div",{className:"flex flex-wrap gap-3 justify-center",children:[o.jsx(Z,{href:"/",children:o.jsx(Ie,{variant:"default",children:"Read the Full Review"})}),o.jsx("a",{href:"https://forexmq5.com",target:"_blank",rel:"noopener noreferrer",children:o.jsxs(Ie,{variant:"outline",children:[o.jsx(za,{className:"mr-2 h-4 w-4"}),"Visit ForexMQ5"]})})]})]})]}),o.jsx(jr,{})]})]})}function r4(){return o.jsxs(Nw,{children:[o.jsx(Lt,{path:"/",component:$0}),o.jsx(Lt,{path:"/blog",component:G0}),o.jsx(Lt,{path:"/blog/:slug",component:K0}),o.jsx(Lt,{path:"/privacy-policy",component:Y0}),o.jsx(Lt,{path:"/terms-of-service",component:J0}),o.jsx(Lt,{path:"/disclaimer",component:Z0}),o.jsx(Lt,{path:"/contact",component:e4}),o.jsx(Lt,{path:"/about",component:t4}),o.jsx(Lt,{component:Iv})]})}function a4(){return o.jsx(ox,{client:dx,children:o.jsxs(AT,{children:[o.jsx(Yk,{}),o.jsx(r4,{})]})})}Of(document.getElementById("root")).render(o.jsx(a4,{}));

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.