Click here to Skip to main content
15,894,955 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionPopup windows Pin
RichardGrimmer2-Aug-07 5:30
RichardGrimmer2-Aug-07 5:30 
AnswerRe: Popup windows Pin
Vasudevan Deepak Kumar2-Aug-07 5:34
Vasudevan Deepak Kumar2-Aug-07 5:34 
GeneralRe: Popup windows Pin
RichardGrimmer2-Aug-07 5:44
RichardGrimmer2-Aug-07 5:44 
QuestionSQL/Item list collection Pin
wpoopsi2-Aug-07 5:27
wpoopsi2-Aug-07 5:27 
AnswerRe: SQL/Item list collection Pin
kubben2-Aug-07 6:31
kubben2-Aug-07 6:31 
AnswerRe: SQL/Item list collection Pin
wpoopsi2-Aug-07 6:38
wpoopsi2-Aug-07 6:38 
QuestionCrystal Reports and Reporting Services Pin
ZeroInfinity2-Aug-07 4:50
ZeroInfinity2-Aug-07 4:50 
Questioncontrol datagrid1_.... must be placed inside a form tag with runat=server. Pin
MissionSuccess2-Aug-07 3:40
MissionSuccess2-Aug-07 3:40 
Respected Gurus
I have to export a datagrid to excel in asp.net1.1


my code is:---

Private Sub btnExport_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnExport.Click
Response.ContentType = "application/vnd.ms-excel"
' Remove the charset from the Content-Type header.
Response.Charset = ""
' Turn off the view state.
Me.EnableViewState = False

'Dim tw As New System.IO.StringWriter
tw = New System.IO.StringWriter
'Dim hw As New System.Web.UI.HtmlTextWriter(tw)
hw = New System.Web.UI.HtmlTextWriter(tw)

' Get the HTML for the control.
DataGrid1.RenderControl(hw)
' Write the HTML back to the browser.
Response.Write(tw.ToString())
' End the response.
Response.End()
End Sub

whenever i run this code i got the error message that control datagrid1_....
must be placed inside a form tag with runat=server.

i chack the same.

Plz suggest.
Questionhot regions on image maps Pin
pipet20022-Aug-07 3:16
pipet20022-Aug-07 3:16 
QuestionOpen popup window from gridview Pin
tahsinates2-Aug-07 3:06
tahsinates2-Aug-07 3:06 
AnswerRe: Open popup window from gridview Pin
kubben2-Aug-07 3:23
kubben2-Aug-07 3:23 
GeneralRe: Open popup window from gridview Pin
tahsinates2-Aug-07 3:41
tahsinates2-Aug-07 3:41 
GeneralRe: Open popup window from gridview Pin
kubben2-Aug-07 3:48
kubben2-Aug-07 3:48 
GeneralRe: Open popup window from gridview Pin
tahsinates2-Aug-07 3:59
tahsinates2-Aug-07 3:59 
GeneralRe: Open popup window from gridview Pin
kubben2-Aug-07 4:02
kubben2-Aug-07 4:02 
GeneralRe: Open popup window from gridview Pin
tahsinates2-Aug-07 4:04
tahsinates2-Aug-07 4:04 
GeneralRe: Open popup window from gridview Pin
tahsinates2-Aug-07 4:08
tahsinates2-Aug-07 4:08 
GeneralRe: Open popup window from gridview Pin
kubben2-Aug-07 4:18
kubben2-Aug-07 4:18 
GeneralRe: Open popup window from gridview Pin
tahsinates2-Aug-07 4:20
tahsinates2-Aug-07 4:20 
GeneralRe: Open popup window from gridview Pin
kubben2-Aug-07 4:28
kubben2-Aug-07 4:28 
GeneralRe: Open popup window from gridview Pin
tahsinates2-Aug-07 4:32
tahsinates2-Aug-07 4:32 
QuestionProblem With Certificate Authentication Pin
Malayil alex2-Aug-07 2:29
Malayil alex2-Aug-07 2:29 
AnswerRe: Problem With Certificate Authentication Pin
Vasudevan Deepak Kumar2-Aug-07 5:33
Vasudevan Deepak Kumar2-Aug-07 5:33 
Questionglobal.asax session end function Pin
Sonia Gupta2-Aug-07 2:03
Sonia Gupta2-Aug-07 2:03 
AnswerRe: global.asax session end function Pin
N a v a n e e t h2-Aug-07 2:14
N a v a n e e t h2-Aug-07 2:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.