Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. How to refresh the ASP.Net page after asynchronously updating the contents of page

How to refresh the ASP.Net page after asynchronously updating the contents of page

Scheduled Pinned Locked Moved ASP.NET
csharpcssasp-netwpfwcf
7 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    Paramhans Dubey
    wrote on last edited by
    #1

    Hi All, I am working on a ASP.Net web application wherein I am calling a class method Asynchronously to get the data from data base (using AsyncCallback) on page load. after the completion of this callback method raises an event. I'm handling the event on the asp.net page wherein I'm assigning the datasource to a grid view. Everything is going good except for the page is not getting refreshed after the event is getting fired. I have checked the datasource of the grid is assigned properly but the contents are not shown on the page. Please Note: I'm calling the method Asynchronously so after the event is fired and after assigning the data source to the grid and after data binding it i want to post back the page to the server so that the latest contents of the page are visible on the page. I want to refresh the entire page on that event. Please help its Urgent Thanks and Regards Paramhans

    N 1 Reply Last reply
    0
    • P Paramhans Dubey

      Hi All, I am working on a ASP.Net web application wherein I am calling a class method Asynchronously to get the data from data base (using AsyncCallback) on page load. after the completion of this callback method raises an event. I'm handling the event on the asp.net page wherein I'm assigning the datasource to a grid view. Everything is going good except for the page is not getting refreshed after the event is getting fired. I have checked the datasource of the grid is assigned properly but the contents are not shown on the page. Please Note: I'm calling the method Asynchronously so after the event is fired and after assigning the data source to the grid and after data binding it i want to post back the page to the server so that the latest contents of the page are visible on the page. I want to refresh the entire page on that event. Please help its Urgent Thanks and Regards Paramhans

      N Offline
      N Offline
      Not Active
      wrote on last edited by
      #2

      Paramhans Dubey wrote:

      Please help its Urgent

      Don't be rude. It may be urgent to you but not anyone else here. I think you are little confused about how to process the page. If you want the entire page to refresh with the data then do a postback. If you want to load the data asynchronous then use something like an UpdatePanel or AJAX methods.


      I know the language. I've read a book. - _Madmatt

      P 1 Reply Last reply
      0
      • N Not Active

        Paramhans Dubey wrote:

        Please help its Urgent

        Don't be rude. It may be urgent to you but not anyone else here. I think you are little confused about how to process the page. If you want the entire page to refresh with the data then do a postback. If you want to load the data asynchronous then use something like an UpdatePanel or AJAX methods.


        I know the language. I've read a book. - _Madmatt

        P Offline
        P Offline
        Paramhans Dubey
        wrote on last edited by
        #3

        Mark Nischalke wrote:

        Don't be rude. It may be urgent to you but not anyone else here.

        If asking for help is rudeness then I am sorry for being rude. My question is that is is there any way to post back the entire page to the server without using Update Panel.

        N 1 Reply Last reply
        0
        • P Paramhans Dubey

          Mark Nischalke wrote:

          Don't be rude. It may be urgent to you but not anyone else here.

          If asking for help is rudeness then I am sorry for being rude. My question is that is is there any way to post back the entire page to the server without using Update Panel.

          N Offline
          N Offline
          Not Active
          wrote on last edited by
          #4

          Paramhans Dubey wrote:

          If asking for help is rudeness

          Asking for help is not rude. Asking an URGENT response is.

          Paramhans Dubey wrote:

          is there any way to post back the entire page to the server without using Update Panel.

          :rolleyes: Yes, of course there is, that is how ASP.NET works. Perhaps you need to restate your question.


          I know the language. I've read a book. - _Madmatt

          P 1 Reply Last reply
          0
          • N Not Active

            Paramhans Dubey wrote:

            If asking for help is rudeness

            Asking for help is not rude. Asking an URGENT response is.

            Paramhans Dubey wrote:

            is there any way to post back the entire page to the server without using Update Panel.

            :rolleyes: Yes, of course there is, that is how ASP.NET works. Perhaps you need to restate your question.


            I know the language. I've read a book. - _Madmatt

            P Offline
            P Offline
            Paramhans Dubey
            wrote on last edited by
            #5

            Mark Nischalke wrote:

            Asking for help is not rude. Asking an URGENT response is.

            let's finish this here. I apologize for being rude. and also i restate my question: I have a long running procedure which takes approx. 1 mins to complete. I am calling the method using a delegate and ICallBack. When my process completes the it raises an event which is handled on UI wherein I am assigning the datasource to grid but as this is a asynchronous update the updates are not visible on the Page. I cant use Update panel in my project. My question is that is is there any way to post back the page to the server without using Update Panel after asynchronously updating the page to show the updated contents.

            N C 2 Replies Last reply
            0
            • P Paramhans Dubey

              Mark Nischalke wrote:

              Asking for help is not rude. Asking an URGENT response is.

              let's finish this here. I apologize for being rude. and also i restate my question: I have a long running procedure which takes approx. 1 mins to complete. I am calling the method using a delegate and ICallBack. When my process completes the it raises an event which is handled on UI wherein I am assigning the datasource to grid but as this is a asynchronous update the updates are not visible on the Page. I cant use Update panel in my project. My question is that is is there any way to post back the page to the server without using Update Panel after asynchronously updating the page to show the updated contents.

              N Offline
              N Offline
              Not Active
              wrote on last edited by
              #6

              You can cause a postback from JavaScript, plenty of examples for that. However, what will you gain? You will postback, causing the grid to rebind, causing your callback to launch, causing you to enter an infinite loop. What you need to do is parse the data on the client, something like this, http://msdn.microsoft.com/en-us/magazine/ee309508.aspx[^]. Is there a valid reason to not use UpdatePanel?


              I know the language. I've read a book. - _Madmatt

              1 Reply Last reply
              0
              • P Paramhans Dubey

                Mark Nischalke wrote:

                Asking for help is not rude. Asking an URGENT response is.

                let's finish this here. I apologize for being rude. and also i restate my question: I have a long running procedure which takes approx. 1 mins to complete. I am calling the method using a delegate and ICallBack. When my process completes the it raises an event which is handled on UI wherein I am assigning the datasource to grid but as this is a asynchronous update the updates are not visible on the Page. I cant use Update panel in my project. My question is that is is there any way to post back the page to the server without using Update Panel after asynchronously updating the page to show the updated contents.

                C Offline
                C Offline
                cramteke
                wrote on last edited by
                #7

                keep some hidden button in the page and call button1.click() or __dopostback("","") or this.form[0].submit()

                1 Reply Last reply
                0
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                • Login

                • Don't have an account? Register

                • Login or register to search.
                • First post
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • World
                • Users
                • Groups