on 01-27-2011 10:23 AM
Hi Experts ,
i want to higlight the input field based on some condition , i tried using reporting attribute message ,
but how to hide the MSG area ? higliting the input field is enough for me .
have a look at the below image .
[http://i56.tinypic.com/119qnwn.jpg |http://i56.tinypic.com/119qnwn.jpg ]
Regards
Chinnaiya P
Hi ,
Have u tried 'REQUEST_FOCUS()' method of the context attribute??
I am not sure if this is making sense,..but still a suggestion.:)
[Look At This|http://help.sap.com/saphelp_nw70ehp1/helpdata/en/2e/a9ed633634494da688855433e105da/frameset.htm]
Thanks,
Aditya.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
have you tried modifying the visiblity property of the message area to none dynamically at runtime.
thanks
sarbjeet
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
i tried to set the visiblity in modify view , but still its displaying the msg area .
data:
lr_msg_area type ref to cl_wd_message_area.
* get a pointer to the msg area
lr_msg_area ?= view->get_element( 'MSGAREA' ).
lr_msg_area->SET_VISIBLE( 01 ).
any other way to higlight the input field based on the condition ?
Regards
Chinnaiya P
then the only remainng option is request focus.
or there is one more thing which is also possible.
you can use the grid layout and then control the property cell backgroud design for the input field dynamically.
means you can bind the proerpty cell background design to soem attribute and then change it dynamically when you want to highlight.
thanks
sarbjeet singh
Problem solved by my self .
let me share the piece of code to hide the msg area .
if lv_field1 ne lv_field2.
* get message manager
DATA lo_api_controller TYPE REF TO if_wd_controller.
DATA lo_message_manager TYPE REF TO if_wd_message_manager.
lo_api_controller ?= wd_this->wd_get_api( ).
CALL METHOD lo_api_controller->get_message_manager
RECEIVING
message_manager = lo_message_manager .
* report message
CALL METHOD lo_message_manager->report_attribute_error_message
EXPORTING
message_text = 'hiiia '
element = lo_el_context
attribute_name = 'FIELD2'
receiving
message_id = msgid .
* below code will reset the message .
data: l_api_testcase1 type ref to if_wd_view_controller,
l_api_wdr_test_msg_area type ref to if_wd_window_controller,
l_wd_message_area type ref to if_wd_message_area.
l_api_testcase1 ?= wd_this->wd_get_api( ).
l_api_wdr_test_msg_area ?= l_api_testcase1->get_embedding_window_ctlr( ).
l_wd_message_area = l_api_wdr_test_msg_area->get_message_area( ).
l_wd_message_area->reset_messages( i_keep_current = 'X' ).
endif .
have a look to the solution arrived .
[http://i54.tinypic.com/11gna4w.jpg|http://i54.tinypic.com/11gna4w.jpg]
thanks for all those give your valuable suggesion
Regards
chinnaiya P
Edited by: chinnaiya pandiyan on Jan 28, 2011 5:08 PM
User | Count |
---|---|
95 | |
11 | |
10 | |
9 | |
9 | |
7 | |
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.