ASP.NET 2.0 ReadOnly behavior change when EnableViewState is false

Posted by: Rick Strahls WebLog, on 20 Dec 2005 | View original | Bookmarked: 0 time(s)

Here’s a behavior difference between ASP.NET 1.1 and 2.0: If you have a control on a page that is marked Read-Only and EnableViewState is set to false on the Page, the ReadOnly value will no longer post back in ASP.NET 2.0 - the value gets lost. This even though the value is actually returned in the POST buffer. I do this a bunch in some of my applications where there are generated IDs that display on a form, but they are readonly. The value displays and is supposed to be part of the postback...

Advertisement
Free Agile Project Management Tool from Telerik
TeamPulse Community Edition helps your team effectively capture requirements, manage project plans, assign and track work, and most importantly, be continually connected with each other.
Category: Data | Other Posts: View all posts by this blogger | Report as irrelevant | View bloggers stats | Views: 2650 | Hits: 133

Similar Posts

  • ASP.NET Membership Tip: Requiring New Users To Change Their Password When Logging On For The First Time more
  • "Variable is assigned but its Value is never used" Warning more
  • jQuery CSS Property Monitoring Plug-in updated more
  • Big sites, big modules, big problems? Easy solution! more
  • Mike Volodarsky posts a Breaking Change list in IIS 7 more
  • Thread Safety Via Read Only Collections more
  • The Java Posse on Agile more
  • Customizing the Visual WebGui design templates more
  • Cross-page postbacks and OnClientClick more
  • MSXML6 SDK documentation online more

News Categories

.NET | Agile | Ajax | Architecture | ASP.NET | BizTalk | C# | Certification | Data | DataGrid | DataSet | Debugger | DotNetNuke | Events | GridView | IIS | Indigo | JavaScript | Mobile | Mono | Patterns and Practices | Performance | Podcast | Refactor | Regex | Security | Sharepoint | Silverlight | Smart Client Applications | Software | SQL | VB.NET | Visual Studio | W3 | WCF | WinFx | WPF | WSE | XAML | XLinq | XML | XSD