| SignDocFieldsetValueIndex Method |
Set the value index.
Radio button groups and check box fields can have multiple widgets having the same button value.For check box fields and radio buttons without f_RadiosInUnison set, specifying the selected button by value string is ambiguous in that case.A 0 - based value index can be used to find out which button is selected or to select a button.
Radio button groups and check box fields need not use a value index; in fact, they usually don't. However, you can always set a value index for radio button groups and check box fields.
If the value index is non - negative, SignDocDocument.addField() and SignDocDocument.setField() will use the value index instead of the string value set by setValue().
Calling setValueIndex() doesn't affect the return value of getValue() as the value index is used by SignDocDocument.addField() and SignDocDocument.setField() only. However, successful calls to SignDocDocument.addField() and SignDocDocument.setField() will make getValue() return the selected value.
For radio button groups with f_RadiosInUnison set and non - unique button values and for check box fields with non - unique button values, for each button value, the lowest index having that button value is the canonical one.After calling SignDocDocument.addField() or SignDocDocument.setField(), getValueIndex() will return the canonical value index.
Don't forget to update the value index when adding or removing widgets!
SignDocDocument.addField() and SignDocDocument.setField() will fail if the value index is non - negative for fields other than radio button groups and check box fields.
The "Off" value never has a value index.
Namespace:
de.softpro.signdocsdk
Assembly:
SPSignDoc_4.3_DotNetLib (in SPSignDoc_4.3_DotNetLib.dll) Version: 1.0.6773.37566
Syntaxpublic void setValueIndex(
int index
)
Parameters
- index
- Type: SystemInt32
the 0-based value index or -1 to make the value index unset.
Remarks
addValue(), clearValues(), and setValue() make the value index unset (ie, getValueIndex() will return -1). Therefore, you don't have to call setValueIndex(-1) to make setValue() take effect on SignDocDocument.addField() and SignDocDocument.setField().
See Also