Default resource file search path
Search rules for program resource files have been enhanced in 3.10.
Default search in application directory
Starting with version 3.10, if resource files such as .42f form files are
not found in the current working directory, or in the directories specified in the FGLRESOURCEPATH
environment variable, or in FGLDIR/lib, the runtime system also does a lookup
in the directory where the MAIN
.42m module or the .42r program file resides.
As a result, if all program files are in the directory where the main program module resides, there is no need to set FGLRESOURCEPATH.
For more details about resource file directory search, see FGLRESOURCEPATH.
Form file path using absolute path
If the file name specified in OPEN FORM
/ OPEN WINDOW WITH FORM
is an absolute path, the runtime system must not search for the form in FGLRESOURCEPATH.
Before version 3.10, to load a form file specified with an absolute path in OPEN
FORM
or OPEN WINDOW WITH FORM
, the runtime system tried to find the file
by appending the absolute path to the directories defined by FGLRESOURCEPATH.
This could end up in loading unexpected resource files.
For example, with:
OPEN FORM f FROM "/dir/form"
The form "/dir/form" was searched in each element of FGLRESOURCEPATH.
Since version 3.10, FGLRESOURCEPATH is only used, if the file name is not an absolute path.
For more details, see The WITH FORM clause.