473,785 Members | 2,434 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

removing viewstate from serialized state in page?

I heard somewhere that in at least ASP.NET 2.0 you can remove the serialized
view state from a page and have it stored locally in SQL server ot the
ASP.NET state server service? so it doesnt transfer all that view state
information with each page (which sometimes is HUGE)... anyone have any
documents on this or tutorials? thanks!
Dec 30 '06 #1
2 1650
The Page object exposes two function, SavePageStateTo PersistenceMedi um and
LoadPageStateFr omPersistenceMe dium which are meant to let you override the
default behaviour. There are a bunch of examples online, for example
http://www.codeproject.com/aspnet/ViewStateProvider.asp which creates an
entire provider model for greatest flexibility.

Karl

--
http://www.openmymind.net/
http://www.codebetter.com/
"Smokey Grindel" <no****@nospam. comwrote in message
news:OQ******** ******@TK2MSFTN GP02.phx.gbl...
>I heard somewhere that in at least ASP.NET 2.0 you can remove the
serialized view state from a page and have it stored locally in SQL server
ot the ASP.NET state server service? so it doesnt transfer all that view
state information with each page (which sometimes is HUGE)... anyone have
any documents on this or tutorials? thanks!
Dec 30 '06 #2
awesome, thanks a lot!

"Karl Seguin" <ka********@rem oveopenmymindre movemetoo.andme netwrote in
message news:eY******** *****@TK2MSFTNG P06.phx.gbl...
The Page object exposes two function, SavePageStateTo PersistenceMedi um
and LoadPageStateFr omPersistenceMe dium which are meant to let you override
the default behaviour. There are a bunch of examples online, for example
http://www.codeproject.com/aspnet/ViewStateProvider.asp which creates an
entire provider model for greatest flexibility.

Karl

--
http://www.openmymind.net/
http://www.codebetter.com/
"Smokey Grindel" <no****@nospam. comwrote in message
news:OQ******** ******@TK2MSFTN GP02.phx.gbl...
>>I heard somewhere that in at least ASP.NET 2.0 you can remove the
serialized view state from a page and have it stored locally in SQL server
ot the ASP.NET state server service? so it doesnt transfer all that view
state information with each page (which sometimes is HUGE)... anyone have
any documents on this or tutorials? thanks!

Dec 30 '06 #3

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

Similar topics

6
7023
by: Robin Bonin | last post by:
In my user contol I am creating a set of dropdownlists. Each list is created based on input from the other lists. The problem I am having is setting the selected index on the lists. If someone changes box1, I want to set the selected index in box2 = 0. When I do this, I dont get an error, but when the page loads, it still has the selected value and not 0. It seems that it is getting the selected value from the viewstate
5
1653
by: Craig Buchanan | last post by:
I'm using a viewstate key/value to store a serialized instance of a class. If I redirect to another aspx page, the viewstate is lost. Is this the intended behavior of the viewstate? Is there a work around? Cookies, I suppose. Thanks, Craig Buchanan
4
8072
by: dm_dal | last post by:
Is there a know issue surrounding the CheckBoxList control and it's viewstate? When my control is created, it's ListItems are checked as needed, but on a postback, they loose their Selected status. David
2
7991
by: ce | last post by:
Being a newbie regarding serialization and memorystreams, I was trying to see if i could improve page performance (avoiding going to the db on a postback) by saving my serialized business object in viewstate and getting it back from the client on a postback. But the last line of the sample code below throws a "Stream was not readable" error when i'm trying to get the serialized object back out of the viewstate and memorystream. Any...
9
1872
by: Mark Broadbent | last post by:
Been a while since I've touched asp.net but one thing that always seems to fustrate me is the loss of state on variable declarations. Is there anyway (i.e. assigning an attribute etc) to instruct the server to remember a variables state *without* having to go through the rigmarole of saving and loading to and from the Session state manually or similar workaround for any Types (including custom types) in exactly the same way web controls...
10
1816
by: Steve Richter | last post by:
I have some potentially large objects I would like to store in the viewstate of a user control. Large as in an entire email message. Is ViewState not the sort of place to store such an object? I think my question and concern depends on what asp.net does with the view state when the page is written to the browser. Is the entire viewstate contents written to the browser as a hidden field? Or are the view state contents stored on the...
7
2143
by: GS | last post by:
Hello, I'm receiving The state information is invalid for this page and might be corrupted error message when running code below. This happens on second post back. Why is it happening? My webpage contains 2 dropdowns controls and I save information entered by user in ViewState variable containing array ArrayList MyCoordinates = (ArrayList) ViewState ; if (MyCoordinates == null) { MyCoordinates = new ArrayList ();
0
1076
by: madani | last post by:
Hi, I need to get serialized string of Page ViewState in Constructor of my custom web control. I can not override SavePageStateToPersistenceMedium Method of page object because I'm in different class. and Page.ViewState is not serializable. Is there any way to get serialized string of ViewState without overriding SavePageStateToPersistenceMedium ?
12
1928
by: Nick C | last post by:
Hi How can i reduce the viewstate for my asp.net application. It is getting very large now. What is a good solution? thanks N
0
9645
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9480
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10325
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10147
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9950
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8972
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5381
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5511
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2879
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.