GlobalEntryHandle

3.1

  #include <toolhelp.h>    

  BOOL GlobalEntryHandle(lpge, hglb)    
  GLOBALENTRY FAR* lpge; /* address of structure for object */
  HGLOBAL hglb; /* handle of item, */  

The GlobalEntryHandle function fills the specified structure with information that describes the given global memory object.

Parameters

lpge

Points to a GLOBALENTRY structure that receives information about the global memory object. The GLOBALENTRY structure has the following form:

#include <toolhelp.h>

typedef struct tagGLOBALENTRY {  /* ge */
    DWORD   dwSize;
    DWORD   dwAddress;
    DWORD   dwBlockSize;
    HGLOBAL hBlock;
    WORD    wcLock;
    WORD    wcPageLock;
    WORD    wFlags;
    BOOL    wHeapPresent;
    HGLOBAL hOwner;
    WORD    wType;
    WORD    wData;
    DWORD   dwNext;
    DWORD   dwNextAlt;
} GLOBALENTRY;

For a full description of this structure, see the Microsoft Windows Programmer's Reference, Volume 3.

hglb

Identifies the global memory object to be described.

Return Value

The return value is nonzero if the function is successful. Otherwise, it is zero. The function fails if the hglb value is an invalid handle or selector.

Comments

This function retrieves information about a global memory handle or selector. Debuggers use this function to obtain the segment number of a segment loaded from an executable file.

Before calling the GlobalEntryHandle function, an application must initialize the GLOBALENTRY structure and specify its size, in bytes, in the dwSize member.

See Also

GlobalEntryModule, GlobalFirst, GlobalInfo, GlobalNext