Click here to Skip to main content
15,922,015 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i need to Export ActivReport to Excel in Asp.net

i use this code

----------------------------------------------------------------------
----------------------------------------------------------------------
Dim rpt As ActiveReport

rpt = ReportGenerator.GenerateReport(objLoginProfile, Me, Server.MapPath(""))
rpt.Run(False)

Dim m_stream As New System.IO.MemoryStream
Dim xlEXports As New XlsExport
xlEXports.Export(rpt.Document, m_stream)
m_stream.Position = 0
Response.ContentType = "application/vnd.ms-excel"
Response.AddHeader("content-disposition", "inline; filename=MyExport.xls")
Response.BinaryWrite(m_stream.ToArray)
Response.End()
----------------------------------------------------------------------
----------------------------------------------------------------------
it Export but not Good not take size of colume in Excel as Report

any one have anther code
Posted

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