AddForcedVirtualLoadPath |
Previous Top Next |
Path
|
[in]
The filename or path for DLLs to load as virtual |
' This sample script will load any DLL located in the same
directory as the EXE as a virtual DLL |
|
' TS_ORIGIN is the path where the EXE is running from
|
Origin = GetEnvironmentVariable("TS_ORIGIN")
|
|
' We want to chop off the filename from TS_ORIGIN, so find the last
backslash and remove everything after this |
LastSlash = InStrRev(Origin, "\") |
SourcePath
= Left(Origin, LastSlash) |
|
' Tell Thinstall to load all DLLs in the same directory (or deeper)
from where the source EXE is |
' This
allows us to drop additional files in the SourcePath tree and have
them resolve imports against virtual DLLs |
AddForcedVirtualLoadPath(SourcePath)
|