延迟加载用户控件 - ASP.NET

时间:2023-01-16 09:30:01

I am using the lazy load approach for loading the user control content by using the timer method outlined here:

我使用延迟加载方法通过使用此处概述的计时器方法加载用户控件内容:

http://johanleino.wordpress.com/2009/06/15/lazy-loading-ascx-usercontrol-or-something-else-at-loadtime/

http://johanleino.wordpress.com/2009/06/15/lazy-loading-ascx-usercontrol-or-something-else-at-loadtime/

It works great when there's only one user control, but when there are multiple ones, it first renders the page, then renders the User control 1 and waits for the timer click event to be completed before it gets to the User control 2's timer click.

当只有一个用户控件时,它工作得很好,但是当有多个用户控件时,它首先呈现页面,然后呈现用户控件1并等待定时器点击事件在完成用户控件2的计时器点击之前完成。

I want more of a async call approach where the timer events of all user controls are independently fired instead one after the other (it appears that this is possible in portals like dropthings or pageflakes that dont use client side ajax methods)

我想要更多的异步调用方法,其中所有用户控件的计时器事件是一个接一个地独立触发(似乎这可能在门户网站中,如不使用客户端ajax方法的dropthings或pageflakes)

Is this possible? Any help is really appreciated.

这可能吗?任何帮助都非常感谢。

2 个解决方案

#1


1  

a friend did something similar for some usercontrols that took very long to render; check here: http://ivowiblo.wordpress.com/2010/06/02/asp-net-webforms-lazypanel-deferred-content-loading-in-webforms/

一位朋友做了类似的事情,因为一些用户控件需要很长时间才能呈现;点击此处:http://ivowiblo.wordpress.com/2010/06/02/asp-net-webforms-lazypanel-deferred-content-loading-in-webforms/

hope it helps

希望能帮助到你

#2


0  

Check this out: http://encosia.com/2007/09/19/aspnet-ajax-timer-trouble-location-is-key/

看看这个:http://encosia.com/2007/09/19/aspnet-ajax-timer-trouble-location-is-key/

and look at the "pop quiz" at the end and the comment by Maurice.

并看看最后的“流行测验”和莫里斯的评论。

#1


1  

a friend did something similar for some usercontrols that took very long to render; check here: http://ivowiblo.wordpress.com/2010/06/02/asp-net-webforms-lazypanel-deferred-content-loading-in-webforms/

一位朋友做了类似的事情,因为一些用户控件需要很长时间才能呈现;点击此处:http://ivowiblo.wordpress.com/2010/06/02/asp-net-webforms-lazypanel-deferred-content-loading-in-webforms/

hope it helps

希望能帮助到你

#2


0  

Check this out: http://encosia.com/2007/09/19/aspnet-ajax-timer-trouble-location-is-key/

看看这个:http://encosia.com/2007/09/19/aspnet-ajax-timer-trouble-location-is-key/

and look at the "pop quiz" at the end and the comment by Maurice.

并看看最后的“流行测验”和莫里斯的评论。