on 11-01-2008 1:41 AM
Hello All,
I have a table ui in one of my application. This table has, say 6 columns; out of these 6 columns 4 columns are shown as input fields. User needs to put in some numbers in two of the fields. I need to capture these two number fields data and subtract one from the other. If number is negative , I need to let the user know by error message that the number is negative and they need to fix their input to make the answer positive. I am able to do all this, but I am not able to high light the corresponding field which needs to be fixed. Is there anyway I can do that...I mean high light the particular field as one gets it when we use the "report attribute error message" method of message manager class.
Secondly I can not halt the application, I need to do some work around for that using some flags. Is there a simple way to halt the application, other than using flags and if condition? I searched this forum, but could not find any definite answer....
Thanks very much!
Any help would greatly be appreicated.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi....
First you should have the table values in an internal table.... for that yo need to get the values from the context like this....
*DECLARE INTERNAL TABLE AND WORKAREA.
data ls_nd_stru type wd_this->element_<node name>
data lt_nd_table type wd_this->elements_<node name>
get all declared attributes
lo_nd_<your context node>->get_static_attributes_table(
importing
table = lt_nd_table ).
*now your lt_nd_table will have the values.....what ever you have in the table.
*then
loop at lt_nd_table into ls_nd_stru.
<.....your logic.....>
<ie., read the current line of the field like
ls_nd_stru-<field name1> = ls_nd_stru-<field name2> - ls_nd_stru-<field name3>
then check error msg... based on your postive or negative values
endloop.
Hope this will help you....
Thanks & regards
Raja
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Raja,
I know how to get the number and all the things. I want to know if there is a way to highlight the corresponding column which value needs to be changed. What I am doing is making that cell in red color. But what I want something similar to what we have when we write message with type "e", in regular ABAP.
If there is none than I guess I will stick to my solution.
Thanks for help!
User | Count |
---|---|
92 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.