on 08-05-2009 1:36 PM
hi all,
I have captured the values entered in select options in field symbols.
Can anyone tell me how to validate those values?
Hi,
After you get the values, have you bound them to context node attribtues that you are using for select-options.
If you have any button, in that handler you can validate them by getting the context node/select-options field values and use the message manager to throw the error.
Regards,
Lekha.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I assume your problem is that the field symbol is generically typed?
You call this to get the values:
data: sel_fields type if_wd_select_options=>tt_selection_screen_item.
wd_this->lv_sel_handler->get_selection_fields( importing et_fields = sel_fields ).
You can then loop through all the select-options and put each into a generic internal table. You can then loop through all rows in the generic internal table and cast each of the fields into a field symbol.
field-symbols: <wa_fields> like line of sel_fields,
<wa_generic> type table.
field-symbols: <wa> type any,
<option> type char2,
<sign> type char1,
<high> type any,
<low> type any.
* Build the field symbols for each Range table
loop at sel_fields assigning <wa_fields>.
assign <wa_fields>-mt_range_table->* to <wa_generic>.
loop at <Wa_generic> assigning <wa>.
assign component 'OPTION' of structure <wa> to <option>.
assign component 'HIGH' of structure <wa> to <high>.
assign component 'LOW' of structure <wa> to <low>.
assign component 'SIGN' of structure <wa> to <sign>.
endloop.
endloop.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
82 | |
10 | |
10 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.