Functions
OptionButton Item

Functions

StatusInt mdlDialog_optionButtonSetEnabled (RawItemHdr *oButP, int subItemIndex, bool enabled)
 Sets the enabled state (enabled or disabled) of a sub-item of the Option Button item specified by oButP to the value specified by enabled. More...
 
StatusInt mdlDialog_optionButtonGetItemInfo (WChar *labelP, RscType *iconTypeP, RscId *iconIdP, int *commandSourceP, UInt32 *valueP, UInt32 *maskP, bool *enabledP, void **userDataPP, RawItemHdr *oButP, int subItemIndex)
 Gets information about an Option Button sub-item. More...
 
StatusInt mdlDialog_optionButtonSetItemInfo (WCharCP labelP, RscType *iconTypeP, RscId *iconIdP, int *commandSourceP, UInt32 *valueP, UInt32 *maskP, bool *enabledP, void **userDataPP, RawItemHdr *oButP, int subItemIndex)
 Sets information in an Option Button sub-item. More...
 
StatusInt mdlDialog_optionButtonGetSubInfo (WChar *labelP, RscType *iconTypeP, RscId *iconIdP, CommandNumber *commandNumberP, int *commandSourceP, UInt32 *valueP, UInt32 *maskP, bool *enabledP, void **userDataPP, RawItemHdr *oButP, int subItemIndex)
 Gets information about an Option Button sub-item. More...
 
StatusInt mdlDialog_optionButtonSetSubInfo (WCharCP labelP, RscType *iconTypeP, RscId *iconIdP, CommandNumber *commandNumberP, int *commandSourceP, UInt32 *valueP, UInt32 *maskP, bool *enabledP, void **userDataPP, RawItemHdr *oButP, int subItemIndex)
 Sets information in an Option Button sub-item. More...
 
int mdlDialog_optionButtonGetNItems (RawItemHdr *oButP)
 Returns the number of sub-items contained in the Option Button item specified by oButP. More...
 
StatusInt mdlDialog_optionButtonInsertItem (WCharCP labelP, RscType *iconTypeP, RscId *iconIdP, int *commandSourceP, UInt32 *valueP, UInt32 *maskP, bool *enabledP, void *userDataP, RawItemHdr *oButP, int subItemIndex)
 Inserts an Option Button sub-item into the Option Button item specified by oButP. More...
 
StatusInt mdlDialog_optionButtonInsSubItem (WCharCP labelP, RscType *iconTypeP, RscId *iconIdP, CommandNumber *commandNumberP, int *commandSourceP, UInt32 *valueP, UInt32 *maskP, bool *enabledP, void *userDataP, RawItemHdr *oButP, int subItemIndex)
 Inserts an Option Button sub-item into the Option Button item specified by oButP. More...
 
StatusInt mdlDialog_optionButtonDeleteItem (RawItemHdr *oButP, int subItemIndex)
 Deletes an Option Button sub- item from the Option Button specified by oButP. More...
 
void mdlDialog_optionButtonDeleteAll (RawItemHdr *oButP)
 Deletes all the sub-items from the Option Button specified by oButP. More...
 
StatusInt mdlDialog_optionButtonGetItemLabel (WStringR labelString, RawItemHdr *oButP, int subItemIndex)
 Gets the label for an OptionButton item. More...
 
StatusInt mdlDialog_optionButtonSetItemLabel (WCharCP pLabelText, RawItemHdr *oButP, int subItemIndex)
 Sets the label for an OptionButton item. More...
 

Detailed Description

Function Documentation

void mdlDialog_optionButtonDeleteAll ( RawItemHdr oButP)

Deletes all the sub-items from the Option Button specified by oButP.

Parameters
[in]oButPOption Button
See also
mdlDialog_optionButtonGetNItems mdlDialog_optionButtonDeleteItem
StatusInt mdlDialog_optionButtonDeleteItem ( RawItemHdr oButP,
int  subItemIndex 
)

Deletes an Option Button sub- item from the Option Button specified by oButP.

Parameters
[in]oButPOption Button
[in]subItemIndexThe subItemIndex parameter specifies the sub-item to delete. It must be greater than or equal to zero and less than the number of sub-items in the Option Button. The mdlDialog_optionButtonGetNItems function can be used to get the number of sub-items contained by an Option Button item.
Returns
SUCCESS on success or non-zero value if an error occurs. This means that oButP does not point to an Option Button item, or subItemIndex is not in range.
See also
uamthmdlDialog_optionButtonGetNItemsC mdlDialog_optionButtonDeleteAll
StatusInt mdlDialog_optionButtonGetItemInfo ( WChar *  labelP,
RscType iconTypeP,
RscId iconIdP,
int *  commandSourceP,
UInt32 valueP,
UInt32 maskP,
bool *  enabledP,
void **  userDataPP,
RawItemHdr oButP,
int  subItemIndex 
)

