4 Replies Latest reply on Apr 15, 2008 6:11 AM by Ilya Shaikovsky

    a4j:status onstop wont work if reRendered

    ff fff Newbie

      My status component is nested in an a4j:outputPanel, if that panel gets reRendered, the onstop javascript function wont be called.

      How do i get around this?

      Is there a possebility to create a part of a page that is never reRendered
      and put the status component in it?.

      Or do i have to split my outputPanel into separate panels and only reRender them(would be a lot of extra work - if want to get around this -if possible)

      Thx a lot,

      Bye,
      Holger

        • 1. Re: a4j:status onstop wont work if reRendered
          ff fff Newbie

          To make it more comprehensive he some example code:

          <!-- onstop works -->
          <a4j:status id="waitStatus2" forceId="true"
           onstart="startShowWaitStatusCursor();"
           onstop="stopShowWaitStatusCursor();">
          </a4j:status>
          
          <!-- onstop dont work when status component rerendere -->
          <a4j:outputPanel id="updatePanel">
           <a4j:status id="waitStatus" forceId="true"
           onstart="startShowWaitStatusCursor();"
           onstop="stopShowWaitStatusCursor();">
           </a4j:status>
          </a4j:outputPanel>
          
          <h:form>
           <a4j:commanLink value="update status1" reRender="updatePanel" status="waitStatus"/>
           <a4j:commanLink value="update status2" reRender="nothing" status="waitStatus"/>
          </h:form>
          
          


          Any solution for this?

          Bye,
          Holger

          • 2. Re: a4j:status onstop wont work if reRendered
            Ilya Shaikovsky Master

            explain why do you need to reRender status component which is updated itself after request start/complete?

            After you replace the status element on the page - event onstop of the new object will never fired because it knows nothing about event start and do not observe nothing.

            • 3. Re: a4j:status onstop wont work if reRendered
              ff fff Newbie

               


              explain why do you need to reRender status component which is updated itself after request start/complete?


              I dont need to reRender status component, in fact(as i wrote...) i want to prevent that the status component gets reRendered.

              Unfortunately the status component is in the same panel like the one that gets updatet.Moving the status outside that panel is not(easy) possible.

              I also dont want to split my big panel into small panels only becourse that the status component is outside....

              sth like <a4j:region ajaxRegion="false" /> that would prevent reRender a part of the page at all costs would be a solution but i guess sth like that doent exist.

              Thx anyway,

              Bye,
              Holger



              • 4. Re: a4j:status onstop wont work if reRendered
                Ilya Shaikovsky Master

                no, we provide just two possibility for this case - you should move it out or reRender concrete components instead of the whole panel.