Reputation: 513
Hey frenz I am new to Umbraco cms. And I am building site using it.Here I need to include the .net user control with some textboxs and submit button. But when I include the macro containing the .net user control in my templete and Run the site I got the error
Server Error in '/' Application.
Control 'ContentPlaceHolderDefault_News_2_Button1' of type 'Button' must be placed inside a form tag with runat=server.
I also watch the video tutorials about the Usercontrol in Umbraco. And followed the same process but i am still getting the error.
But it works fine if i used Html textbox and buttons
So, it there any solution for it.............
Upvotes: 0
Views: 1436
Reputation: 1748
This is because the control 'ContentPlaceHolderDefault_News_2_Button1' of type 'Button' is not placed inside a form tag with runat=server. Every ASP>NET control that have attribute runat="server" must be placed inside a form tag with runat=server. The solution is easy:
or
Upvotes: 2