Thursday, March 4, 2010

Run-time Error: Control 'controlname' of type 'Button' 'TextBox' 'GridView' 'CheckBox' must be placed inside a form tag with runat=server

I found this error in Asp.Net when i am trying to add a control dynamically in the page. The error is Control 'controlname' of type 'Button' must be placed inside a form tag with runat=server. The error comes when you trying to add the control like GridView, Button, TextBox, RadioButton, RadioButtonList, CheckBox, CheckBoxList out side the form tag of your aspx page in runtime or dynamically.

No comments:

Post a Comment