This is a migrated thread and some comments may be shown as answers.

docx Export Error

14 Answers 141 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Chris
Top achievements
Rank 1
Chris asked on 07 Apr 2011, 04:20 PM
With the new 2011 Q1 Telerik Reporting release I'm getting errors when trying to export reports that have HtmlTextbox components in the report.  The other export formats work correctly.  Anyone else having issues with docx exports?

Here's the stacktrace:

[ObjectDisposedException: Cannot access a closed Stream.]
   System.IO.__Error.StreamIsClosed() +57
   System.IO.MemoryStream.Seek(Int64 offset, SeekOrigin loc) +9628100
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.DocumentHelper.WriteHtmlPart(HeaderPart headerPart, String html) +218
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.HeaderStorage.WriteHtml(String html) +45
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ContentStorage.CreateHtml(String html) +92
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ContentBuilder.WriteHtml(String html) +45
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.HtmlTextBoxWriter.WriteHtml(ContentBuilder contentBuilder, LayoutElement layoutElement) +303
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.HtmlTextBoxWriter.WriteContent(ContentBuilder contentBuilder, LayoutElement layoutElement) +37
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ContentWriter.WriteContent(LayoutBuilder layoutBuilder, LayoutElement layoutElement) +68
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ElementWriter.WriteElement(LayoutBuilder layoutBuilder, LayoutElement layoutElement) +101
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ElementWriter.WriteContent(LayoutBuilder layoutBuilder, LayoutElement layoutElement) +166
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ElementWriter.WriteElement(LayoutBuilder layoutBuilder, LayoutElement layoutElement) +101
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.LayoutWriter.WriteElement(LayoutBuilder layoutBuilder, LayoutElement layoutElement) +245
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.HeaderWriter.WriteDocument(DocumentBuilder documentBuilder, LayoutElement layoutElement) +101
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.WordprocessingWriter.WriteEndElement(ProcessingElement pageElement, ElementPageInfo pageInfo) +92
   Telerik.Reporting.BaseRendering.PageHandler.Telerik.Reporting.Paging.IPageHandler.EndElement(ProcessingElement element, ElementPageInfo info) +49
   Telerik.Reporting.Paging.PagerBase.AddEndElementToPage(ProcessingElement processingElement, ElementPageInfo pageInfo) +49
   Telerik.Reporting.Paging.RenderingElement.AddToPageRecursive(RectangleRF parentClip, RoundedFloat parentTop, RoundedFloat parentLeft, RoundedFloat parentReservedTop, RoundedFloat parentReservedBottom, RoundedFloat parentReservedLeft, RoundedFloat parentReservedRight) +1201
   Telerik.Reporting.Paging.PageComposition.WritePageSection(PageArea pageArea, RenderingElement pageSection, RoundedFloat height) +763
   Telerik.Reporting.Paging.PageComposition.ApplyPageSections() +308
   Telerik.Reporting.Paging.PageComposition.SendPhysicalPages(Boolean lastPage) +81
   Telerik.Reporting.Paging.PageComposition.PageOverride() +1268
   Telerik.Reporting.Paging.PagerBase.Page(IPageHandler handler, Report report) +103
   Telerik.Reporting.BaseRendering.RenderingExtensionBase.Render(Report report, Hashtable renderingInfo, Hashtable deviceInfo, CreateStream createStreamCallback, EvaluateHeaderFooterExpressions evalHeaderFooterCallback) +361
   Telerik.Reporting.Processing.ReportProcessor.Render(IList`1 reports, ExtensionInfo extensionInfo, Hashtable renderingContext, Hashtable deviceInfo, CreateStream createStreamCallback) +1481
   Telerik.Reporting.Processing.ReportProcessor.RenderReport(String format, IReportDocument reportDocument, Hashtable deviceInfo, Hashtable renderingContext, CreateStream createStreamCallback) +608
   Telerik.ReportViewer.WebForms.ServerReport.Render(HttpResponse response, String format, Int32 pageIndex) +894
   Telerik.ReportViewer.WebForms.ReportExportOperation.PerformOperation(NameValueCollection urlQuery, HttpContext context) +112
   Telerik.ReportViewer.WebForms.HttpHandler.ProcessRequest(HttpContext context) +276
   System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +100
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +75

14 Answers, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 11 Apr 2011, 09:43 AM
Hello Chris,

We've not been contacted with this error before and could not reproduce such a problem on our end (sample report is attached). That is why we would appreciate if you provide us with a runnable report that exhibits the problem you've encountered. Once we review it, we would be able to provide you with more information.

All the best,
Steve
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Andy Grimes
Top achievements
Rank 1
answered on 28 Apr 2011, 03:50 PM
I can tell you I am receiving this for 2 of my 3 reports but not all of them...  same error on docx export pdf works fine....

Cannot access a closed Stream

0
Andy Grimes
Top achievements
Rank 1
answered on 28 Apr 2011, 03:50 PM
here is the stack...

Cannot access a closed Stream.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.ObjectDisposedException: Cannot access a closed Stream.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[ObjectDisposedException: Cannot access a closed Stream.]
   System.IO.MemoryStream.Seek(Int64 offset, SeekOrigin loc) +12610339
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.DocumentHelper.WriteHtmlPart(HeaderPart headerPart, String html) +310
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.HeaderStorage.WriteHtml(String html) +17
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ContentStorage.CreateHtml(String html) +84
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ContentBuilder.WriteHtml(String html) +28
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.HtmlTextBoxWriter.WriteHtml(ContentBuilder contentBuilder, LayoutElement layoutElement) +244
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ElementWriter.WriteElement(LayoutBuilder layoutBuilder, LayoutElement layoutElement) +73
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ElementWriter.WriteContent(LayoutBuilder layoutBuilder, LayoutElement layoutElement) +171
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.ElementWriter.WriteElement(LayoutBuilder layoutBuilder, LayoutElement layoutElement) +73
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.LayoutWriter.WriteElement(LayoutBuilder layoutBuilder, LayoutElement layoutElement) +63
   Telerik.Reporting.OpenXmlRendering.Wordprocessing.WordprocessingWriter.WriteEndElement(ProcessingElement pageElement, ElementPageInfo pageInfo) +56
   Telerik.Reporting.Paging.RenderingElement.AddToPageRecursive(RectangleRF parentClip, RoundedFloat parentTop, RoundedFloat parentLeft, RoundedFloat parentReservedTop, RoundedFloat parentReservedBottom, RoundedFloat parentReservedLeft, RoundedFloat parentReservedRight) +1089
   Telerik.Reporting.Paging.PageComposition.WritePageSection(PageArea pageArea, RenderingElement pageSection, RoundedFloat height) +670
   Telerik.Reporting.Paging.PageComposition.ApplyPageSections() +259
   Telerik.Reporting.Paging.PageComposition.SendPhysicalPages(Boolean lastPage) +40
   Telerik.Reporting.Paging.PageComposition.PageOverride() +1056
   Telerik.Reporting.Paging.PagerBase.Page(IPageHandler handler, Report report) +227
   Telerik.Reporting.BaseRendering.RenderingExtensionBase.Render(Report report, Hashtable renderingInfo, Hashtable deviceInfo, CreateStream createStreamCallback, EvaluateHeaderFooterExpressions evalHeaderFooterCallback) +435
   Telerik.Reporting.Processing.ReportProcessor.Render(IList`1 reports, ExtensionInfo extensionInfo, Hashtable renderingContext, Hashtable deviceInfo, CreateStream createStreamCallback) +1247
   Telerik.Reporting.Processing.ReportProcessor.RenderReport(String format, IReportDocument reportDocument, Hashtable deviceInfo, Hashtable renderingContext, CreateStream createStreamCallback) +619
   Telerik.ReportViewer.WebForms.ServerReport.Render(HttpResponse response, String format, Int32 pageIndex) +862
   Telerik.ReportViewer.WebForms.HttpHandler.ProcessRequest(HttpContext context) +243
   System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +597
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +266

 


 

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.1

