CodeVerge.Net Beta


   Explore    Item Entry   Register  Login  
Microsoft News
Asp.Net Forums
IBM Software
Borland Forums
Adobe Forums
Novell Forums

ASP.NET Web Hosting – 3 Months Free!



Zone: > NEWSGROUP > Asp.Net Forum > windows_hosting.hosting_open_forum Tags:
Item Type: NewsGroup Date Entered: 3/22/2004 4:33:52 AM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
(NR, 0)
XPoints: N/A Replies: 1 Views: 27 Favorited: 0 Favorite
Can Reply:  No Members Can Edit: No Online: Yes
2 Items, 1 Pages 1 |< << Go >> >|
John Spurlin
Asp.Net User
Custom Controls where view state may not need enabled.3/22/2004 4:33:52 AM

0/0

I understand that viewstate will preserve a controls "properties". I need clarification on what this means.

I am building custom controls for the first time and from my understanding, viewstate may not be needed for a particular type of control I am using.

One control is a menu (no dhtml) that is xml driven. Another is an Ad rotator control that will manage multiple files at once without displaying any given single add more than once per postback or page load. It is also xml driven.

The controls are set up so that attributes are assigned values

<cc1:menu id="Navigator1" SourceFile="Config/NavMenu01.xml" Runat="server" TransformFile="Transforms/NavMenu01.xslt" EnableViewState="False"></cc1:menu>

<cc1:rotator id="FP_GoldRotator1" runat="server" ImageStyle="RotatorImageStyle" FilterValue="Gold_FrontPage" DataSource="Config/AdRotator.xml" NumberOfItems="4" EnableViewState="False"></cc1:rotator>


I used the IDE to set 'EnableViewState=false'. So my question is, should the viewstate be false with regard to these controls, and if they may have the viewstate turned off or disabled to my benefit, is there a way to have this be a default attribute when I drag the custom control onto a webform from my toolbox?

I am not sure what the benefits pro and contra are in the case of these particular controls.
If I am not learning patterns and practices, I am not harnessing the power of .NET
master4eva
Asp.Net User
Re: Custom Controls where view state may not need enabled.3/22/2004 6:28:19 AM

0/0

You could disable the view state by setting so in the control's constructor:

public class MyControl : Control {
// ...

public MyControl() {
EnableViewState = false;
}
}

-- Justin Lovell
2 Items, 1 Pages 1 |< << Go >> >|


Free Download:

Books:
Pro ASP.NET for SQL Server: High Performance Data Access for Web Developers Authors: Brennan Stehling, Pages: 408, Published: 2007
Professional Web Parts and Custom Controls with ASP.NET 2.0 Authors: Peter Vogel, Pages: 449, Published: 2005
Professional ASP.NET 2.0 Server Control and Component Development Authors: Shahram Khosravi, Pages: 1186, Published: 2006
ASP.NET 1.0 Namespace Reference with VB.NET Authors: Jason Bell, Amit Kalani, Dave Gerding, Matt Milner, John Schenken, Matt Gibbs, Bruce Lee, Andy Elmhorst, Mike Clark, Alex Homer, Pages: 889, Published: 2002
ASP.NET: tips, tutorials, and code Authors: Scott Mitchell, Doug Seven, Stephen Walther, Donny Mack, Billy Anders, Adam Nathan, Dan Wahlin, Pages: 878, Published: 2002
C# Developer's Guide to ASP.NET, XML, and ADO.NET Authors: Jeffrey P. McManus, Chris Kinsman, Pages: 590, Published: 2002
Mastering ASP.NET with C# Authors: A. Russell Jones, Pages: 816, Published: 2002
The Web Application Hacker's Handbook: Discovering and Exploiting Security Flaws Authors: Dafydd Stuttard, Marcus Pinto, Pages: 736, Published: 2008
Fixing Access Annoyances: How to Fix the Most Annoying Things about Your Favorite Database Authors: Phil Mitchell, Evan Callahan, Pages: 357, Published: 2006

