Panels and multiple form tags?
-
i have a user control (RightPane.ascx) which has a few panels that i can hide.. to use
asp:Panel
i have to use aform
tag.. i am using this user control on the right hand side of all my pages, and now im trying to put it on a page which has aform
tag on it itself used for gathering some information.. if i try to put my RightPane.ascx on this page i get an error telling me that i cannot have multipleform
tags on the same page.. is there a way to have panels in a user control and put that user control on a data entry page? i have to assume its possible, but from the looks of it im wrong.. so whats the best way for me to go about this? any suggestions are appreciated, thanks for your help! still a newb.. cut me some slack :P -dz -
i have a user control (RightPane.ascx) which has a few panels that i can hide.. to use
asp:Panel
i have to use aform
tag.. i am using this user control on the right hand side of all my pages, and now im trying to put it on a page which has aform
tag on it itself used for gathering some information.. if i try to put my RightPane.ascx on this page i get an error telling me that i cannot have multipleform
tags on the same page.. is there a way to have panels in a user control and put that user control on a data entry page? i have to assume its possible, but from the looks of it im wrong.. so whats the best way for me to go about this? any suggestions are appreciated, thanks for your help! still a newb.. cut me some slack :P -dzDon't put FORM tags in your user control. Then in your ASPX page make sure the User Control reference is within the ASPX pages FORM tags. e.g.
<body>
<form runat="server">
<sab:themechanger id="themechangerMain" runat="server" />
</form>
</body>Then in your UC just remove your FORM tags. Don't worry about there not being FORM tags in the User Control, it is not needed when the User Control itself is wrapped properly. Just try it :)
Paul Watson
Bluegrass
Cape Town, South AfricaMacbeth muttered: I am in blood / Stepped in so far, that should I wade no more, / Returning were as tedious as go o'er DavidW wrote: You are totally mad. Nice.
-
Don't put FORM tags in your user control. Then in your ASPX page make sure the User Control reference is within the ASPX pages FORM tags. e.g.
<body>
<form runat="server">
<sab:themechanger id="themechangerMain" runat="server" />
</form>
</body>Then in your UC just remove your FORM tags. Don't worry about there not being FORM tags in the User Control, it is not needed when the User Control itself is wrapped properly. Just try it :)
Paul Watson
Bluegrass
Cape Town, South AfricaMacbeth muttered: I am in blood / Stepped in so far, that should I wade no more, / Returning were as tedious as go o'er DavidW wrote: You are totally mad. Nice.