0
Steve
Telerik team
answered on 28 Apr 2011, 04:20 PM
Hi Andy,

We already had the stacktrace from the original post of Chris, but it does not really help in reproducing the problem. Please open a support ticket and attach a runnable report/project that exhibits the problem and once we review it, we would be able to provide more info/fix.

Greetings,
Steve
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Chris
Top achievements
Rank 1
answered on 11 May 2011, 03:04 AM
Still working on isolating this, but it appears to happen only when I place an HtmlTextBox in the Page Header band of the report.  HtmlTextbox's appear to work correctly in the Detail band.
0
Steve
Telerik team
answered on 16 May 2011, 02:36 PM
Hello Chris,

Thank you for the additional information - it helped us reproduce the issue on our end and we've logged the issue in our system for further investigation and fixing.

Your Telerik points have been updated for bringing this to our attention.

Best wishes,
Steve
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Jill
Top achievements
Rank 1
answered on 06 Jun 2011, 04:39 PM
Has a fix been found for this issue?  I am experiencing the same issue.
0
Steve
Telerik team
answered on 06 Jun 2011, 05:03 PM
Hi Jill,

The issue would be fixed for the upcoming Q2 release. In the mean time, avoid using HtmlTextBox in page sections.

Best wishes,
Steve
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Jill
Top achievements
Rank 1
answered on 06 Jun 2011, 05:54 PM
I am also experiencing another issue with HtmlTextBox.  The formatting is running words together, I cannot see any reasonable sequence for the run together words.

