Page 1 of 1

Generate .doc document ?

Posted: Wed Sep 22, 2010 6:27 am
by Houssam Hamdan
Hello,

Is there a way to rename the .rtf document generated by Stimulsoft.Report.Web.StiReportResponse.ResponseAsRtf(this, objReport) method to .doc ?

A feasible workaround would be also accepted.

Thank you for your cooperation.


Generate .doc document ?

Posted: Thu Sep 23, 2010 1:48 am
by Andrew
Hello,

Unfortunately, there is no ready solution.
Integration of a property to choose file extension would require very large changes in the code, so we do not plan to do this.
As a workaround, if you have the source code of our product, you can change the default file extension for export to RTF in the StiReportResponce class.

Thank you.

Generate .doc document ?

Posted: Thu Sep 23, 2010 3:52 am
by Houssam Hamdan
Solution:

MemoryStream objMemoryStream = new MemoryStream();
StiRtfExportService objStiRtfExportService = new StiRtfExportService();
objStiRtfExportService.ExportRtf(objReport, objMemoryStream, objStiRtfExportSettings);
StiReportResponse.ResponseAs(this, objMemoryStream, "application/msword", "FileName.doc", true);

Cheers )

Generate .doc document ?

Posted: Thu Sep 23, 2010 7:26 am
by Andrew
Thank you sharing your solution.