Entering content frame

Object documentation Web Dynpro RadioButton API - IWDRadioButton Locate the document in its SAP Library structure

Definition

The RadioButton UI element is a button with two states (on/off) that enables the user to select options. The RadioButton UI element allows you to spread the displayed radio buttons individually on the screen instead of grouping them in a table. You can toggle the radio button when you bind the UI elements to the same context attribute.

The radio button is selected if the context attribute to which the selectedKey property is bound, contains the value of the key that belongs to this radio button. The key is specified by the keyToSelectproperty.

Description of the UI Element Properties

·        keyToSelect
Specifies the value of the key used for the selection of this radio button.

·        selectedKey
Specifies the path to the context attribute that stores the currently selected key.

·        readOnly
Specifies whether or not the user can check the checkbox.

·        state
Describes the error status of the UI element. The data type of this property corresponds to the enumeration type WDState. You can use the following values in the application:

normal

Describes the default state of the UI element.

required

Specifies whether the entered value is required.

·        text
Describes the text next to the radio button.

Overview of Inherited and Additional Properties

Name

Interface

Type

Initial Value

Bindable

Value Required

enabled

IWDUIElement

boolean

true

bindable

No

keyToSelect

IWDRadioButton

String

 

bindable

Yes

selectedKey

IWDRadioButton

String

 

bindable_mandatory

Yes

readOnly

IWDRadioButton

boolean

false

bindable

No

state

IWDRadioButton

WDState

normal

bindable

No

text

IWDRadioButton

String (TranslatableText)

 

bindable

No

tooltip

IWDUIElement

String (TranslatableText)

 

bindable

No

visible

IWDUIElement

WDVisibility

visible

bindable

No

Events

·         onSelect
This property can assign the action that is executed when the user selects the RadioButton UI element.

Event Parameter

Type

key

String

See Structure linkParameter Mapping.

Mobile Characteristics

The UI element RadioButton supports the development of mobile applications for pocket PCs and BlackBerry wireless handhelds (see Mobile Web Dynpro).

However, several properties supported in the desktop browser cannot be used. These include:

Variances of the properties

Properties

Pocket PC

BlackBerry wireless handheld

enabled

ignored

ignored

readOnly

ignored

ignored

state

ignored

ignored

tooltip

ignored

ignored

Methods in the Web Dynpro IWDRadioButton API

Method Name

Parameter

Return Value

Short Description

bindingOfKeyToSelect

 

String

Returns the path of the context element to which the keyToSelect property is bound. Returns NULL if no binding exists.

bindingOfSelectedKey

 

String

Returns the path of the context element to which the selectedKey property is bound. Returns NULL if no binding exists.

bindingOfReadOnly

 

String

Returns the path of the context element to which the readOnly property is bound. Returns NULL if no binding exists.

bindingOfState

 

String

Returns the path of the context element to which the state property is bound. Returns NULL if no binding exists.

bindingOfText

 

String

Returns the path of the context element to which the text property is bound. Returns NULL if no binding exists.

bindKeyToSelect

(String path)

 

Binds the keyToSelect property to the context node specified by a path.

bindSelectedKey

(String path)

 

Binds the value of the selectedKey property to the context element specified by the path.

bindReadOnly

(String path)

 

Binds the readOnly property to the context node specified by a path.

bindState

(String path)

 

Binds the state property to the context node specified by a path.

bindText

(String path)

 

Binds the text property to the context node specified by a path.

getKeyToSelect

 

String

Returns the value of the keyToSelect property.

getOnSelect

 

IWDAction

Returns the action that is executed when the onSelect event is triggered.

getSelectedKey

 

String

Returns the value of the selectedKey property.

getReadOnly

 

String

Returns the value of the readOnly property.

getState

 

WDState

Returns the value of the state property.

getText

 

String

Returns the value of the text property.

mappingOfOnSelect

 

IWDParameterMapping

Returns the parameter mapping for the onSelect action.

setKeyToSelect

(String)

 

Sets the value of the keyToSelect property.

setOnSelect

(IWDAction action)

 

Sets the action that is executed when the onSelect event is triggered.

setSelectedKey

(String)

 

Sets the value of the selectedKey property.

setReadOnly

(boolean value)

 

Sets the value of the readOnly property.

setState

(WDState)

 

Sets the value of the state property.

setText

(String)

 

Sets the value of the text property.

Additional methods are available using inheritance: IWDUIElement, IWDViewElement.

Note

For detailed documentation of all inherited methods, see the documentation for the relevant APIs.

  

  

 

Leaving content frame