Click here to Skip to main content
15,880,608 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
The title probably explains everything. I've looked around on the internet, and the solution is that there must only be one runat="server", but I get an error message although I delete them. The master page has a form, but not the page that I'm trying to access. I'm creating 2 seperate websites with the code just the layout which differ, the one has no issue with this and the other has a big issue with the server-side.

Your question makes no sense at all.

If you're having the problem stated in your question title, try NOT putting a Form tag in the master page, and if you need it, put it in the page in question.
Share this answer
Are you creating the 'form' at runtime on server side? If so, it will be considered as another form having runat="sever".

If not, then try cleaning the solution, remove the bin/obj folders. Clear cache and rebuild the solution.
Share this answer
Ok, I took the form tag out in the master page, this has no form now. This is the page I'm requesting which will not load because of the error.

<pre lang="xml"><asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
    <asp:Label CssClass="CatalogTitle" ID="titleLabel" runat="server" Text=""></asp:Label><br />
    <asp:Label CssClass="CatalogDescription" ID="descriptionLabel" runat="server" Text=""></asp:Label><br />
    <br />
    <uc1:ProductsList ID="ProductsList1" runat="server" />

Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900