The SymGetSymFromAddr function locates the symbol for the specified address.
BOOL SymGetSymFromAddr(
IN HANDLE hProcess,
IN DWORD Address,
OUT LPDWORD Displacement,
IN OUT PIMAGEHLP_SYMBOL Symbol
);
If the function succeeds, the return value is TRUE.
If the function fails, the return value is FALSE. To retrieve extended error information, call GetLastError.
The SymGetSymFromAddr function locates the symbol for a specified address. The modules are searched for the one the address belongs to. When the module is found, its symbol table is searched for a match. When the symbol is found, the symbol information is copied into the Symbol buffer provided by the caller. The caller must allocate the Symbol buffer properly and fill in the required parameters in the IMAGEHLP_SYMBOL structure before calling SymGetSymFromAddr.
Windows NT: Requires version 4.0 or later.
Windows: Requires Windows 95 or later. Available as a redistributable for Windows 95.
Windows CE: Unsupported.
Header: Declared in imagehlp.h.
Import Library: Use imagehlp.lib.
PE Image Helper (ImageHlp) Overview, Symbol Handler, IMAGEHLP_SYMBOL, SymInitialize