GpiQueryDefTag
Appearance
This function returns the default value of the tag identifier, as set by the GpiSetDefTag function.
Syntax
GpiQueryDefTag(hps, plTag)
Parameters
- hps (HPS) - input
- Presentation-space handle.
- plTag (PLONG) - output
- Default tag identifier.
Return Value
- rc (BOOL) - returns
- Success indicator.
- TRUE
- Successful completion
- FALSE
- Error occurred.
Errors
Possible returns from WinGetLastError:
- PMERR_INV_HPS (0x207F)
- An invalid presentation-space handle was specified.
- PMERR_PS_BUSY (0x20F4)
- An attempt was made to access the presentation space from more than one thread simultaneously.
- PMERR_INV_MICROPS_FUNCTION (0x20A1)
- An attempt was made to issue a function that is invalid in a micro presentation space.
Example Code
#define INCL_GPIDEFAULTS /* Or use INCL_GPI, INCL_PM, */ #include <os2.h> HPS hps; /* Presentation-space handle. */ PLONG plTag; /* Default tag identifier. */ BOOL rc; /* Success indicator. */ rc = GpiQueryDefTag(hps, plTag);
This example uses GpiQueryDefTag to return the default value of the tag identifier, as set by the GpiSetDefTag call.
#define INCL_GPIDEFAULTS /* Default functions */ #include <os2.h> BOOL fSuccess; /* success indicator */ HPS hps; /* Presentation-space handle */ LONG plTag; /* default tag identifier */ fSuccess = GpiQueryDefTag(hps, &plTag);