User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the ASP.NET section within the Web Development category of DaniWeb, a massive community of 391,153 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,136 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our ASP.NET advertiser: Lunarpages ASP Web Hosting
Views: 2411 | Replies: 2
Reply
Join Date: Apr 2007
Posts: 13
Reputation: virendra_sw is an unknown quantity at this point 
Rep Power: 2
Solved Threads: 0
virendra_sw virendra_sw is offline Offline
Newbie Poster

Question Export Crystal report in word from ASP .Net

  #1  
Sep 17th, 2007
Hi,

I want to export crystal report fom ASP .Net in word format. I am able to export crystal report but it dosen't give be the Word toolbar as we can see in the when Msword document is opened.

oStream = DirectCast(Me.reportdocoument.ExportToStream(CrystalDecisions.[Shared].ExportFormatType.WordForWindows), MemoryStream)
Response.Clear()
Response.Buffer = True
Response.ContentType = "application/msword"
Response.BinaryWrite(oStream.ToArray())
Response.[End]()

where reportdocoument is the crystal report document.

When we will execute this code it will ask 2 options to save or to open the word document. If you select the open word document then it will show the word document but no word toolbar as we can see in Msword. If we want to print this document then we can not print.

Please Help.

Reply from the earliest is really appreciated.

With Regards,
Virendra
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Jun 2008
Posts: 1
Reputation: dotnetdelegate is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
dotnetdelegate dotnetdelegate is offline Offline
Newbie Poster

Re: Export Crystal report in word from ASP .Net

  #2  
Jun 13th, 2008
Hi Veeru,

U can use Ctrl+P for print Dialog.

Thanks
Hari


Originally Posted by virendra_sw View Post
Hi,

I want to export crystal report fom ASP .Net in word format. I am able to export crystal report but it dosen't give be the Word toolbar as we can see in the when Msword document is opened.

oStream = DirectCast(Me.reportdocoument.ExportToStream(CrystalDecisions.[Shared].ExportFormatType.WordForWindows), MemoryStream)
Response.Clear()
Response.Buffer = True
Response.ContentType = "application/msword"
Response.BinaryWrite(oStream.ToArray())
Response.[End]()

where reportdocoument is the crystal report document.

When we will execute this code it will ask 2 options to save or to open the word document. If you select the open word document then it will show the word document but no word toolbar as we can see in Msword. If we want to print this document then we can not print.

Please Help.

Reply from the earliest is really appreciated.

With Regards,
Virendra
Reply With Quote  
Join Date: Aug 2007
Location: Somewhere between heaven and hell
Posts: 86
Reputation: Kusno is an unknown quantity at this point 
Rep Power: 2
Solved Threads: 6
Kusno's Avatar
Kusno Kusno is offline Offline
Junior Poster in Training

Re: Export Crystal report in word from ASP .Net

  #3  
Jul 11th, 2008
Hi,

Try this code :
Crs.ReportDocument.ExportToDisk(ExportFormatType.WordForWindows, yourReport)

Crs is your ReportSourceID. That is located in CrystalReportViewer control.

Thanks,

Kusno.
Last edited by Kusno : Jul 11th, 2008 at 2:56 am. Reason: Forget to add Quote tag
NEVER NEVER NEVER GIVE UP
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

DaniWeb ASP.NET Marketplace
Thread Tools Display Modes

Similar Threads
Other Threads in the ASP.NET Forum

All times are GMT -4. The time now is 7:07 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC