How can I put a message in a page after an action in another page?

Hi everybody, I know that what I try to explain is a bit difficult to understand without know all the context but I try to do it the same:). I have a datatable that contains a list of student. In another page I insert a new student. When I click on "save" button I save the new student and I return to the page with the datatable. The problem is: when I add a student I must notify the user that the student is added correctly with a message in the 1st page like "The student is added correctly". This message must display only after I added the student not when I see for the first time the page with the datatable. How can i do this? Thanks to all.

I use your suggestion but it doesn't work. I create a bean named MessageHandler with scope request. In its constructor i put an empty value for the variable addStudent_message, and in the page that the message should be I have this line of code:
<h:outputText rendered="#{!empty messageHandler.addStudent_message}" value="#{messageHandler.addStudent_message}"/>
In the bean I used to add a student I have a MessageHandler object and in the method that add a student, before the return statement, I put this:
handler.setAddStudent_message("Studente aggiunto correttamente");
When I run, it gives me this error:
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
javax.servlet.ServletException: Error calling action method of component with id _idJsp1:save
     javax.faces.webapp.FacesServlet.service(FacesServlet.java:152)
root cause
javax.faces.FacesException: Error calling action method of component with id _idJsp1:save
     org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
     javax.faces.component.UICommand.broadcast(UICommand.java:106)
     javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
     javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
     org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343)
     org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
     javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
root cause
javax.faces.el.EvaluationException: Exception while invoking expression #{addStudentBean.save}
     org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:153)
     org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63)
     javax.faces.component.UICommand.broadcast(UICommand.java:106)
     javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
     javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
     org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343)
     org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
     javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
root cause
java.lang.NullPointerException
     beanDomain.AddStudentBean.save(AddStudentBean.java:68)
     sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     java.lang.reflect.Method.invoke(Method.java:585)
     org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:129)
     org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63)
     javax.faces.component.UICommand.broadcast(UICommand.java:106)
     javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:94)
     javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:168)
     org.apache.myfaces.lifecycle.LifecycleImpl.invokeApplication(LifecycleImpl.java:343)
     org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:86)
     javax.faces.webapp.FacesServlet.service(FacesServlet.java:137)
note The full stack trace of the root cause is available in the Apache Tomcat/5.5.23 logs.
It seems that it doesn't find the MessageHandler object. What do you think?

