Files
mql5-skills/skills/mql5/references/docs/00-basis/0070-basis-preprosessor-include.md
T
2026-06-23 21:47:51 +08:00

26 lines
918 B
Markdown
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Including Files (#include)
The #include command line can be placed anywhere in the program, but usually all inclusions are placed at the beginning of the source code. Call format:
```
#include <file_name>
#include "file_name"
```
Examples:
```
#include <WinUser32.mqh>
#include "mylib.mqh"
```
The preprocessor replaces the line #include <file_name> with the content of the file WinUser32.mqh. Angle brackets indicate that the WinUser32.mqh file will be taken from the standard directory (usually it is terminal_installation_directory\MQL5\Include). The current directory is not included in the search.
If the file name is enclosed in quotation marks, the search is made in the current directory (which contains the main source file). The standard directory is not included in the search.
See also
[Standard Library](/en/docs/standardlibrary), [Importing Functions](/en/docs/basis/preprosessor/import)