on 03-02-2011 6:07 AM
Hi Friends
I have a requirement wherein I need to display a hyperlink along with the error message in webui.
Example...
Please enter a valid currency Details
Here Details should appear as a Hyperlink and on clicking on this hyperlink it should navigate to a portal screen.
Infact it is not actually a portal screen, it can be any URL.
Could you please let me know how to add the hyperlink and how to navigate to portal screen on clicking on this hyperlink
where do we need to write the code.
Best Regards
Anil
Edited by: ANILKUMAR M on Mar 3, 2011 7:23 AM
Hi Anil,
This is very simple....what you need to do is what ever error/information message you are displaying you just need to attach long text to that and system will automatically show you the Details word with hyper link and when you click on it you would see the long text that you attach to the message...
Please follow these steps:
1. Goto se91 specify your message and no and click on display
2. Uncheck the Self explainatry check box
3. Select the message and in the menu bar click on GOTO->Documentation->Long Text
4. Here you can define what ever you want to display when user will click on Detais in the error message.
I hope this would resolve you issue if yes plaease award the points:)
Regards
Ajay
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Anil.
According to SAP Help you can always get a link in a message for:
. Fields that are defined as mandatory in the UI Configuration Tool
. Fields that are defined as mandatory in the business object layer (BOL)
Also it's possible with additional coding. The example is:
lr_msg_service = view_manager->get_message_service( ).
lr_msg_service->add_message_mapping( iv_message_class = 'CRM_BRC_MESSAGES'
iv_message_number = '013'
iv_binding_string = '//BRCBUSINESSROLE/STRUCT.CRMUI_NAVBAR'
iv_page_id = component_id ).
Check this [link|http://help.sap.com/saphelp_crm700_ehp01/helpdata/EN/cb/659ebfc880493baad66896518a55a1/content.htm] for details. Look at "Navigation to Field That Issued a Message" section and related link for "Enabling Links in Messages".
Another option, which mentioned Arun and according [to this book|http://www.sap-press.com/products/SAP-CRM-Web-Client-Customizing-and-Development.html], is the global message service. The global message service enables you to register callback methods so that you can output navigable messages, that is, you can initiate a navigation to another view (or do whatever you want ) by clicking the message. Registration of the message service for a message looks like:
DATA: lr_service TYPE REF TO cl_bsp_wd_message_service.
lr_service = me->view_manager->get_message_service( ).
TRY.
lr_service->subscribe_message(
iv_message_class = 'CRM_IC_PPL_UI_BDC'
iv_message_number = '114'
iv_subscriber = me
iv_activation = abap_true ).
CATCH cx_bsp_wd_dupl_mess_subscr.
ENDTRY.
where is the ME self reference points to a view controller that implements the IF_BSP_WD_MESSAGE_HANDLER interface, including HANDLE_MESSAGE method.
Thanks to Arun and Andrey !!
You both guys have explained the solution perfectly and I was just looking for the same to give a link and navigate to another view.
Its really unfortunate that the person who raised the thread did not even reply with a Thanks !!
I really feel sorry that I can not give 10 to Arun and Andrey for giving the solution, because its not my thread, but i hope moderator may give.
The thread raiser did not implement the solution may be but that does not mean that the solution proposed by Arun and Andrey is not useful !!
Once again thanks.
Regards
Suchita
Hi Andrei,
We have implemented the same logic what you have suggested to add a hyperlink below an error message and link the message to the particular field, and it is working perfect for standard fields. But when i try to do the same for AET fields, it is adding the hyper link but unable to navigate to the field.
We suspect some problem with the binding string we are passing. And the format which we are using is as follows:
CONCATENATE '//BTADMINI[' lv_index ']/ ZZFLD00003V' INTO lv_bind_string.
Also we have tried adding EXT.ZZFLD00003V' in place of the attribute name.But that didnt help us.
Please suggest us on this.
Thanks in Advance....!!!!!!
Best Regards,
Amarendra.
User | Count |
---|---|
3 | |
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.