Gets information about an Option Button sub-item.

Thise function is obsolete; you should use mdlDialog_optionButtonGetSubInfo instead.

Parameters
[out]labelPset NULL if don't want label
[out]iconTypePset NULL if don't want type
[out]iconIdPset NULL if don't want id
[out]commandSourcePset NULL if don't want cmd source
[out]valuePset NULL if don't want value
[out]maskPset NULL if don't want mask
[out]enabledPset NULL if don't want enabled state
[out]userDataPPUser defined data can be attached to any Option Button sub-item. The userDataPP parameter is used to attach or retrieve a pointer to the user defined data area.
[in]oButPThe oButP parameter specifies a particular Option Button item.
[in]subItemIndexThe subItemIndex parameter indicates which sub-item to get information about or set information in. It must be greater than or equal to zero, and less than the number of sub-items in the Option Button. The mdlDialog_optionButtonGetNItems function can be used to get the number of sub-items contained by an Option Button item.
Remarks
The parameters other than oButP, subItemIndex, and userDataPP are analogous to those found in the DItem_OptionButtonItemRsc structure. See the "Option Button Item" section of the "Standard Dialog Items" chapter for more information on the DItem_OptionButtonItemRsc structure.
When using mdlDialog_optionButtonGetItemInfo the caller can specify NULL for any parameter (other than oButP and subItemIndex), which indicates that the corresponding value is not required.
Returns
SUCCESS on success or non-zero value if an error occurs. This means that oButP does not point to an Option Button item.
See also
mdlDialog_optionButtonGetNItems mdlDialog_optionButtonGetSubInfo mdlDialog_optionButtonSetSubInfo mdlDialog_optionButtonSetItemInfo
StatusInt mdlDialog_optionButtonGetItemLabel ( WStringR  labelString,
RawItemHdr oButP,
int  subItemIndex 
)

Gets the label for an OptionButton item.

The label is in Unicode format.

Parameters
[out]labelStringreference to a WString that receives the item label
[in]oButPThe oButP parameter specifies a particular Option Button item.
[in]subItemIndexThe subItemIndex parameter indicates which sub-item to get label for.
Returns
SUCCESS on success or non-zero value if an error occurs. This means that oButP does not point to an Option Button item.
See also
mdlDialog_optionButtonGetNItems mdlDialog_optionButtonSetItemLabel
int mdlDialog_optionButtonGetNItems ( RawItemHdr oButP)

Returns the number of sub-items contained in the Option Button item specified by oButP.

Parameters
[in]oButPOption Button
Returns
The number of sub-items in the specified Option Button item. It returns -1 if oButP does not point to an Option Button item.
See also
mdlDialog_optionButtonSetEnabled
StatusInt mdlDialog_optionButtonGetSubInfo ( WChar *  labelP,
RscType iconTypeP,
RscId iconIdP,
CommandNumber *  commandNumberP,
int *  commandSourceP,
UInt32 valueP,
UInt32 maskP,
bool *  enabledP,
void **  userDataPP,
RawItemHdr oButP,
int  subItemIndex 
)

Gets information about an Option Button sub-item.

Parameters
[out]labelPset NULL if don't want label
[out]iconTypePset NULL if don't want type
[out]iconIdPset NULL if don't want id
[out]commandNumberPset NULL if don't want cmd number
[out]commandSourcePset NULL if don't want cmd source
[out]valuePset NULL if don't want value
[out]maskPset NULL if don't want mask
[out]enabledPset NULL if don't want enabled state
[in]oButPThe oButP parameter specifies a particular Option Button item.
[in]subItemIndexThe subItemIndex parameter indicates which sub-item to get information about or set information in. It must be greater than or equal to zero, and less than the number of sub-items in the Option Button. The mdlDialog_optionButtonGetNItems function can be used to get the number of sub-items contained by an Option Button item.
[out]userDataPPdefined data can be attached to any Option Button sub-item. The userDataPP parameter is used to attach or retrieve a pointer to the user defined data area.
Remarks
The parameters other than oButP, subItemIndex, and userDataPP are analogous to those found in the DItem_OptionButtonItemRsc structure. See the "Option Button Item" section of the "Standard Dialog Items" chapter for more information on the DItem_OptionButtonItemRsc structure.
When using mdlDialog_optionButtonGetSubInfo the caller can specify NULL for any parameter (other than oButP and subItemIndex), which indicates that the corresponding value is not required.
These functions replace mdlDialog_optionButtonGetItemInfo and mdlDialog_optionButtonSetItemInfo. The functionality is identical except for the addition of the commandNumberP field and better error- checking.
Returns
SUCCESS on success or non-zero value if an error occurs. This means that oButP does not point to an Option Button item.
See also
mdlDialog_optionButtonGetNItems mdlDialog_optionButtonSetSubInfo
StatusInt mdlDialog_optionButtonInsertItem ( WCharCP  labelP,
RscType iconTypeP,
RscId iconIdP,
int *  commandSourceP,
UInt32 valueP,
UInt32 maskP,
bool *  enabledP,
void *  userDataP,
RawItemHdr oButP,
int  subItemIndex 
)

