form doesn't submit to next page?

pyncdenekeela

New Member
I have a .net form that has some fields which use AutoPostBack and those work fine. The problem is when I try to use the actual submit button, the form submits back to itself instead of to the next page as specified in the form tag.<BR><BR>The form tag below is from my default.aspx page<BR><form method="post" action="step1.aspx" runat="server"><BR><BR>Is there something that needs to be done differently than classic ASP?<BR><BR>Thank you!If you want a form to submit to another page, leave off the runat="server". A server-side form object automatically sets itself up as a postback form.<BR>That works, but then subroutines associated with the AutoPostBack fields no longer work.<BR><BR>Example:<BR><BR><asp:RadioButtonList id="demo" runat="server" AutoPostBack OnSelectedIndexChanged="demo_CheckedChanged" RepeatDirection="Horizontal"><BR>...<BR></asp:RadioButtonList><BR><BR>It can't find the demo_CheckedChanged subroutine.Right, you can't have your cake and eat it too. Why are you wanting to redirect to another page? Why not do it all on one page? This is the model that is encouraged with ASP.NET development. That is, if you want to take advantage of the Web controls and their server-side event model, then you have to use WebForums (forms with the runat="server" attribute).I was thinking I could use the web controls and server side events for some of the dynamic changes needed, but then use the form action parameter to submit to a new page for additional processing. I wanted to use a new page because there is such a dramatic difference between the input page and the results page. Clearly I need to reconsider my strategy.
 
Back
Top