on 01-08-2009 12:57 PM
Hi All,
I am working with the assistance class.In text symbols i created one text with sym= 001,text = welcome and mlen = 8.
I passed this number as key to get_text method as
DATA: lv_text TYPE string.
lv_text = wd_assist->if_wd_component_assistance~get_text( key = '001' ).
and i binded the lv_text to text property of i/p element textview using set_attribute method but i am getting the error as text 001 not found
Can anybody give me the solution for this........
Everything sounds right. Are you sure you actived the text in the assistance class. Sometimes people edit and then forget to active - and therefore the text symbol wouldn't exist at runtime. Otherwise your steps sound correct.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi The exact code to get the text symbol text to webui screen.
Maintain a text in text symbol in webui Component and call this code in your method
DATA LO_API_CONTROLLER TYPE REF TO IF_WD_CONTROLLER.
DATA LO_MESSAGE_MANAGER TYPE REF TO IF_WD_MESSAGE_MANAGER.
DATA LV_MSG(80) TYPE C.
DATA LV_TXT TYPE STRING.
LO_API_CONTROLLER ?= WD_THIS->WD_GET_API( ).
CALL METHOD LO_API_CONTROLLER->GET_MESSAGE_MANAGER
RECEIVING
MESSAGE_MANAGER = LO_MESSAGE_MANAGER.
CLEAR: LV_TXT, LV_MSG.
LV_TXT = WD_ASSIST->IF_WD_COMPONENT_ASSISTANCE~GET_TEXT( KEY = '001' ).
LV_MSG = LV_TXT.
* report message
CALL METHOD LO_MESSAGE_MANAGER->REPORT_ERROR_MESSAGE
EXPORTING
MESSAGE_TEXT = LV_MSG.
EXIT.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Thomos,
Thanks for ur reply.My problem is solved I forgot to activate the text symbols.Now i got the solution....
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
lv_text = wd_assist->if_wd_component_assistance~get_text( key = '001' ).
Insted of this used
lv_text = wd_assist->if_wd_component_assistance->get_text( key = '001' ).
Rick
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
>
> Hi,
>
> lv_text = wd_assist->if_wd_component_assistance~get_text( key = '001' ).
>
> Insted of this used
>
> lv_text = wd_assist->if_wd_component_assistance->get_text( key = '001' ).
>
>
> Rick
Rick, what you are suggestion isn't syntactically correct. You can't change the ~ to a -> as if_wd_component_Assistance is an interface and not an object instance. the original coding with the ~ is the correct coding.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
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.