Similar Messages

  • How can I put my podcasts in one place and my music in another?

    How can I put my playlists on my NAS media server (Buffalo Linkstation mini) so I can access them through Home Sharing and Sonos?  FYI, right now I run my iTunes with media location on my laptop's c: drive so I can manage podcasts while on the go and map a lettered network drive to the media server device when I connect up at home.

    Duplicated: https://support.mozilla.com/en-US/questions/886179

  • How can I put the image fixed on the bottom-left of the HTML page

    I can't put the image at the left-bottom of my div id="content". I have "textcontent" (float:left) and "sidebar" (float:right) inside the content. I am attaching my code here for your review. Please help!
    HTML:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Interior and Exterior</title>
    <link href="main.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript">
    function MM_swapImgRestore() { //v3.0
      var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
    function MM_preloadImages() { //v3.0
      var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
        var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
        if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
    function MM_findObj(n, d) { //v4.01
      var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
        d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
      if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
      for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
      if(!x && d.getElementById) x=d.getElementById(n); return x;
    function MM_swapImage() { //v3.0
      var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
       if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
    </script>
    </head>
    <body onload="MM_preloadImages('images/rollover_home.jpg','images/menu_home_over.png','images/m enu_paint_over.png','images/menu_contractor_over.png')">
    <div id="container">
      <div id="header">
      <div id="contactinfo">contact us for free estimates  250-878-1786</div>
    <div id="logo"><a href="index.html"><img src="images/logo.png" width="276" height="53" /></a></div>
    <div id="topmenu">
    <ul>
    <li><a href="index.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('home','','images/menu_home_over.png',1)"><img src="images/menu_home.png" name="home" width="119" height="54" border="0" id="home" /></a></li>
    <li><img src="images/menu_interior_over.png" width="177" height="54" /></li>
    <li><a href="paint_design.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('paint','','images/menu_paint_over.png',1)"><img src="images/menu_paint.png" name="paint" width="172" height="54" border="0" id="paint" /></a></li>
    <li><a href="contractor_trades.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('contractor','','images/menu_contractor_over.png',1)"><img src="images/menu_contractor.png" name="contractor" width="166" height="54" border="0" id="contractor" /></a></li>
    </ul>
    </div>
      </div>
    <div id="content"><h1><img src="images/page_name_interior.png" width="286" height="27" /></h1>
    <div id="textcontent">
    <h2>Interior Services:</h2>
    <p> </p>
    <h3>Painting and staining:</h3>
    <table width="300" border="0">
      <tr>
        <td width="100">doors</td>
        <td width="100">walls</td>
        <td width="100">ceilings</td>
      </tr>
      <tr>
        <td>baseboards</td>
        <td>trim</td>
        <td>cabinets</td>
      </tr>
      <tr>
        <td>banisters</td>
        <td>rails</td>
        <td></td>
      </tr>
    </table>
    <p> </p>
    <h3>Fill and seal:</h3>
    <table width="300" border="0">
      <tr>
        <td width="100">cracks</td>
        <td width="100">baseboards</td>
        <td width="100">trim</td>
      </tr>
      <tr>
        <td>holes</td>
        <td>drywall repair</td>
        <td>cabinets</td>
      </tr>
    </table>
    <p> </p>
    <h3>Wallpaper and boarder removal</h3>
    <br />
    <p>No interior job is complete unless all the holes, nicks and gaps are filled and sealed.  I guarentee you'll be happy with the quality of our workmanship.</p>
    <p> </p>
    <h2>Exterior Services:</h2>
    <p> </p>
    <h3>Painting and staining:</h3>
    <table width="400" border="0">
      <tr>
        <td width="100">trim</td>
        <td width="100">posts</td>
        <td width="100">beams</td>
        <td width="100">hardiboard</td>
      </tr>
      <tr>
        <td>smartboard</td>
        <td>gables</td>
        <td>facia</td>
        <td>shakes</td>
      </tr>
      <tr>
        <td>shadowboard</td>
        <td>belly-board</td>
        <td>stucco</td>
      </tr>
    </table>
    <p> </p>
    <h3>Decks and rails:</h3>
    <table width="150" border="0">
      <tr>
        <td width="144">staining and painting</td>
    </tr>
    </table>
    <p> </p>
    <h3>Power washing:</h3>
    <table width="180" border="0">
      <tr>
        <td width="174">houses, fences and decks</td>
    </tr>
    </table>
    <p> </p>
    <p> </p>
    <h3>All nail holes are filled and all joints filled and sealed on all exterior painting projects.</h3>
    <p> </p>
    <h3>Stucco homes can be repainted quickly and inexpensively!</h3>
    </div>
    <div id="sidebar">
      <img src="images/interior_house.png" width="514" height="329" /><br />
      <a href="testimonial.html"><img style="padding-left: 40px; padding-top: 30px" src="images/interior_testimony.png" width="362" height="289" /></a></div>
    <p><img src="images/exterior_specialists.png" width="322" height="56" /></p>
      </div>
    <div id="footer"><img src="images/interior_footer.png" width="962" height="50" /></div>
    </div>
    </body>
    </html>

    Working with CSS Backgrounds:
    http://www.w3schools.com/css/css_background.asp
    #content {
         background-image:url('some-img.png');
         background-repeat: no-repeat;
         background-position: left bottom;
         min-height: 500px; /**same as image height**/
         overflow:hidden; /**float containment**/
    HTML
    <div id="content">
    the rest of page content goes here>>>
    </div>
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists 
    http://alt-web.com/

  • How can i put a tracker on my phone after i lost it

    i had lost my phone and i dont have a tracker on it is there any way i can put a tracker on my phone while its lost to find it

    No. You have to download and enable "Find My iPhone", set up iCloud, turn Find My iPhone on in iCloud, set up Find My iPhone on you computer, or go to icloud.com to access it. The phone or device has to have a Wifi connection to be seen. If it has been wiped by the thief or thieves, then you would not be able to see or manipulate it anymore.
    If you do not have Find My iPhone and iCloud and everything set up ahead of time, then you can't do anything period.
    GB

  • How can I get a webpage to load dialogs after mistakenly clicking "prevent this page from creating additional dialogs"?

    I still need to be able to have dialogs load with the webpage. I am not able to see any images on this webpage since clicking this button by mistake. Clearing the cache does not address the problem; Re-creating my profile does not correct the problem. Firefox needs to address this issue as it is happening to too many web apps.

    If the slide show is the part not working, I believe that is a Flash slide show. There are some compatibility issues between the latest Flash player and some Firefox add-ons or settings. Could you see whether anything in this article helps: [[Flash 11.3 doesn't load video in Firefox]].

  • How to return to the same PLACE on a page after you link to another page

    If you are on a long page that contains links, if you click on the link, go to the new page, read, then return to the first page, you are dropped at the top of the page, not where you left from as FF3.* did. It matters because some pages I use have hundreds of links and I have to hunt to find where I was so that I continue my process.

    It took me a while to find out. This issue has nothing to do with Firefox 8, I think. It is the way Google handles the page with your search results.
    In the top right corner of your Google home page click the settings button and change the search settings "Google Instant predictions" to OFF. Then hit SAVE and you will be able to go back to same scroll position of your Google search results page. Hope that helps !!!

  • Hi I've got a I phone 5 c how can I put my number for I message instead ov email

    HI I have a I phone5 c how can I put number for I message instead of e mail

    It is there - at the bottom below the section - you can be reached by iMessage at.
    The iPhone's cell phone number is automatically registered with iMessage along with your Apple ID email address.

  • I bought a used i pod 4 for my daughter and it does not have the message icon on it: how can i put the icon on the i pod and get it receive and send messages

    I bought a used i pod 4 for my daughter and it does not have the message icon on it ( not even in settings) how can I get the message icon on it so it can receive and send messages

    Try:
    - Reset the iOS device. Nothing will be lost
    Reset iOS device: Hold down the On/Off button and the Home button at the same time for at
    least ten seconds, until the Apple logo appears.
    - Reset all settings
    Go to Settings > General > Reset and tap Reset All Settings.
    All your preferences and settings are reset. Information (such as contacts and calendars) and media (such as songs and videos) aren’t affected.
    - Restore from backup. See:       
    iOS: How to back up
    - Restore to factory settings/new iOS device.
    -  Make an appointment at the Genius Bar of an Apple store.
    Apple Retail Store - Genius Bar

  • How can I put my icloud photos to camera roll or photo stream?

    I got a nee iphone, i backed up everything and restored it into mu new iphone, but the pictures didn't restore so i did it manually but now on my phone i got different albums icloud photo stream and camera roll. How can i put the icloud picture into camera roll or photo stream. Any ideas?? On my old iphone ive deleted everything.

    Hello Ozzie94,
    Thanks for the additional information. The camera roll is designed for photos taken on your device, or saved images from Mail and other applications. Photos synced from a computer are organized into their own album(s):
    View photos and videos - iPhone
    http://help.apple.com/iphone/7/#/iph3d267610
    - Camera Roll—photos and videos you took on iPhone, or saved from an email, text message, webpage, or screenshot
    - Shared photos and videos—Photos and videos that you’ve shared with iCloud Photo Sharing or that others have shared with you (see iCloud Photo Sharing)
    - Photos and videos synced from your computer (see Sync with iTunes)
    Additionally, you may find more information by using another one of Apple's support resources - https://getsupport.apple.com
    Thanks,
    Matt M.

  • How can I put a movie on my ipod without deleting other movies?

    I have a movie (and extras) on my ipod nano that I downloaded years ago and placed my ipod. Unfortunately, that computer crashed and I no longer have the computer.
    I recently downloaded a digital copy of a movie that came with the DVD I bought on my new computer. When I tried to put this movie on my ipod, I received a message saying that in order to do this, I would have to link my ipod to this itunes library on my computer and it would delete my old movie. I don't want this happen so how can I put my new movie on my ipod without deleting my old movie (and extras)?
    (Also, I have no idea if this will be necessary information, but I want to give all the information for this question...the e-mail address I used to download the 1st movie is no longer in use due to security reasons. I've been using a new e-mail that has worked fine for downloading music and my new movie.)
    I hope someone can help me!
    Thank you in advance.

    Are you sure you have enough space on the ipod for the new movie? If you do, make sure it's loaded in i-tunes, and it's check box is checked, then click sync, or apply, and everything should load.

  • How can I put a parenthesis around the number?

    Hi expert people!!!
    One question:  How can I put a parenthesis around the number because I have this
    write:   /123 t_bsid-pago1, 141 t_bsid-pago2,
              157 t_bsid-pago3, 175 t_bsid-pago4,
              193 t_bsid-pago5.
    and if I put the parenthesis hardcoded like this:
    write:   /123 '(', t_bsid-pago1,')'.
    when the variable are printed the parenthesis is write very separated from the amount.
    I know that maybe I can use the CONDENSE or CONCATENATE statement but for that I need to create a variable type N, or STRING and if I do that I don't know how can I put the decimals points back.
    Thanks!!

    Hi Carlos,
    Try this:
    REPORT  ZTESTRAJ.
    data: v_val(10) type p decimals 2 value '123456.75',
          v_text type string.
    start-of-selection.
      write:/ v_val.
      v_text = v_val.
      concatenate '(' v_text ')' into v_text.
      condense v_text no-gaps.
      write:/ v_text.
    <b>Output:</b>
    test program...      
    123,456.75 
    <b>(123456.75)</b>          
    Regards,
    Raj
    Message was edited by: Rajasekhar Dinavahi

  • How can i put a "/" or "\" in a file name with filewriter?????

    hi there
    how can i put "/" or "\" in a file name? i am using filewriter to create file, here is my code
    String fileName = year+"\\"+month+"\\"+date+":"+hour+":"+minute+":"+second+FILE_EXTENSION;
    fw = new FileWriter("users"+"/"+userDirectory+"/"+OUTPATH+"/"+fileName, false);
    i keep getting error message :"invalid file name, path, directory...", i want to have the following format in my file name: yyyy/mm/dd:hh:mm:ss.txt,
    do you know how to get date and time in this format: ie. March 10, 2002 14:01:32, or something like this?
    thank you

    You are using invalid characters in you name. For example,
    : - is used to separate the drive from the path
    / - is used to separate directories
    therefore they can't be used in the filename.
    Open an editor and try creating a file using the format you want and see if the editor can save it, before attempting to do it in Java.

  • As a grand parent, how can I put some apps on an ipod touch and then give it as a gift?

    As a grand parent, how can I put some apps on an ipod touch and then give it as a gift?

    Apps and many other purchases are tied to the iTunes Store account via which they were purchased. So if you buy the app, that app is tied to your iTunes Store account. Without that account information, the child could not update the app nor back it up.
    I'd also suggest giving the child an iTunes gift card or gift certificate along with the iPod. If the child is too young to have and manage his or her own iTunes Store account, then his or her parent could set up an iTunes Store account to purchase the apps. That could be done with that gift card and not need a credit card. You can also gift specific apps, though again that would require the child or a parent to open an iTunes Store account through which to redeem the gift. For more information on gift options, see:
    http://support.apple.com/kb/HT2736
    Regards.
    Message was edited by: Dave Sawyer

  • How can i put my own text sound

    i need help, how can you put my own text message sound in my iphone....p.s i'm new the the apple family

    Welcome to the family. Tell your Uncle Steve you would like custom text tones: http://www.apple.com/feedback/iphone.html

  • How can I put text in transparent background?

    How can I put text in transparent background?
    Message title was edited by: Brett N

    Good day!
    You can create a new document (»Background Contents« set to »Transparent«), use the Type Tool (T) to create text and then save in a format that supports layers like psd, psb, tif.
    If the receiving application can’t handle those png24 is another option.
    Regards,
    Pfaffenbichler

Maybe you are looking for

  • MSI 6800 pci e/ 3D Mark

    I have two 6800 pci e in the Asus SLI system shown in sig.  I am unable to have 3D Mark benches recognize the cards.  Is there some way to have them recognized.  This is not the case with other pci e cards I have.

  • ITunes not connecting to AirTunes remote speakers after upgrade to 7.6.1

    Hi I've just noticed that iTunes is refusing to connect to my AirPort Express. Or rather, it's ignoring me when I ask it to connect; it's as if I didn't select the remote speakers at all. It is displaying them in the remote speakers menu, and allowin

  • How to get previous step totals from Apple Health

    Is there a way (natively or via 3rd party app) to isolate step totals from previous days in Apple Health?  All I can find is the weekly view, which won't let you zoom in.  The daily view will not let you view anything but the current day. I've tried

  • Need help with the color options on my new mac monitor!

    Ok, so I just bought a new Apple 23" monitor. I had originally bought a Samsung 21" and tried desperately to get the picture quality on the samsung to look like the quality of my macbook. I messed with calibration settings to no luck. After a few mon

  • When streaming movies from itunes, I get an error that there is not enough storage

    I stream a movie for my kids and the ipad says that there is not enough storage available. I can stream from Vudu and Netflix with no issues. When I started streaming from itunes, I cannot due to this error. Still learning iOS, any help would be grea