[Struts] Presenting errors and messages in a neat fashion

I need to write a piace of jsp code that will present the errors and the messages to the user.
The errors (if any) must appear under a small title "errors" (error.title in Message Resources), while other messages (if any) will appear under the title "messages".
I found a piece of code, that already works, for showing validation errors:
<logic:messagesPresent message="">
   <font color="red"><bean:message key="error.title"/></font><br/>
   <html:messages id="message">
     <html:img page="/view/images/arr_right.gif"/><bean:write name="message"/><br />
   </html:messages>
</logic:messagesPresent>But I don't know how to have it 'recognizing' the difference between messages and errors, and how to present them appropriately.
Edited by: Lorenzo_Carnevale on Jul 10, 2008 4:15 AM

Maybe you can't like that. Instead of it, you need to create the script using the command like "grep".

Similar Messages

  • ON-ERROR and ON-MESSAGE

    Is anyone using a stored procedure to trap and intercept Oracle Forms Errors and Messages using the ON-ERROR and ON-MESSAGE Triggers?
    In order to do this, I would like to store Oracle's Forms error in a table. I have been unable to located the .msg file that contains the flat file for all of oracle errors and messages. I have loaced the binaries at: $ORACLE_FORMS_HOME\forms90 in the following 5 files: (1) fmcus.msb (2) fmdus.msb (3) fmfus.msg (4) fmgus.msg and (5) fmmus.msb
    Does any know where I can locate the .msg files?
    Any help would be appreciated.

    Hello,
    You can use ERROR_TYPE and ERROR_CODE to ask your own tables
    Declare
    err_code NUMBER := ERROR_CODE;
    errmsg VARCHAR2(512) ;
    Begin
    If ERROR_TYPE = 'FRM' Then
    SELECT message_text
    INTO errmsg
    FROM forms_message_table
    WHERE code = err_code ;
    Elsif ERROR_TYPE = 'ORA' Then
    SELECT message_text
    INTO errmsg
    FROM database_message_table
    WHERE code = err_code ;
    Else
    errmsg := ERROR_TEXT ;
    End if ;
    Set_Alert_Property( 'ALERT1', TITLE, 'Forms error message' ) ;
    Set_Alert_Property( 'ALERT1', ALERT_MESSAGE_TEXTE, errmsg ) ;
    Ok := Show_Alert( 'ALERT1' ) ;
    Exception
    When NO_DATA_FOUND Then
    Set_Alert_Property( 'ALERT1', TITLE, 'Forms error message' ) ;
    Set_Alert_Property( 'ALERT1', ALERT_MESSAGE_TEXTE, ERROR_TEXT ) ;
    Ok := Show_Alert( 'ALERT1' ) ;
    End ;

  • Setup email in my nokia e71x,and messaging phone i...

    my phone can't open yahoomail(error)and messaging instant phone can't be open (error in communication) even if network provider is goodly set.what the solution of this?

    Hi kabideco13
    Thank you for posting! 
    Simple steps that you can try:
    Restart your phone
    1. Switch your phone off
    2. Remove the battery. 
    3. After a few seconds, put the battery in and switch your phone on.
    Reset the settings
    Restore the original factory settings as instructed in your phone's user guide.
    If my post helped you, please don't forget to click on the "White Star" and if it resolved your issue click on "Accept as Solution"

  • I have tried several times to install iTunes update 11.1.4 on my PC.  I get a message saying that install was not successful and an error message of MSVCR80.dll not present, Error 7, (Windows error 126).  I am told to reinstall iTunes, but nothing changes

    I have tried several times to install iTunes update 11.1.4 on my PC.  I get a message saying that install was not successful and an error message of MSVCR80.dll not present, Error 7, (Windows error 126).  I am told to reinstall iTunes, but nothing changes.  What next?  I've not had this problem with other updates requested by Apple.

    I have also had the same problem with my Win 7 32 bit computer.  I had great help from Apple techs in Montreal and Orlando for 2.5 hours.  They helped me remove every trace of Apple products and clean the registry in two different ways.  Each install gave the same problem!  If Apple techs can't fix it (on some of our machines) then we are really in trouble.  They promised to raise it with the "engineers" and get back to me with a solution.  I am waiting and hoping.  Otherwise maybe version 11.1.5 will have a fix ??

  • "An error occurred while opening the file dialog. Please save your presentation, exit, and restart PowerPoint."

    In PowerPoint 2013 on Windows 7 - 64 bit, when
    File / Save as is selected, an error message comes up stating, "An error occurred while opening the file dialog. Please save your presentation, exit, and restart PowerPoint." This is an intermittent issue and also
    affects Excel 2013. I have tried repairing it, done windows update and also uninstalled and reinstalled but no luck. I have researched this issue but it relates to Office 2007 and 2010 and the resolution does not support 2013.
    Has anyone come across this issue? If so how did you resolve it?
    Many thanks….

    Hi,
    You mentioned you tried some steps but I'm not sure what they are, you may try my suggestion to resolve this issue, follow these steps:
    Click Start, right-click Computer, click
    Properties, and then click Advanced system settings.
    On the Advanced tab, click Environment Variables.
    Locate and select the __COMPAT_LAYER variable, and then click Edit.
    Set the value of the __COMPAT_LAYER variable to EnableThemes. Or, delete the __COMPAT_LAYER variable.
    If the issue persists, we can troubleshoot this problem in Clean Boot to determine whether background programs are interfering with PowerPoint:
    http://support.microsoft.com/kb/929135
    Regards,
    Melon Chen
    TechNet Community Support

  • Porting an InDesign Plugin from InDesign CC to InDesign CC 2014 the plugin complies successfully with the InDesign CC 2014 SDK but at run time presents this error and is disabled. Does anyone know what might be the issue?

    Porting an InDesign Plugin from InDesign CC to InDesign CC 2014 the plugin complies successfully with the InDesign CC 2014 SDK but at run time presents this error and is disabled. Does anyone know what might be the issue?
    Run TimeError Message Presented when InDesign CC 2014 runs:
    Adobe InDesign cannot load the FastFractions.InDesignPlugin plug-in. The FastFractions.InDesignPlugin plug-in requires the 9.0 version of InDesign. Please contact the vendor to get a compatible version of FastFractions.InDesignPlugin.
    Show this alert again?

    As already told this means that the plugin has not been ported correctly. Some part of it for ex InDesign libraries or frameworks are being referenced from the CC sdk instead of the CC2014 sdk. To troubleshoot it i would advise you to rename the folder containing the CC sdk on your machine and then compile the project, it will fail to compile and you will get to know straightaway what aspects of the ported project are still accessing the old sdk. Fix the errors and your plugin will load fine.
    Thanks,
    Manan

  • Jabber and Messages: error with cert

    Hi all,
    Since upgrading to Mavericks, I'm not able to connect to my company's Jabber server. I get a cert error, even after I've trusted the cert. All Mavericks users at our company are having the same problem, so the problem isn't just on my computer. I've enclosed a screen shot of the error.
    Is anyone else having the same problem? The same setup - Jabber and Messages - works fine in Mountain Lion and previous OS versions.
    Thanks!

    Hi,
    Look at item 4 in this article
    http://support.apple.com/kb/TS3970
    Some people deliberately alter this file to prevent some apps from "phoning home"
    If I am reading this Cert info correctly you are one of the companies that someone might block.
    9:58 pm      Monday; November 4, 2013
      iMac 2.5Ghz 5i 2011 (Mavericks 10.9)
     G4/1GhzDual MDD (Leopard 10.5.8)
     MacBookPro 2Gb (Snow Leopard 10.6.8)
     Mac OS X (10.6.8),
     Couple of iPhones and an iPad

  • How do I stop my iTunes from getting an "error and has to close" message?

    When I open iTunes, it wants to update my Music Match and I get an error message that "iTunes has experienced an error and has to close".  How do I prevent this?

    No, an external drive will not always be mounted. If the drive goes to sleep, it can unmount, or it may unmount for other reasons. As Chris said, confim that the drive is mounted and active before launching iTunes.
    Regards.

  • I just tried to update my iPhone4 to iOS7 and after downloading, I got an error "4005" message; Now my iPhone is completely wiped out and I can't even get my pc to read it (just has a picture of the USB and the iTunes icon). HELP!!

    I tried updating my Iphone4 from iOS 6.1.4 to 7 via iTunes. After downloading, I got an error 4005 message during installation and now my phone is completely wiped out; is not being recognized by my PC; and all I get on the phone is a photo of a USB plug and the iTunes symbol! Can anyone, PLEASE, help?!?

    The phones in recovery mode so if yu connect it to itunes it should ask to restore it back to the last back up you have done.
    that should solve it for you...

  • Protected mode message comes up and when I try to open files it says it encountered an error and to check online.. i can not open any files now

    Within the past week I have been getting messages when trying to open pdf files " that its in protected mode and can not open"
    I deleted adobe and reinstalled directly from Adobe.com and now I can not open any file with a message it has encountered an error
    and will check online for solution. Please assist as no files will open now
    This is details of error
    Problem Event Name:    APPCRASH
      Application Name:    AcroRd32.exe
      Application Version:    11.0.10.32
      Application Timestamp:    547e9779
      Fault Module Name:    StackHash_147f
      Fault Module Version:    0.0.0.0
      Fault Module Timestamp:    00000000
      Exception Code:    c000041d
      Exception Offset:    77a011f1
      OS Version:    6.1.7601.2.1.0.256.48
      Locale ID:    1033
      Additional Information 1:    147f
      Additional Information 2:    147ff66574b08dc93180d912e60eb897
      Additional Information 3:    c48b
      Additional Information 4:    c48be403c52ec6c06778481aaa8948d8
    Read our privacy statement online:
      http://go.microsoft.com/fwlink/?linkid=104288&clcid=0x0409
    If the online privacy statement is not available, please read our privacy statement offline:
      C:\Windows\system32\en-US\erofflps.txt

    Can you open Adobe Reader by itself?  If so, try to disable Protected Mode [Edit | Preferenes | Security (Enhanced)].

  • My iTunes program is giving me a message that says, "Runtime error" and wont open iTunes. How do I fix this?

    My iTunes program is giving me a message that says, "Runtime error" and wont open iTunes. How do I fix this?

    Try the following user tip:
    Troubleshooting issues with iTunes for Windows updates

  • I am having troubles, when I open LR I get a message that there is an error and it will try to fix the error next time it opens, but I get the error next time it opens, and this is going on and on where I can not use LR, any suggestions?

    I am having troubles, when I open LR I get a message that there is an error and it will try to fix the error next time it opens. LR closes on it's own, I reopen it and get that same message next time it opens, and this is going on and on where I can not use LR, any suggestions? If I click on a different set of photos in the libary before I get that message I might or might not get the message next time it oipens, but I still can not get to those photos, and it is not just one or two but most of my photos. HELP!!!!
    Thanks
    Carol

    The first thing I would suggest is for you to go to the folder containing your catalog, using your system browser. There will be a folder that has the extension .lrdata. Delete that folder, and then try to start Lightroom. If that doesn't work, replace your catalog with your most recent backup.

  • Error when trying to access the RBAC User editor and Message tracking

    Hi,
    I am getting an error when trying to access the RBAC User editor and Message tracking on the Web Mgmt interface. I verified that the admin account trying to access is in the Organization Management group and has the correct Role Assignment Policy applied.
    I searched through this thread below and saw that matching the msExchRoleLink and msExchUserLink attributes fixed the issue. 
    https://social.technet.microsoft.com/Forums/exchange/en-US/fc568cc6-8691-4127-b70b-bcc82f9b1f7f/first-2010-cas-server-no-administrator-rights-emc-permissions-gone?forum=exchange2010
    However I have another environment where this is not the case and works just fine; the msExchUserLink attribute has a value of CN=Organization Management,OU=Microsoft Exchange Security Groups,DC=Domain,DC=Local which is different as per the issue outlined in
    the above thread so I am not convinced that this will work and also don’t want to blindly edit something in adsiedit without being sure.
    I then checked the event logs on the server and saw the below error logged;
    Current user: 'Domain/Server Services Accounts/administrator'
    Request for URL 'https://server.domain.com/ecp/default.aspx?p=AdminDeliveryReports&exsvurl=1' failed with the following error:
    System.Web.HttpUnhandledException: Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> Microsoft.Exchange.Management.ControlPanel.UrlNotFoundOrNoAccessException: The page may not be available or you might not have permission to open the
    page. Please contact your administrator for the required credentials. For new credentials to take effect, you have to close this window and log on again.
       at Microsoft.Exchange.Management.ControlPanel._Default.CreateNavTree()
       at Microsoft.Exchange.Management.ControlPanel._Default.OnLoad(EventArgs e)
       at System.Web.UI.Control.LoadRecursive()
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
       --- End of inner exception stack trace ---
       at System.Web.UI.Page.HandleError(Exception e)
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
       at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
       at System.Web.UI.Page.ProcessRequest()
       at System.Web.UI.Page.ProcessRequest(HttpContext context)
       at ASP.default_aspx.ProcessRequest(HttpContext context)
       at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
       at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    Microsoft.Exchange.Management.ControlPanel.UrlNotFoundOrNoAccessException: The page may not be available or you might not have permission to open the page. Please contact your administrator for the required credentials. For new credentials to take effect, you
    have to close this window and log on again.
       at Microsoft.Exchange.Management.ControlPanel._Default.CreateNavTree()
       at Microsoft.Exchange.Management.ControlPanel._Default.OnLoad(EventArgs e)
       at System.Web.UI.Control.LoadRecursive()
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    I then had a look at the IIS permissions for ecp and owa. The account did not have permissions so I added them there but still got the same error. I’ve also tried all of the above with a newly-created account but still got the same issue.
    Any ideas as to what the above event log is specifically referring to?

    Hi,
    From your description, I would like to clarify the following thing:
    If you want to search message tracking logs, the account you use should be a member of the role groups below:
    Organization Management role group, Records Management role group, Recipient Management role group.
    Hope this can be helpful to you.
    Best regards,
    Amy Wang
    TechNet Community Support

  • I did the iTunes update and now I am getting a Windows error 126 message.

    I did the iTunes update and now I am getting a Windows error 126 message. Now I can't use iTunes at all. Any ideas?

    Click here and follow the instructions. You may need to completely remove and reinstall iTunes and all related components, or run the process multiple times; this won't normally affect its library, but that should be backed up anyway.
    (99606)

  • Just installed Firefox 3.6. Firefox will not start and Firefox safemode does not start either. Using Task manager I do not see if started either. If I create a new profile and start from that window, Firefox starts up. I see no error windows/messages. I d

    Just installed Firefox 3.6. Firefox will not start and Firefox safemode does not start either. Using Task manager I do not see if started either. If I create a new profile and start from that window, Firefox starts up. I see no error windows/messages. I do have it listed in my Firewall as an exception program with Permit All. What is happening?
    == This happened ==
    Every time Firefox opened
    == After removing Firefox and Reinstalling it. ==
    == User Agent ==
    Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; GTB6.4; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.04506.648; MS-RTC LM 8)

    If that new profile works then you can transfer some files from the old profile to that new profile (be careful not to copy corrupted files)
    See http://kb.mozillazine.org/Transferring_data_to_a_new_profile_-_Firefox
    See also [[Basic Troubleshooting|#Make_a_new_profile|Basic Troubleshooting: Make a new profile]]

Maybe you are looking for