Inserts an Option Button sub-item into the Option Button item specified by oButP.

mdlDialog_optionButtonInsSubItem differs from the earlier mdlDialog_optionButtonInsertItem only in that it also allows the command number to be set.

Parameters
[in]labelPset NULL if not not setting label
[in]iconTypePset NULL if not not setting type
[in]iconIdPset NULL if not not setting ID
[in]commandSourcePset NULL if not not setting cmd source
[in]valuePset NULL if not not setting value
[in]maskPset NULL if not not setting mask
[in]enabledPset NULL if not not setting enabled state
[in]oButPThe oButP parameter specifies a particular Option Button item.
[in]subItemIndexThe subItemIndex parameter indicates which sub-item to get information about or set information in. It must be greater than or equal to zero, and less than the number of sub-items in the Option Button. The mdlDialog_optionButtonGetNItems function can be used to get the number of sub-items contained by an Option Button item.
[in]userDataPUser defined data can be attached to any Option Button sub-item. The userDataPP parameter is used to attach or retrieve a pointer to the user defined data area.
Returns
SUCCESS or a non-zero value to indicate an error.
See also
mdlDialog_optionButtonGetNItems
StatusInt mdlDialog_optionButtonInsSubItem ( WCharCP  labelP,
RscType iconTypeP,
RscId iconIdP,
CommandNumber *  commandNumberP,
int *  commandSourceP,
UInt32 valueP,
UInt32 maskP,
bool *  enabledP,
void *  userDataP,
RawItemHdr oButP,
int  subItemIndex 
)

Inserts an Option Button sub-item into the Option Button item specified by oButP.

mdlDialog_optionButtonInsSubItem differs from the earlier mdlDialog_optionButtonInsertItem only in that it also allows the command number to be set.

Parameters
[in]labelPset NULL if not not setting label
[in]iconTypePset NULL if not not setting type
[in]iconIdPset NULL if not not setting ID
[in]commandNumberPset NULL if not not setting cmd number
[in]commandSourcePset NULL if not not setting cmd source
[in]valuePset NULL if not not setting value
[in]maskPset NULL if not not setting mask
[in]enabledPset NULL if not not setting enabled state
[in]oButPThe oButP parameter specifies a particular Option Button item.
[in]subItemIndexThe subItemIndex parameter indicates which sub-item to get information about or set information in. It must be greater than or equal to zero, and less than the number of sub-items in the Option Button. The mdlDialog_optionButtonGetNItems function can be used to get the number of sub-items contained by an Option Button item.
[in]userDataPUser defined data can be attached to any Option Button sub-item. The userDataPP parameter is used to attach or retrieve a pointer to the user defined data area.
Returns
SUCCESS or a non-zero value to indicate an error.
See also
mdlDialog_optionButtonGetNItems
StatusInt mdlDialog_optionButtonSetEnabled ( RawItemHdr oButP,
int  subItemIndex,
bool  enabled 
)

Sets the enabled state (enabled or disabled) of a sub-item of the Option Button item specified by oButP to the value specified by enabled.

Parameters
[in]oButPOption Button to set; true if error
[in]subItemIndexindicates which sub-item's enabled state to set. It must be greater than or equal to zero and less than the number of sub-items in the Option Button. The mdlDialog_optionButtonGetNItems function can be used to get the number of sub-items contained by an Option Button item.
[in]enabledIf enabled is true, the Option Button sub-item is drawn with normal bold text (if the Option Button is not using icons) and the user can select the sub-item. If enabled is false, the Option Button sub-item is drawn with dimmed text and the user cannot select the sub-item.
Returns
SUCCESS on success or non-zero value if an error occurs. This means that oButP does not point to an Option Button item.
See also
mdlDialog_optionButtonGetNItems
StatusInt mdlDialog_optionButtonSetItemInfo ( WCharCP  labelP,
RscType iconTypeP,
RscId iconIdP,
int *  commandSourceP,
UInt32 valueP,
UInt32 maskP,
bool *  enabledP,
void **  userDataPP,
RawItemHdr oButP,
int  subItemIndex 
)