Web:
How do I enable ViewState for child custom controls when disabled ... ... turn it off for all of the controls within it, except for the control you need viewstate. ... EDIT: You may want to look at your CreateChildContols() method and enumerate the ... Not the answer you're looking for? Browse other questions tagged asp.net viewstate custom-server-controls or ask your own question. ...
How do I enable ViewState for child custom controls when disabled ... You cannot enable viewstate on a control which is within another control that has ... off for all of the controls within it, except for the control you need viewstate. ... EDIT: You may want to look at your CreateChildContols() method and ... Not the answer you're looking for? Browse other questions tagged asp.net ...
Viewstate Optimization Strategies in ASP.NET - WebReference.com (1/3) Nov 20, 2002 ... Each control defines what it needs to store in its viewstate. ... In cases where the page does not need to post back at all, viewstate can be completely ... purposes the enable viewstate setting of these controls can be ignored. ... One easy way of doing this would be to create a custom control that ...
ASP.NET Custom Server Control - Extend TextBox Control ViewState ... These properties are not stored in ViewState by ASP.NET controls. In your implementation, you will probably want to exclude any of those properties you don't need. .... Enabled = (System.Boolean)newstate[15]; this.ForeColor = ( System. .... ToChar(" "); /* You may choose to implement the next three variables as ...
Speed Up Your Site with Improved View State in ASP.NET 2.0 and C# To see what happens when view state is not enabled, .... thinking about whether your controls need view state to function properly or not, ... currently used for view state which may change before the final release. ... Figure 7 shows a custom control that stores a string in control state (in this case, its color). ...
Viewstate is not maintained for the inner controls if i used ... Nov 27, 2007 ... I am developing a server control which is used as a custom tag ... the child controls to render as visible or enabled based on the ... 4, How to preserve viewstate in my own control during postbacks · ASP. .... it works fine. it may be helpful for other users when they really need this functionality ...
.NET 247 the viewstate for controls that are nested in my Custom Control. I'm really not ... Is there something I need to do with my control to tell it to utilize the viewstate. ... -By default, my textboxes enabled property is set to false, and the ... It seems since some of the viewstate is being reloaded that this may ...
DataGrid empty on Postback with ViewState enabled - ASP.NET Data ... A contributing factor may be the fact that during Page_Init, I mess around with the controls ... subsequent rendering of controls into the HTML stream. That is needed ... Custom DataGridColumn DataGridItems not saving to ViewState. ...
Scott on Writing I need to know where should I load these controls' viewstate and how? ... according to the Trace output, and it's the only control in any of the user controls that has view state enabled.) ..... Different controls may handle ViewState differently. ... Custom Controls e ViewState 1/24/2006 7:49 AM FoxyBlog ...
CodeProject: Your First ASP.NET Custom Control. Free source code ... Aug 23, 2008 ... NET 2 was released, it minimized the need for creating custom controls. ... NET 2.0 were user controls, not custom controls. ... When I was learning to develop some AJAX enabled controls, I found myself dragged again to custom controls ... ViewState round trip management. Simple custom controls vs. ...

Videos:
Powered by YouTube - Design Your Own YouTube Player Speaker: Geoff Stearns The YouTube player APIs allow you to take nearly full control over the YouTube embedded video players. Controls like ...
Please We Have No Regrets -an adventure to the last phish ... Gary Dann's documentary of his adventure to Coventry, VT. to see the last phish concert/festival. This film tells the true story of a horrible ...
A Millenium Celebration in the Everglades - Y2KNYE Big Cypress - New Years Eve 2000 - Phish By 1999, Phish were an American institution. They were considered the biggest concert band in the ...
The End Of The World prophecy. Les prophéties de la fin des ... The world is changing. It is coming to an end as we know it. Captivating video about the end of days. Armageddon Gog u Magog Gog-u-Magog end of ...
Hidabroot Astrologia אסטרולוגיה לפי האסטרולוגיה ולפי מחקרי הגנום האנושי לאחרונה, העתיד נקבע מראש. מהי השקפת היהדות בנושא חשוב זה? האם בידינו להשפיע על עתיד גורלנו? האם בידינו ...
Long Beach City Council Meeting Long Beach City Council Meeting
GeoServer and Architectures of Participation for Geospatial ... Google TechTalks August 23, 2006 Chris Holmes ABSTRACT This talk will introduce GeoServer, an open source server to publish and edit ...




Search This Site:










iframe and microsoft passpot

migration and synchronization strategy

forums rss news feed available

v2 and validaterequest="false"

request.querystring error after upgrade to 3.1.0 from 3.0.13

corrupted portal. what do i now?

beta 2 survey dll

basic ucanuse module help needed

more performance issues.

yaf .98 on dnn 2.1.2 problem!

has anyone got dotnetwiki working

what is the method for creating a new template to clone portals with tabs & modules?

zero dnn startup times

binding dualist control after postback

sub-portal creation

saturday morning sour grapes

controlling solpart forcefullmenulist submenu

add table in text/html module

dnn v4.0 - doesn't produce meta tags: description, keywords, copyright...

removing search engine keywords

dnn 2.0 urgency

disabling default login module

user control problem

log viewer

synch development and production environments

a question about breadcrumbs...

dotnetnuke 3.0 released...

dnn newbie - how do i move my site to a host?

pa private stylesheet

regarding bug # 000387 on gdn

  Privacy | Contact Us
All Times Are GMT