Sets individual grid options.
Syntax
ESSG_FUNC_M EssGSetGridOption (hGrid, sOption, pOption);
Parameter | Data Type | Description |
---|---|---|
hGrid | ESSG_HGRID_T | Handle passed back from EssGNewGrid(). Description |
sOption | ESSG_SHORT_T | Value indicating what option is being set. For a table of valid values, see Notes. |
pOption | ESSG_PVOID_T | Value of option being set cast to an ESSG_PVOID_T. |
Notes
You can use the ESSG_OP_USERGRIDDATA pointer to store grid-specific information that is private to the application.
The following table lists valid options for sOption and the corresponding description and data type:
Value | Description | Data Type Expected | Default |
---|---|---|---|
ESSG_OP_ALIASNAMES | Alias names | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_ALIASTABLE | Alias names table | ESSG_STR_T | |
ESSG_OP_DATALESS | Enable dataless navigation. | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_DRILLLEVEL | Drill-level | ESSG_SHORT_T | ESSG_NEXTLEVEL |
ESSG_OP_EMPTYGRIDERROR | If FALSE, don't issue error on queries which result in no data and return only the grid header. | ESSG_BOOL_T | ESSG_TRUE |
ESSG_OP_INCSEL | Include selection | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_INDENT | Indent style | ESSG_SHORT_T | ESSG_INDENTTOTALS |
ESSG_OP_LATEST | Turn on the ability to specify the latest member. | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_LATESTMEMBER | Specify the latest member. | ESSG_STR_T | NULL |
ESSG_OP_REPEATMBRNAMES | Repeat member names. | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_RETAINTHREAD | If set to TRUE, don't disconnect from server thread at end of grid operation. May improve performance when submitting several operations in sequence. | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_SELGROUP | Remove Unselected Groups. Zooms on all occurrences of selected member but removes any other members from the same dimension, including the selected member itself. | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_SELONLY | Within Selected Group. Zooms on only the exact instance of the member that is selected. | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_SUPMISSING | Suppress missing rows. | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_SUPUNDER | Replace underscores with spaces. | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_SUPZEROS | Suppress zero rows. | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_UPDATEMODE | Update mode | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_USEBOTHFORROWDIMS | Use both member names and aliases for the row dimensions. | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_USERGRIDDATA | Pointer to user data | ESSG_PVOID_T | NULL |
ESSG_OP_RETAINTHREAD | Retain threads | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_EMPTYGRIDERROR | Issue an empty grid error | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_DATALESS | Navigate without data | ESSG_BOOL_T | ESSG_FALSE |
ESSG_OP_SPANHYBRIDANALYSIS | Span drill to relational source | ESSG_BOOL_T | ESSG_FALSE |
Return Value
If successful, returns ESSG_STS_NOERR.
Example
ESSG_VOID_T ESSG_SetGridOption (ESSG_HGRID_T hGrid) { ESSG_STS_T sts = ESS_STS_NOERR; ESSG_SHORT_T sOption; ESSG_SHORT_T tmpShort; ESSG_PVOID_T pOption; /* connect the grid to a database on the server */ sts = EssGConnect(hGrid, "Rainbow", "Admin", "Password", "Demo", "Basic", ESSG_CONNECT_DEFAULT); tmpShort = 2; sOption = ESSG_OP_DRILLLEVEL; pOption = (ESSG_PVOID_T)tmpShort; /* set grid option */ if(!sts) sts = EssGSetGridOption(hGrid, sOption, pOption); if(!sts) EssGDisconnect(hGrid, 0); }
See Also