on 10-04-2012 4:18 AM
Hello Experts ,
I have created a custom UI Component. I have a description field at the header level as shown below. Description field is 124 char length.
The same description i am displaying on the over view page as shown in green color. Now how to change the title length so that i can display complete length ?
Thanks and Regards,
Nikhil Kulkarni
Hi,
try using the below code for ur reference..
method IF_BSP_WD_HISTORY_STATE_DESCR~GET_STATE_DESCRIPTION.
DATA lr_name TYPE REF TO if_bol_bo_property_access.
DATA lv_name TYPE STRING.
lr_name ?= me->typed_context->ZDETAILS->collection_wrapper->get_current( ).
CALL METHOD lr_name->get_property_as_string
EXPORTING
iv_attr_name = 'FIRSTNAME'
RECEIVING
rv_result = lv_name.
CONCATENATE 'Details of' lv_name INTO description SEPARATED BY space.
endmethod.
cheers,
Savaridassan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Nikhil,
Check the method IF_BSP_WD_HISTORY_STATE_DESCR~GET_STATE_DESCRIPTION of the window . I guess the description parameter is of type string and it should be fine .
Regards,
Nithish
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Nithish ,
Ya it makes sense. But as you can see the in the above figure , i am only setting '69' in IF_BSP_WD_HISTORY_STATE_DESCR~GET_STATE_DESCRIPTION . Not sure from where it is getting this description . Is there any other place where we get the text and concatinate with this text ? Hope i am clear in explaining my problem.
Best regards,
Nikhil Kulkarni
Hello Nithish ,
u were rt , basically i have 3 components , one for search , one as head component and another component by name MAIN which is intermediate between my Search and Head component . Main component has only Navigation links.
Now in my search component _IMPL class i am getting some text and i am setting that in the method : IF_BSP_WD_HISTORY_STATE_DESCR~GET_STATE_DESCRIPTION . And now when i am navigating to my Head component via main component , i am adding some more text to that title. and it is been done in
IF_BSP_WD_HISTORY_STATE_DESCR~GET_STATE_DESCRIPTION of my main component _impl class. Here i am getting the reference of the window and navigating to head component.
I could have even set every thing in the Main component's get_state_description method also . is'nt it ?
or even in my Head components get_state_description. Which would you suggest to implement ?
THanks and Regards,
Nikhil Kulkanri
Nikhil,
If you have separate Main(M), Head(H) and Search(S) component , the M -component main window method IF_BSP_WD_HISTORY_STATE_DESCR~GET_STATE_DESCRIPTION gets triggered first which will call the appropriate H or S components window based on component usage .
Now in either H or S components Main window method , you can place your logic to display the title or you can call the overviewset page of the same component and place the logic there . It depends upon your requirement . In most of the standard components , they use this approach first they try to check at the inner level ( overview level) , if it doesn't fetch anything then they use some default logic to populate the description.
In your case you can try redefining the overviewset method , in case the window method is calling the ovevrviewset method to fetch the description . Else , you directly can redefine window method and place your logic.
Regards,
Nithish
hi
can u pls elaborate ur requirement ??
Thanks ,
Lokesh.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
At the header level in the above screen shot , i a have Description field. The same description i want to display it on the Over view page title bar . it is getting displayed but partially as you can see. So i want to know where we should change this title length so that it can accomodate full description .
THnaks and regards,
nikhil Kulkarni
User | Count |
---|---|
5 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.