I have a gridview and an image header in my page and when i export the gridview and the image header to word document. the image header disapear when I open the word document.Am I doing it right or is there a best way to handle this kind of problem. please let me know and your help is really appreciated.
Code:
<asp:Panel ID="pnlLogo" runat="server" Width="100%" style="text-align: center">
<img src="../images/ES-DSR.jpg" alt="Mn/DOT Logo" runat="server" />
</asp:Panel><br />
Protected Sub btnWord_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnWord.Click
Response.Clear()
Response.ContentType = "application/ms-word"
Response.AddHeader("Content-Disposition", "inline;filename=TechnicalMemorandum.doc")
Response.Charset = ""
Response.Cache.SetCacheability(HttpCacheability.NoCache)
Dim stringWrite As StringWriter = New StringWriter
Dim htmlWrite As HtmlTextWriter = New HtmlTextWriter(stringWrite)
pnlLogo.RenderControl(htmlWrite)
pnlInstruction.RenderControl(htmlWrite)
pnlSignature.RenderControl(htmlWrite)
Response.Write("<BR>")
gvReviewer.RenderControl(htmlWrite)
pnlApprove.RenderControl(htmlWrite)
pnlMemo.RenderControl(htmlWrite)
pnlExplain.RenderControl(htmlWrite)
Response.Write(stringWrite.ToString())
Response.End()
End Sub