See below in my report I have assigned the same field to both an HtmlTextbox (top) and a TextBox(bottom).  the word output is not recognizing whitespace see "Inany event" item 2, or "ifapplicable" Item 3.  How can I resolve this issue?

1.                    Shipping terms are F.O.B. Port of Entry or F.O.B. Cincinnati as appropriate.

2.                    All prices are subject to change without notice and may be withdrawn at any time prior to Makino's acceptance of Buyer's order by Makino's Home Office. Inany event, prices become invalid sixty (60) days after date of quotation.

3.                    Prices do not include excise, sales, use and transportation taxes of any taxing authority. If not included in the invoice for the goods or services, such taxes, ifapplicable, may be invoiced ata later date.

 

<P><ol><li>Shipping terms are F.O.B. Port of Entry or F.O.B. Cincinnati as appropriate.</li><li>All prices are subject to change without notice and may be withdrawn at any time prior to Makino's  acceptance of Buyer's order by Makino's Home Office.  In any event, prices become invalid sixty (60) days after date of quotation.</li><li>Prices do not include excise, sales, use and transportation taxes of any taxing authority.  If not included in the invoice for the goods or services, such taxes, if applicable, may be invoiced ata later date.</li></ol></P>

 

0
Steve
Telerik team
answered on 07 Jun 2011, 07:55 AM
Hello Jill,

There was a problem with the new line feed in the HtmlTextBox that has been fixed in the Q1 2011 SP1, so please upgrade. Additionally further research showed that there is a problem with MS Word which handles line spacing incorrectly whenever you have HTML injected directly. We found that you can "notify" it by using <p> tag to surround the HTML, however this is not an almighty solution and might lead to other layout problems whenever you have nested paragraphs, lists etc. We would continue looking for a better way to handle such case, but for the time being you can try the above suggestion.

Greetings,
Steve
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Chris
Top achievements
Rank 1
answered on 07 Jun 2011, 01:23 PM
Where do I get the service pack, the only one I can find says that it is a trial version, I cannot have a trial version message on my software.
0
Steve
Telerik team
answered on 07 Jun 2011, 01:36 PM
Hi Chris,

It is available in your account under Your Account / Your products / Telerik Reporting/ Automatic Installation link.

All the best,
Steve
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Marko Gluhak
Top achievements
Rank 1
answered on 19 Sep 2011, 11:00 AM
Hi,

I'm getting this error too. I have 5.1.11.713 version od Telerik reporting.

Is this supposed to be solved or you still working on this issue?

Marko

Edit: Its HtmlBox in Footer that couseing this.
0
Steve
Telerik team
answered on 19 Sep 2011, 01:09 PM
Hi Marko,

This issue is resolved and would be part of the upcoming Q2 SP1 release by the end of this week or early next week.

Regards,
Steve
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
General Discussions
Asked by
Chris
Top achievements
Rank 1
Answers by
Steve
Telerik team
Andy Grimes
Top achievements
Rank 1
Chris
Top achievements
Rank 1
Jill
Top achievements
Rank 1
Chris
Top achievements
Rank 1
Marko Gluhak
Top achievements
Rank 1
Share this question
or