on 06-05-2008 9:17 AM
Hi Experts,
Can any one please tel me how to validate radiobutton groupbyindex...
and what is the cardinality for that.........
Thanks in advance
Hi
Create a node of cardinality 0..n
create an attribute of type string under the node
fill the node in wddoinit ( rbtngrp1 is the node name and texts is the attribute name under the node )
data:
lt_attributes type standard table of if_radiobtngrpbyidx=>element_rbtngrp1,
wa_attributes like line of lt_attributes.
wa_attributes-texts = 'Radiobutton 1'.
insert wa_attributes into table lt_attributes.
wa_attributes-texts = 'Radiobutton 2'.
insert wa_attributes into table lt_attributes.
wa_attributes-texts = 'Radiobutton 3'.
insert wa_attributes into table lt_attributes.
Abhi
node->bind_elements( lt_attributes ).
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
Please go through the component WDR_TEST_EVENTS
You can get to know the UI elements are being used.
If you are getting the error null object reference, then it must be something wrong with your code.
you have to fill your context in WDDOINIT() method - refer my previous post
I Assume Validating means:
Knowing which radiobutton is selected at runtime, it is the lead selection.
Abhi
Hi
You are able to view the radio buttons.
use this code to check whether any radiobutton is clicked
data: lr_rb type ref to if_wd_context_node.
data: lt_table type WDR_CONTEXT_ELEMENT_SET.
data: lr_element type ref to if_wd_context_element.
data: isselected type c.
lr_rb = wd_context->get_child_node( '<node_name>' ).
lt_table = lr_rb->get_elements( ).
loop at lt_table into lr_element.
if lr_element->isselected( ).
isselected = 'X'.
endif.
endloop.
if isselected is initial.
< none is selected >
endif.
Abhi
User | Count |
---|---|
86 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.