473,411 Members | 2,289 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,411 software developers and data experts.

fragment caching problem

Joe
I have a custom control that generates client scripts and uses viewstate
This control is placed in a user control that is placed in my application pages
When I use OutputCache directive in the ascx (so that the control will not be generated each time), the client script and viewstate data of the custom control is not rendered, and this causes errors when using the page

What's the way to solve this problem
TIA
Jo
Nov 18 '05 #1
1 986
If you registered the JS by calling the parent page like this:
control.Page.RegisterClientScript etc..

Don't expect that the script will be there for you when it is loaded from
the cache since the code is never executed.

What you can do is put the script tag in the ASCX file itself.


"Joe" <an*******@discussions.microsoft.com> wrote in message
news:8C**********************************@microsof t.com...
I have a custom control that generates client scripts and uses viewstate.
This control is placed in a user control that is placed in my application pages. When I use OutputCache directive in the ascx (so that the control will not be generated each time), the client script and viewstate data of the custom
control is not rendered, and this causes errors when using the page.
What's the way to solve this problem?
TIA,
Joe

Nov 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Troy Simpson | last post by:
Hi, I have a website which is made up of dynamic pages. Each page that's loaded has some code which looks at which template to load amongst other things, which causes the page to take a little...
3
by: DC | last post by:
Hi, (ASP.Net 1.1) is it possible to (programmatically and globally) deactivate page fragment caching? We have only two scenarios, development stage where we want caching off and testing where we...
0
by: Ed | last post by:
Hi all, Have a strange situation regarding fragment caching. I've read the docs and kbs on this so it's either I've missed some key aspect of the implementation or there is a "gotcha" here that...
0
by: Ben Fidge | last post by:
I'm trying to use ASP.NET 2.0's Menu control in a UserControl with fragment cahcing but it doesn't work. This UserControl and menu combination make up my sites left hand navigation and is database...
0
by: Jens | last post by:
Hello, I've created a user control with fragment caching: <%@ OutputCache Duration="43200" VaryByParam="none" %> <% =now() %> In my local environment (PC with Visual Webdeveloper 2005) the...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.