Asynchronous page loading
-
Hi, I have a web form (aspx) with some controls that take long time to load. This is because they gather information from other systems on our network. Today the whole page will wait for these controls to be finished before anything is sent to the client. Is it possible to change this behavior easily? I have installing the AJAX Extensions and AJAX Toolkit. Using the UpdatePanel i can refresh the components without reloading and waiting for the whole page, but it still takes a long time to load the page the first time. Can someone come up with any good ideas?
-
Hi, I have a web form (aspx) with some controls that take long time to load. This is because they gather information from other systems on our network. Today the whole page will wait for these controls to be finished before anything is sent to the client. Is it possible to change this behavior easily? I have installing the AJAX Extensions and AJAX Toolkit. Using the UpdatePanel i can refresh the components without reloading and waiting for the whole page, but it still takes a long time to load the page the first time. Can someone come up with any good ideas?
I don't think there is an easy way to do this, when you have databases which are quite big and are spread out throughout your system it will make the app run slightly slower. You will have to load all controls on the page for the first time anyway and the server request has to happen. Maybe look at trimming down your app in other ways e.g. if you have images reduce the size, try and move any of your databases closer together on the system or shrink down if possible. hope any of that helps! :)
-
I don't think there is an easy way to do this, when you have databases which are quite big and are spread out throughout your system it will make the app run slightly slower. You will have to load all controls on the page for the first time anyway and the server request has to happen. Maybe look at trimming down your app in other ways e.g. if you have images reduce the size, try and move any of your databases closer together on the system or shrink down if possible. hope any of that helps! :)
Stubborn as I am, I found a solution. If you want to try it I will give you a brief description of the setup. I have an UpdatePanel with the slow-loading content. Set Visible = false on the slow-loading content and make sure that it's not visible and that page is loading fast. If you have trouble making the content invisible, or if it consists of several components, put the content on a Panel and make the Panel invisible. Add a second UpdatePanel with an AJAX timer. Set Interval = 1 on the timer. Add a Tick event handler to the timer that sets the Interval to a higher value or disable the timer all together if you don't want to update the content regularly. Also make the slow-loading content visible. Your page will load and will immediately trigger an update which will force the slow-loading content to load asynchronously.
-
Stubborn as I am, I found a solution. If you want to try it I will give you a brief description of the setup. I have an UpdatePanel with the slow-loading content. Set Visible = false on the slow-loading content and make sure that it's not visible and that page is loading fast. If you have trouble making the content invisible, or if it consists of several components, put the content on a Panel and make the Panel invisible. Add a second UpdatePanel with an AJAX timer. Set Interval = 1 on the timer. Add a Tick event handler to the timer that sets the Interval to a higher value or disable the timer all together if you don't want to update the content regularly. Also make the slow-loading content visible. Your page will load and will immediately trigger an update which will force the slow-loading content to load asynchronously.