Loading…

Catalogue Registry Panel

Running several indicators and EAs on one chart or across a terminal leaves no built-in way to see, at a glance, what is actually running and whether each one thinks it is healthy. MQL4 has no API for one program to enumerate or inspect another running program directly - that introspection channel genuinely does not exist on this platform. What MQL4 does have is terminal-wide global variables (GlobalVariableSet / GlobalVariableGet), the one piece of state every MQL4 program can read and write regardless of which chart it is attached to. This panel defines a small convention over that mechanism and displays whatever currently matches it: CBREG_<ToolName>_VER double, e.g. 1.00 CBREG_<ToolName>_HEALTH double, 0 = OK, 1 = WARN, 2 = ERROR CBREG_<ToolName>_TS double, TimeCurrent() of the last update Any tool - present or future - that calls GlobalVariableSet with those three names (substituting its own short name for <ToolName>) on a periodic timer becomes visible here automatically, with its version, health code, and staleness (time since its last TS update) shown in one row. A tool that stops reporting (its TS goes stale past InpStaleSeconds) is shown greyed out rather than silently vanishing from the list, so a crashed or removed tool's absence is itself visible information. This panel is a registry VIEWER. It cannot discover a tool that never adopts the convention - that limitation is a direct consequence of MQL4 having no cross-program introspection API at all, not a gap in this panel's implementation. Notes and limitations - Only tools that actively publish the CBREG_ convention appear here. This panel cannot discover, list, or assess any indicator or EA that does not call GlobalVariableSet with these exact names - nothing in the current catalogue does this automatically yet, so this panel is most useful once other tools are updated to adopt the convention, or for your own custom tools built to publish it. - Terminal global variables are shared across the WHOLE terminal, not per-chart or per-symbol - a tool running on one chart is visible in this panel from any other chart too, which is intended (that is the entire point of using this mechanism) but means the panel cannot tell you which chart a listed tool is actually attached to. - Terminal global variables persist for the terminal's configured expiry (commonly around four weeks of inactivity) and survive terminal restarts if saved - a tool that was removed but whose variables have not yet expired can still show up as "stale" rather than fully gone. - The registry list is capped at 40 distinct tool names to keep memory and panel height bounded; a terminal publishing more than that under the convention will not show every one. - Health codes beyond 0/1/2 are displayed as "UNKNOWN(n)" rather than guessed at - the convention only defines those three values.

Indicator · MT5 · v1.0 · Free

About Catalogue Registry Panel

Catalogue Registry Panel is an indicator for MetaTrader 5. It has 12 settings, such as Rescan seconds, Stale seconds and Corner. MQL source code included.

Files in the download: CatalogueRegistryPanel.ex5, CatalogueRegistryPanel.mq5, CatalogueRegistryPanel.txt.

Settings

SettingDefaultWhat it does
Rescan seconds5How often to rescan global variables, seconds
Stale seconds120A tool not updated within this many seconds is shown STALE
CornerCORNER_RIGHT_UPPERPanel corner
X offset10Horizontal offset from the corner, pixels
Y offset20Vertical offset from the corner, pixels
Font size9Font size
Header colorclrWhiteHeader row colour
Ok colorclrLimeGreenRow colour when health is OK
Warn colorclrOrangeRow colour when health is WARN
Error colorclrRedRow colour when health is ERROR
Stale colorclrGrayRow colour when the tool's TS is stale
Show backgroundtrueDraw a solid backing rectangle behind the panel

How to install

  1. Download the ZIP from your PolyMaria library and unzip it.
  2. In MetaTrader 5 open File → Open Data Folder, then go to MQL5 → Indicators.
  3. Copy the .mq5 file(s) there. Put any .mqh files in MQL5 → Include.
  4. Open the .mq5 file in MetaEditor and press Compile (F7) if MetaTrader does not show it.
  5. Drag the indicator from the Navigator onto a chart and adjust the settings.

Download the PDF guide

Tags: Channels & Envelopes · MT5 Indicator · MQL5 Source Code

MetaTrader 4 & 5 indicators · PolyMaria