473,406 Members | 2,698 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,406 software developers and data experts.

asp.net manage state of classic asp controls.

I have a asp.net web form running in the 2.0 framework.

The page has a mixture of asp.net controls and older controls (ex:
<input type="radio" )
When the pages posts back to itself, all of the user entry for the
aspx controls are saved...because viewstate is managed for me.

But the user entry in the old controls...like radio buttons or
dropdownlists are not saving the user input.

I really can't convert these controls to aspx controls. The
dropdownmenu is using an optgroup.

I've been reading some older articles about using hidden fields for
this..but was wondering if there is a better way to do this...with
examples.

Thanks

Oct 16 '07 #1
2 1187
for your "plain old html" controls, add the runat="server" directive, as well
as the enableViewState="true" directive.
-- Peter
Recursion: see Recursion
site: http://www.eggheadcafe.com
unBlog: http://petesbloggerama.blogspot.com
BlogMetaFinder: http://www.blogmetafinder.com

"dr*********@gmail.com" wrote:
I have a asp.net web form running in the 2.0 framework.

The page has a mixture of asp.net controls and older controls (ex:
<input type="radio" )
When the pages posts back to itself, all of the user entry for the
aspx controls are saved...because viewstate is managed for me.

But the user entry in the old controls...like radio buttons or
dropdownlists are not saving the user input.

I really can't convert these controls to aspx controls. The
dropdownmenu is using an optgroup.

I've been reading some older articles about using hidden fields for
this..but was wondering if there is a better way to do this...with
examples.

Thanks

Oct 16 '07 #2
really?

so if I have this...
<select name="contact_industry" >

I can do this? <select name="contact_industry" runat="server" >

here is how I figured out how to do this for radio buttons.

<input type="radio" name="MembershipType" value="Sponsor1_ks" <% if
( Request.Form.Get("MembershipType") == "Sponsor1_ks")
{ Response.Write ("checked"); } %
On Oct 16, 12:51 pm, Peter Bromberg [C# MVP]
<pbromb...@yahoo.yohohhoandabottleofrum.comwrote :
for your "plain old html" controls, add the runat="server" directive, as well
as the enableViewState="true" directive.
-- Peter
Recursion: see Recursion
site: http://www.eggheadcafe.com
unBlog: http://petesbloggerama.blogspot.com
BlogMetaFinder: http://www.blogmetafinder.com

"drewsdep...@gmail.com" wrote:
I have a asp.net web form running in the 2.0 framework.
The page has a mixture of asp.net controls and older controls (ex:
<input type="radio" )
When the pages posts back to itself, all of the user entry for the
aspx controls are saved...because viewstate is managed for me.
But the user entry in the old controls...like radio buttons or
dropdownlists are not saving the user input.
I really can't convert these controls to aspx controls. The
dropdownmenu is using an optgroup.
I've been reading some older articles about using hidden fields for
this..but was wondering if there is a better way to do this...with
examples.
Thanks


Oct 16 '07 #3

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

Similar topics

99
by: Jim Hubbard | last post by:
It seems that Microsoft not only does not need the classic Visual Basic developer army (the largest army of developers the world has ever seen), but now they don't need ANY Windows developer at a...
8
by: Bf | last post by:
I was creating test projects using c# and was surprised that there seems to be only a form based windows applications available. Is it safe to assume that classic window applications that utilize a...
0
by: Robert Scarborough | last post by:
Can someone point me to information on how to save the state of COM objects in WebForm between round trips in ASP.NET? I've read much of the documentation about Application and Session state and...
3
by: gb | last post by:
We are in the process of upgrading part of a large system to .NET, whilst the majority will remain ASP. Sharing session state information will not be a problem at the moment as it is trivial and...
3
by: Neven Klofutar | last post by:
Hi, I recently read an article on MSDN about viewstate and postback. http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaspp/html/viewstate.asp The author states the following:...
9
by: Charles Law | last post by:
Hi chaps I realise that this is a .NET group, but please don't shoot me down quite yet. I looked in the vb classic groups and there seems to be so little activity there that I was not hopeful of...
0
by: ChrisMiddle10 | last post by:
Hey, I am developing a fairly simple custom web control. I am, however, having a major problem understanding how to have any child controls maintain state. For instance, in my particular control...
3
by: Steven Nagy | last post by:
Hi all, I'm getting across the membership API stuff. However it seems that we would have benefitted from some extra controls for "Manage Users" and "Manage Roles". Is there some additional...
3
by: =?Utf-8?B?U2FjaGluIFNha2k=?= | last post by:
Hi, Our application have asp and .aspx pages, we need to redirect user from asp page to .aspx page and vice-versa and want to share session state b/w asp and asp.net. This could be achieved by...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
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
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,...
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.