LoadLibraryFlags Enumeration
Namespace: DevCase.Win32.EnumsAssembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[FlagsAttribute]
public enum LoadLibraryFlags
<FlagsAttribute>
Public Enumeration LoadLibraryFlags
Dim instance As LoadLibraryFlags
[FlagsAttribute]
public enum class LoadLibraryFlags
[<FlagsAttribute>]
type LoadLibraryFlags
No code example is currently available or this language may not be supported.
None |
0 |
Define no flags.
|
DontResolveDllReferences |
1 |
If this value is used, and the executable module is a DLL,
the system does not call DllMain for process and thread initialization and termination.
Also, the system does not load additional executable modules that are referenced by the specified module.
Do not use this value; it is provided only for backward compatibility.
If you are planning to access only data or resources in the DLL,
use LoadLibraryAsDataFileExclusive
or LoadLibraryAsImageResource or both.
Otherwise, load the library as a DLL or executable module using the LoadLibrary(String) function.
|
LoadLibraryAsDataFile |
2 |
If this value is used, the system maps the file into the calling process's virtual address space as if it were a data file.
Nothing is done to execute or prepare to execute the mapped file.
Therefore, you cannot call functions like GetModuleFileName, GetModuleHandle
or GetProcAddress(SafeModuleHandle, String) with this DLL.
Using this value causes writes to read-only memory to raise an access violation.
Use this flag when you want to load a DLL only to extract messages or resources from it.
This value can be used with LoadLibraryAsImageResource.
|
LoadWithAlteredSearchPath |
8 |
If this value is used and lpFileName specifies an absolute path,
the system uses the alternate file search strategy to find associated executable modules that the specified module causes to
be loaded.
If this value is used and lpFileName specifies a relative path, the behavior is undefined.
|
IgnoreCodeAuthzLevel |
16 |
If this value is used, the system does not check AppLocker rules or apply Software Restriction Policies for the DLL.
This action applies only to the DLL being loaded and not to its dependencies.
This value is recommended for use in setup programs that must run extracted DLLs during installation.
|
LoadLibraryAsImageResource |
32 |
If this value is used, the system maps the file into the process's virtual address space as an image file.
However, the loader does not load the static imports or perform the other usual initialization steps.
Use this flag when you want to load a DLL only to extract messages or resources from it.
Unless the application depends on the file having the in-memory layout of an image,
this value should be used with either LoadLibraryAsDataFile
or LoadLibraryAsDataFileExclusive.
|
LoadLibraryAsDataFileExclusive |
64 |
Similar to LoadLibraryAsDataFile,
except that the DLL file is opened with exclusive write access for the calling process.
Other processes cannot open the DLL file for write access while it is in use.
However, the DLL can still be opened by other processes.
This value can be used with LoadLibraryAsImageResource.
|
LoadLibrarySearchDllLoadDir |
256 |
If this value is used, the directory that contains the DLL is temporarily added to the beginning of the list of
directories that are searched for the DLL's dependencies.
Directories in the standard search path are not searched.
The fileName parameter of LoadLibraryEx(String, IntPtr, LoadLibraryFlags) function must specify a fully qualified path.
This value cannot be combined with LoadWithAlteredSearchPath.
|
LoadLibrarySearchApplicationDir |
512 |
If this value is used, the application's installation directory is searched for the DLL and its dependencies.
Directories in the standard search path are not searched.
This value cannot be combined with LoadWithAlteredSearchPath.
|
LoadLibrarySearchUserDirs |
1,024 |
If this value is used, directories added using the AddDllDirectory or the SetDllDirectory(String) function are searched for the
DLL and its dependencies.
If more than one directory has been added, the order in which the directories are searched is unspecified.
Directories in the standard search path are not searched.
This value cannot be combined with LoadWithAlteredSearchPath.
|
LoadLibrarySearchSystem32 |
2,048 |
If this value is used, %windows%\system32 is searched for the DLL and its dependencies.
Directories in the standard search path are not searched.
This value cannot be combined with LoadWithAlteredSearchPath.
|
LoadLibrarySearchDefaultDirs |
4,096 |
This value is a combination of LoadLibrarySearchApplicationDir,
LoadLibrarySearchSystem32, and LoadLibrarySearchUserDirs.
Directories in the standard search path are not searched.
This value cannot be combined with LoadWithAlteredSearchPath.
This value represents the recommended maximum number of directories an application should include in its DLL search path.
|