ModuleFileName

(Engine-Level Function)

Description: Returns the full path (including the drive letter) and file name of the document (.SRC) file of a module.
Returns: Text
Usage: Script or steady state.
Function Groups: Compilation and On-Line Modifications,  File I/O,  Advanced Module
Related to:
Format: ModuleFileName(Module)
Parameters:  
Module
Required. Any expression for the module to enquire about.

This function is session non-aware, meaning it works on the server's file system even with an active remote connection established. This function is also blocking, all concurrent thread operations will be paused until its execution has concluded.

Example:

If 1 Next;
[
  PageFiles = ChildDocs(Scope(\Code, PageName), 10);
  I = 0; 
  WhileLoop(I < ArraySize(PageFiles, 0),
            PageFiles[I] = ModuleFileName(PageFiles[I]); 
            I++; 
  ); 
]