Click here to Skip to main content
15,886,422 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
hi,
i am create export to excel but this error is coming


errror.(comimg).......
Control 'ctl00_ContentPlaceHolder1_gridprocess' of type 'GridView' must be placed inside a form tag with runat=server.



how to solve this problem please help me........
Posted
Comments
Praveen Kumar Upadhyay 16-Apr-15 8:19am    
Simple, wrap your Gridview control in Form tag.
Member 10385151 16-Apr-15 10:20am    
still it show this error ...
Maciej Los 16-Apr-15 15:57pm    
The error message is quite clearly...
Samira Radwan 16-Apr-15 11:30am    
could you please give more info, like your aspx or cs files how they look like?
thank you

Its quite simple,just place your Grid view inside the form tag

C#
<form id="form1"  runat="server">

//Place you Grid view here
</form>
 
Share this answer
 
v2
Comments
Member 10385151 17-Apr-15 1:31am    
this page already used in under master page. so in master page have under form tag so no need form tag in child page and my error coming in child page...
King Fisher 17-Apr-15 1:36am    
So did you checked that your Content Placeholder inside the form tag .

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