Debugging Tools for Windows |
The GetModuleByModuleName2 and GetModuleByModuleName2Wide methods search through the process's modules for one with the specified name.
HRESULT
IDebugSymbols3::GetModuleByModuleName2(
IN PCSTR Name,
IN ULONG StartIndex,
IN ULONG Flags,
OUT OPTIONAL PULONG Index,
OUT OPTIONAL PULONG64 Base
);
HRESULT
IDebugSymbols3::GetModuleByModuleName2Wide(
IN PCWSTR Name,
IN ULONG StartIndex,
IN ULONG Flags,
OUT OPTIONAL PULONG Index,
OUT OPTIONAL PULONG64 Base
);
#ifdef UNICODE
#define GetModuleByModuleName2T GetModuleByModuleName2Wide
#else
#define GetModuleByModuleName2T GetModuleByModuleName2
#endif
Flag | Effect |
---|---|
DEBUG_GETMOD_NO_LOADED_MODULES | Do not search the loaded modules. |
DEBUG_GETMOD_NO_UNLOADED_MODULES | Do not search the unloaded modules. |
This method may also return other error values. See Return Values for more details.
GetModuleByModuleName2 and GetModuleByModuleName2Wide are available in IDebugSymbols3 and later versions.
Starting at the specified index, these methods return the first module they find with the specified name. If the target has more than one module with this name, then subsequent modules can be found by repeated calls to these methods with higher values of StartIndex.
For more information about modules, see Modules.
Headers: Defined in Dbgeng.h. Include Dbgeng.h.