Component level display of the Custom Error Message in 11g

Iam using custom error handler that extends the default DCErrorHandlerImpl class to handle the Custom exceptions thrown from the service layer, and able to see the exception displayed in the ADF UI in a popup window.
How can we do Customization in order to display the Custom error message inline with a component (i.e. associated with a specific UI component with the arrow mark look and feel ) instead of the global level message displayed as a pop up window on the ADF UI page? Please suggest.
Thanks,
Kayal.
Edited by: user11217416 on Feb 15, 2012 6:07 AM
Edited by: user11217416 on Feb 15, 2012 6:14 AM

Hi,
Try as follows
  final static int MSG_FATAL = 1;
  final static int MSG_ERROR = 2;
  final static int MSG_WARN = 3;
  final static int MSG_INFO = 4;
      public static void showMsgForRelevantComponentAll(int iSeverity, String sMsg, UIComponent uIComponent) {
          FacesMessage msg = null;
          switch (iSeverity) {
          case MSG_FATAL:
              msg = new FacesMessage(FacesMessage.SEVERITY_FATAL, null, sMsg);
              break;
          case MSG_ERROR:
              msg = new FacesMessage(FacesMessage.SEVERITY_ERROR, null, sMsg);
              break;
          case MSG_WARN:
              msg = new FacesMessage(FacesMessage.SEVERITY_WARN, null, sMsg);
              break;
          case MSG_INFO:
          default:
              msg = new FacesMessage(FacesMessage.SEVERITY_INFO, null, sMsg);
          FacesContext facesContext = FacesContext.getCurrentInstance();
          facesContext.addMessage(uIComponent.getClientId(facesContext), msg);
      }

Similar Messages

  • The custom error message in the bank application is displaying in English

    Hello Team,
    The custom error message for a blank institution number in the bank application is displaying in English when the user is logged in French. See attached screen shot.
    ESS --> Personal Information --> Bank Information.
    Could any one let me know the procedure in solving the error. Helpful answer is highly appreciated.
    Thanks,
    Sankar

    Hi,
    sandip is correct, go to SE11 Table T100.
    I did it this way: Searched for (in my case) SPRSL = DE and TEXT = "Bitte Bankschlüssel eingeben" (that's the said error message). With the upcoming result I got the message ID and message Number, these are:
    ARBGB = 'AR' MSGNR = '195'
    ARBGR = '1J' MSGNR ='510'
    Maintain them for your SPRSL and you should be fine.
    regards, Lukas

  • OAF page is not able to display the custom error messages

    Hi,
    I have extended a seeded CO and trying to throw few custom error messages.
    It was working fine, but suddenly it is not able to display the error messages(but checked that the error messages are still present in application) and saying "Message not found. Application: PER, Message Name: ...."
    Is there any profile option which enables the custom messages?
    Thanks,
    Ranita

    Hi,
    There is no profile to enable the Custom error Messages, u will use the diagnostistics for showing the messages in the custom page
    use the following syntax for writing a msg in Jdeveloper
    pageContext.writeDiagnostics(strClassName, "Initializing the vo....", OAWebBeanConstants.STATEMENT);
    and enable the following profile option to yes
    Fnd:Diagnostics
    Regards
    Chanu

  • IDOC_INPUT_ORDER - How manage the custom error message ?

    Hello,
    on EXIT_SAPLVEDA_002 and EXIT_SAPLVEDA_003 I done some custom check, (I would show some custom message as a result of these check).
    My question is: How to show these custom message on the standardc idoc spool (WE02) ??
    There's DERRTAB internal table to manage the error, but is not available on there exit ...(EXIT_SAPLVEDA_002 and 3)
    Any idea ??
    thank you

    Hello,
    question is if you want to raise an error, which makes sense only if the document is not posted or just an information message.
    Please consider that you can put messages into the idoc only connected with a status. If you set status 51 thge Idoc is reprocessible, if you set status 53 it is successfully processed.
    In error case you can raise exception USER_ERROR. in exit EXIT_SAPLVEDA_002. Set SY-MSGTY, SY-MSGID, SY-MSGNO, etc before. In exit EXIT_SAPLVEDA_003 you can set changing parameter ok to space. Then SAP will add an error message.
    /Michael

  • Cannot display custom error message in CRM_MKTLIST_BADI

    We did implement the following BADI BADI Name: CRM_MKTLIST_BADI
    Interface: IF_EX_CRM_MKTLIST_BADI Method: MAP_AND_CONVERT_DATA
    This enhancement is for suport the extension field for create new BP in
    external list management (transaction CRMD_MKTLIST). The BP creation
    process work properly but we cannot display our custom error message,
    only SAP standard error message is shown. We did try using the export
    parameter ET_MKTLIST_E but it does not work as expected, custom message
    still cannot display.
    How we can be show the custome error message ?
    Thanks in advance.
    Supreeya K.

    Hello Supreeya,
    have you tried to post this question in the SAP CRM: Webclient UI - Framework forum?
    Regards
    Gregor

  • How to display custom error message in Job log for batch processing

    Hi All,
    I am rexecuting one R/3 report in batch mode and i want to display all the custom error i have handled in job log when its executed from SM36,SM37. The custom error are like 'Delovery/Shipmet doe not exits' or others which we can display in online mode like message e100(ZFI) or any other way and accordingly we can handle the program control like come out of the program ro leave to transaction'Zxxx' or anything. But i want my program to be executed completely and accumulate all the error in job log of batch processing.
    Can anyone tell me how can i do so...
    Thanks,
    Amrita

    Hi,
    Thats what i have done from the begining. I have written message like this:
    Message i100(ZFI).
    I was hoping to see this message in the log. But i cant see. Can you help me pleae...

  • Catch datetime exception and custom error message in SSRS

    I currently working on create report by using SSRS. I have 2 parameters: [Start date] and [End date] to filter data from database and show it on report. I want to validate 2 datetime parameter as describe above. Please tell me a solution to do this.
    For example:
    When user type the text like: 4/15/2014mmm => System validation thrown a message: [The From Date not correct type]
    But in my case, I want to receive a custom error message by myself.(Look like: [Date Invalid!])

    Hi Brain,
    According to your description, you have a report with two parameters for user to input. Now you want to validate these two parameters and display custom error message when the date is invalid. Right?
    In Reporting Service, it doesn’t provide any interference for us to modify the system error message (the text in grey color). That means we can’t modify the system message when error occurs. However we can create a textbox in this report, use custom code
    and expression to display the custom error message. But this all based on the report is successfully running. So if error occurs during report processing, all the custom code and expression will not work. In this scenario, we find a workaround for you. We
    use custom code to judge if the date is valid, if the users type an invalid date, we return a default value to make sure this report can successfully run. Then we use expression to control the visibility of tablix in this report and create a textbox to show
    the custom error message. Your case has been tested in our local environment. Here are steps and screenshots for your reference:
    Go to Report Properties. Put the code below into custom code:
    Public Shared a As Integer=0
    Public Shared Function IsDate(d1 As String,d2 As String) as Integer
            Try
               FormatDateTime(d1)
               FormatDateTime(d2)
            Catch ex As Exception
                       a=1
            End Try
    return a
    End Function
    Create two parameters. One is StartDate, the other is EndDate. Set the data type of these two parameters Text.
    Create a filter for StartDate, put the expression below into Value:
    =IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,CDate(IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,Parameters!StartDate.Value,"1/1/2012")),CDate("1/1/2012"))
    Create a filter for EndDate, put the expression below into Value:
    =IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,CDate(IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,Parameters!EndDate.Value,"1/1/2013")),CDate("1/1/2013"))
    Ps: In step3 and step4, the date(“1/1/2012”, “1/1/2013”) in the expression are the default we set to make sure the report can successfully process. You can set any date existing in your dataset.
    Use the expression below to set the visibility of the tablix:
    =IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,false,true)
    Create a textbox, put the expression below into it:
    =IIF(Code.IsDate(Parameters!StartDate.Value,Parameters!EndDate.Value)=0,"","Date invalid")
    Save and preview. It looks like below:
    Reference:
    SSRS Calendar and Date Restriction
    Errors and Events Reference (Reporting Services)
    If you have any question, please feel free to ask.
    Best Regards,
    Simon Hou
      

  • CreateStrategyR3 and ReadStrategyR3 Customized Error Message

    Hi
    We want to display customize error message for the function module SD_SALESDOCUMENT_CREATE.
    the function returns a return structure that has error codes like V1-117, V1-118 etc
    We want to display the customized error message for this code
    so we have made the changes in CreateStrategyR3 and ReadStrategyR3 
    as well as we have placed the customized message in the property file
    but I still cant see customized error message i can see the std error message of SAP
    Can anyone help me out with this
    Regards
    JM

    Hi ,
    Does this approach work for the version 7.0 also?
    I have made changes to ReadStrategyR3, OrderR3, backendobject-config.xml and overriden replaceR3MessageTexts.
    public boolean replaceR3MessageTexts(JCO.Record messageRecord, StringBuffer messageId, StringBuffer text){
              super.replaceR3MessageTexts( messageRecord , messageId, text); is the way i am trying to override it.
    Still the standard message is getting displayed.
    I am trying to capture message V1/150.
    Please help.
    Best regards,
    Rohit Sharma

  • How to display custom error message if the Required field is not entered?

    Hi,
    I have made one input field as required field in a view.
    I want to display one custom error message ,if the required input field is not entered.
    Please help me regarding this.
    Thanks,
    Deepika

    hi deepika....
    First go to message pool under webdynpro components.
    Create a new message there..of type error.
    Enter your text.
    Now to avoid null pointer exception , in wdDoInit(), initialise the value
    wdContext.currentDateTimeElement().setDate("");
    now create an action for submission of data. If field is empty, then within the button write:
      msg = wdComponentAPI.getComponent().getMessageManager();
        if(wdContext.currentDateTimeElement().getDate().equals(""))
        msg.raiseMessage(IMessageCompTodatDateTime.ERROR,new Object[]{""},true)     ;
    between begin others put:
    regards,
    pinki
      IWDMessageManager msg = null;

  • ICI - How to display custom error messages in SAP CRM

    Hello,
    we are working on a custom Contact Center which interfaces with SAP CRM Version 7 with Enhancement Package over ICI.
    The basic call functions like accepting, hanging up, holding and retrieving are fully implemented and are working already.
    Our goal is to display error messages in the CRM so that clients know there is something wrong, for example why he can't be log in successfully (e.g. the telephony server isn't reachable).
    We already found the ICI Documentation file which provides us the CRM SOAP error codes and tried to send SOAP Fault messages, but never got
    them to screen.
    Please find an attached example screenshot what we mean exactly, reproduced by trying to make a call with CRM user while BCM CDT isn't
    running in the background.
    Regarding to this topic we've the following questions:
    - Is it possible to display custom error messages on the CRM or is this functionality limited to SAP?
    - Could you provide us some further information on how to use this feature exactly (implementation details?) and how the SOAP XML should look like to get it work?
    Thank you in advance!
    Best regards
    René Holy

    NewUser7 wrote:
    Please correct me if I am wrong
    I need to create an entity adapter and attach an error handler with the adapter? or can i handle that in the event handler itself. I coulnt find any api for handling errorsYou can do it both ways but since we are talking about event handler now, then in 9.x you need to extend com.thortech.xl.client.events.tcBaseEvent class for creating a event handler. In tcBaseEvent class there are various flavors of handleError method. So use that as per my note earlier and you should be good.
    HTH

  • Displaying Custom Error Message in ALV

    Hello Experts,
    Usually, when an error occurs in editable ALV, the standard WD ALV functionality marks the particular error cell in red and displays the error message.
    I want the same functionality for custom error messages in event ON_DATA_CHECK. I'm able to display the message, but looking for a way to mark cells as well.
    Please help....

    Hello friend,
    I think this link will help you much more clear on the coloring of the ALV concepts.
    http://help.sap.com/saphelp_smehp1/helpdata/en/5f/ec57c72a1349c8bfdda56d976e9399/frameset.htm
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/f0625002-596c-2b10-46af-91cb31b71393?QuickLink=index&overridelayout=true
    Thanks,
    Sri Hari

  • Display custom error message in enhancement spots

    Hi all,
    Is there someone here who've encountered having the need to display custom error message in an enhancement spot? Could you help me please.. I can't find any reference from the net.
    Thanks in advance
    Regards,
    Aris

    Hi,
    The error message can be only displayed in enhancement spots based on thr program flow.
    You have to determine where its getting called for ex: in PBO or PAI etc.....
    You have to find the right place to display the error messages . for ex: using a memory id ......

  • "Cannot play video - The Connected display is not supported" error message using Netflix 5.0.2 on my iPad

    I'm running iOS 7.0.3 on my iPhone 4S and iPad (3rd gen) and have just upgraded to the current version of the Neflix app available in the Canadian App Store (5.0.2).
    Although all other apps I've tried (e.g. Podcast, VLC) are able to properly output video & audio directly to my TV using the HDMI adapter (i.e. NOT via an Apple TV), the Netflix app pops up the error message "Cannot play video - The connected display is not supported".  If I start a video and then plug the HDMI cable in, it will play for a few seconds and then halt with the same error message.
    Netflix & Apple were supposed to have been working together to fix the previous issue with this scenario which was causing audio to be output but no video.  The current Netflix app update was released yesterday and seems to have taken a step backward.
    When I contacted Netflix support, they indicated that they have done whatever can be done from their side and this is now Apple's issue.
    Any ideas?
    Thanks!
    Kiron

    Hello all,
    I have an iPad 2 16GB with iOS 7.0.3 and Netflix version 5.0.2. I cannot watch netflix on an External LCD monitor that I have through VGA out. I use bluetooth speakers, so the AirPlay is going to that for Audio. Before this update, this combo worked without an issue.
    So as of Friday Nov. 8/2013, I contacted Netflix support, and they said they fixed the problem on their end, and the fix is on the Apple side of things, and to contact Apple support.
    So, I contacted Apple support, and the first person I spoke to said I would have to agree to pay a $35 fee for 30 days of support to this problem since my unit is out of warranty. I said this isn't a hardware issue, it's a software issue, and I'm not willing to pay to fix a problem you created. So I got a Senior Level advisor on the line, and she was helpful, and she's looking into the issue for me and said she'll contact me sometime on Tuesday or Wednesday (Nov. 12 or 13) to let me know of the issue.
    Here's the thing: this is a combination of Netflix and iOS not working correctly with any of the Apple Authorized Dongles. This is truly a code error that some hot shot programmer had major oversight on, and their management didn't catch it either. There was no reason for Netflix to rush to get this Netflix update going until Apple sorted out the bugs in iOS 7.
    Anyway, if I hear anything from Donna (the advisor), I'll post it and let you guys know. In the mean time, good luck!

  • LSO_CHECK_BOOKING custom error messages are not displayed

    Hi,
    Good day! I am currently experiencing some problems displaying custom error messages from BADI LSO_CHECK_BOOKING. I have implemented this Badi and is appending error messages in CT_MESSAGE_TAB however when the message is displayed in portal, the custom message is not displayed. Instead, SAP displays a predefined error "Error When Creating Prebooking with the data entered..."
    Is there a way for me to display my custom error message instead of the predefined SAP message?
    Thanks a lot.
    Cheers,
    James

    Hi James,
    You have not mentioned, which portal you are using. Please see below, that there are differences in the learning and the admin portal:
    Learning Portal:
    The framework of the existing design of the Learning Portal does not
    allow customer specific error messages to be displayed in the portal.
    Only a generic message will be displayed when prebooking in the learning
    portal if the BADI LSO_CHECK_BOOKING returns an error. The design of the
    application does not expect to raise an exception from the BADI. If the
    BADI processing is assumed to be unsuccessful, the messages filled by
    the BADI will be ignored and a general error message will be displayed
    in the portal.
    So this is basically a design limitation.
    Administrator Portal:
    Have you tried e.g. the following notes?
    SAP Note 1806593 Admin Portal: Message is not displayed while prebooking
    SAP Note 1575238 LSO: BADI LSO_CHECK_BOOKING does not show warning messages
    Regards,
    Agnes

  • Print a custom Error message in the XML bursting program's log file...

    Hi,
    I having this requirement, where i need to print a custom error message in the xml bursting program's log file.
    Actually i am having a report where i create invoices and then those invoices are emailed to the respective customers, now say if a customer has three contacts and there is only two valid email id's so what happens is bursting will be successful for two contacts whereas the third contact dosen't get any emails. when this happens i need to log a message in the bursting programs log file stating a custom message.
    Two things i want to know..
    1- Whether is it possible to write into the xml bursting programs log file
    2- If yes, then how..
    note: it ll be greatly appreciated if the answer is elaborated.
    thanks,
    Ragul

    Hi,
    I having this requirement, where i need to print a custom error message in the xml bursting program's log file.
    Actually i am having a report where i create invoices and then those invoices are emailed to the respective customers, now say if a customer has three contacts and there is only two valid email id's so what happens is bursting will be successful for two contacts whereas the third contact dosen't get any emails. when this happens i need to log a message in the bursting programs log file stating a custom message.
    Two things i want to know..
    1- Whether is it possible to write into the xml bursting programs log file
    2- If yes, then how..
    note: it ll be greatly appreciated if the answer is elaborated.
    thanks,
    Ragul

Maybe you are looking for

  • Color Laserjet Pro M277dw making weird noises when printing

    Hello Everyone, At my office we bought the Color Laserjet Pro M277dw printer last week, and since then everytime we print, the printer makes really weird noises. We checked inside but everything inside looks to be okay . Here you have the link with a

  • GETTING ROW COUNTS OF ALL TABLES AT A TIME

    Is there any column in any Data dictionary table which gives the row counts for particular table.. My scenario is...i need to get row counts of some 100 tables in our database... instead of doing select count(*) for each table....is there any way i c

  • Can't update iPad since iTunes uses drive C. Solutions?

    Can't update iPad since iTunes uses drive C. Solutions? Yeah, I've seen this topic: http://apple.stackexchange.com/questions/27446/i-do-not-have-enough-free-space-o n-the-c-drive-of-my-windows-computer-to-run-t But which one is 100% working solution?

  • 'ASSERTION_FAILED' dump in a BI trasformation rule

    HI BI Gurus, After a trasport in Quality System , I can't open the trasformation rules related to a master data of a charatteristic . When I try to open these trasformations a 'ASSERTION_FAILED' dump is showed with this short text: "The ASSERT condit

  • Getting a run time error  R6034 when updating itunes

    Itunes trying to load incorrectly