HyperMath

Search Paths

Search Paths

Previous topic Next topic Expand/collapse all hidden text  

Search Paths

Previous topic Next topic JavaScript is required for expanding text JavaScript is required for the print function  

It is possible to specify search paths to look for files when no path is specified or to specify relative paths against.

hmtoggle_plus1greyAddPath

AddPath(pathname)

Adds a path to the search path.  The path is added at the end of any existing paths.  During the search, this order is used.  Returns true on success.

pathname   The string of the full path.  Use forward slash (/) or (\\) to separate folders.

b = AddPath("c:/demo");

hmtoggle_plus1greyClearPaths

ClearPaths()

Removes the entire search path.  Use RestoreDefaultPaths to restore the default paths.

hmtoggle_plus1greyGetPaths

t = GetPaths()

Returns the current search paths for include files.

t                 A table with the search paths as strings.

hmtoggle_plus1greyRemovePath

It is also possible to remove specific paths or all paths.

RemovePath(pathname)

Removes the path from the search path.

pathname     The string of the full path.

hmtoggle_plus1greyRestoreDefaultPaths

RestoreDefaultPaths()

Restores the default search paths.  It does not remove any existing paths.

hmtoggle_plus1greyShowPaths

It is possible to see the search paths.

ShowPaths()

Prints the search path in the order they were added.