Sets information in an Option Button sub-item.

This function is obsolete; you should usually use mdlDialog_optionButtonSetSubInfo instead.

Parameters
[in]labelPset NULL if not setting label
[in]iconTypePset NULL if not setting type
[in]iconIdPset NULL if not setting id
[in]commandSourcePset NULL if not setting cmd source
[in]valuePset NULL if not setting value
[in]maskPset NULL if not setting mask
[in]enabledPset NULL if not setting enabled state
[in]userDataPPUser defined data can be attached to any Option Button sub-item. The userDataPP parameter is used to attach or retrieve a pointer to the user defined data area.
[in]oButPThe oButP parameter specifies a particular Option Button item.
[in]subItemIndexThe subItemIndex parameter indicates which sub-item to get information about or set information in. It must be greater than or equal to zero, and less than the number of sub-items in the Option Button. The mdlDialog_optionButtonGetNItems function can be used to get the number of sub-items contained by an Option Button item.
Remarks
The parameters other than oButP, subItemIndex, and userDataPP are analogous to those found in the DItem_OptionButtonItemRsc structure. See the "Option Button Item" section of the "Standard Dialog Items" chapter for more information on the DItem_OptionButtonItemRsc structure.
When using mdlDialog_optionButtonSetItemInfo the caller can specify NULL for any parameter (other than oButP and subItemIndex), which indicates that the corresponding value is not being set and should remain unchanged.
Returns
SUCCESS on success or non-zero value if an error occurs. This means that oButP does not point to an Option Button item.
See also
mdlDialog_optionButtonGetNItems mdlDialog_optionButtonGetSubInfo mdlDialog_optionButtonSetSubInfo mdlDialog_optionButtonGetItemInfo
StatusInt mdlDialog_optionButtonSetItemLabel ( WCharCP  pLabelText,
RawItemHdr oButP,
int  subItemIndex 
)

Sets the label for an OptionButton item.

The new label may be in MultiByte or Unicode format.

Parameters
[in]pLabelTextpointer to the text representing the new label
[in]oButPThe oButP parameter specifies a particular Option Button item.
[in]subItemIndexThe subItemIndex parameter indicates which sub-item to set label in.
Returns
SUCCESS on success or non-zero value if an error occurs. This means that oButP does not point to an Option Button item.
See also
mdlDialog_optionButtonGetNItems mdlDialog_optionButtonGetItemLabel
StatusInt mdlDialog_optionButtonSetSubInfo ( WCharCP  labelP,
RscType iconTypeP,
RscId iconIdP,
CommandNumber *  commandNumberP,
int *  commandSourceP,
UInt32 valueP,
UInt32 maskP,
bool *  enabledP,
void **  userDataPP,
RawItemHdr oButP,
int  subItemIndex 
)

Sets information in an Option Button sub-item.

Parameters
[in]labelPset NULL if not not setting label
[in]iconTypePset NULL if not not setting type
[in]iconIdPset NULL if not not setting ID
[in]commandNumberPset NULL if not not setting cmd number
[in]commandSourcePset NULL if not not setting cmd source
[in]valuePset NULL if not not setting value
[in]maskPset NULL if not not setting mask
[in]enabledPset NULL if not not setting enabled state
[in]oButPThe oButP parameter specifies a particular Option Button item.
[in]subItemIndexThe subItemIndex parameter indicates which sub-item to get information about or set information in. It must be greater than or equal to zero, and less than the number of sub-items in the Option Button. The mdlDialog_optionButtonGetNItems function can be used to get the number of sub-items contained by an Option Button item.
[in]userDataPPUser defined data can be attached to any Option Button sub-item. The userDataPP parameter is used to attach or retrieve a pointer to the user defined data area.
Remarks
The parameters other than oButP, subItemIndex, and userDataPP are analogous to those found in the DItem_OptionButtonItemRsc structure. See the "Option Button Item" section of the "Standard Dialog Items" chapter for more information on the DItem_OptionButtonItemRsc structure.
When using mdlDialog_optionButtonSetSubInfo the caller can specify NULL for any parameter (other than oButP and subItemIndex), which indicates that the corresponding value is not being set and should remain unchanged.
These functions replace mdlDialog_optionButtonGetItemInfo and mdlDialog_optionButtonSetItemInfo. The functionality is identical except for the addition of the commandNumberP field and better error- checking.
Returns
SUCCESS on success or non-zero value if an error occurs. This means that oButP does not point to an Option Button item.
See also
mdlDialog_optionButtonGetNItems mdlDialog_optionButtonGetSubInfo

Copyright © 2017 Bentley Systems, Incorporated. All rights reserved.