Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PDF & Image generation fails on Windows Nano Server Docker container #42

Open
josellm opened this issue May 4, 2021 · 1 comment
Open

Comments

@josellm
Copy link

josellm commented May 4, 2021

Hi,

We need to containerize a legacy application using rdlc report and migrate to .net 5.0. We uses your porting succesfully but testing with a NanoServer returns this error when render reports to PDF/TIFF:

Microsoft.Reporting.NETCore.LocalProcessingException: An error occurred during local report processing. ---> System.NotImplementedException: The method or operation is not implemented. at System.Runtime.InteropServices.Marshal.ThrowExceptionForHR(Int32 errorCode) at Microsoft.ReportingServices.Rendering.RichText.Paragraph.ScriptItemize(Directions direction) at Microsoft.ReportingServices.Rendering.RichText.TextBox.ScriptItemize() at Microsoft.ReportingServices.Rendering.HPBProcessing.TextBox.GetRichTextBox() at Microsoft.ReportingServices.Rendering.HPBProcessing.TextBox.CalculateVerticalSize(PageContext pageContext) at Microsoft.ReportingServices.Rendering.HPBProcessing.TextBox.DetermineVerticalSize(PageContext pageContext, Double topInParentSystem, Double bottomInParentSystem, List1 ancestors, Boolean& anyAncestorHasKT, Boolean hasUnpinnedAncestors)
at Microsoft.ReportingServices.Rendering.HPBProcessing.PageItem.CalculateVertical(PageContext pageContext, Double topInParentSystem, Double bottomInParentSystem, PageItem[] siblings, List1 ancestors, Boolean& anyAncestorHasKT, Boolean hasUnpinnedAncestors, Nullable1 sourceWidth)
at Microsoft.ReportingServices.Rendering.HPBProcessing.Tablix.RowInfo.CalculateVerticalLastDetailCell(PageContext context, Boolean firstTouch, Boolean delayCalc)
at Microsoft.ReportingServices.Rendering.HPBProcessing.Tablix.CreateDetailCell(Tablix tablix, TablixMember colMemberParent, Int32 colGridIndex, RowInfo rowInfo, PageContext pageContext)
at Microsoft.ReportingServices.Rendering.HPBProcessing.Tablix.TraverseColumnMembers(Tablix tablix, TablixMember colMemberParent, Int32 parentColIndex, RowInfo currRowInfo, Boolean create, Double startInTablix, Double endInTablix, Int32& detailCellIndex, Int32& visibleSpan, List1 detailCellsState, PageContext pageContext) at Microsoft.ReportingServices.Rendering.HPBProcessing.Tablix.TraverseColumnMembers(Tablix tablix, TablixMember colMemberParent, Int32 parentColIndex, RowInfo currRowInfo, Boolean create, Double startInTablix, Double endInTablix, Int32& detailCellIndex, Int32& visibleSpan, List1 detailCellsState, PageContext pageContext)
at Microsoft.ReportingServices.Rendering.HPBProcessing.Tablix.CreateDetailRow(Tablix tablix, TablixMember rowMemberParent, Int32 parentRowIndex, Int32 parentColIndex, PageContext pageContext)`

The problem is that NanoServer is a headless SO and no support GDI+ and Uniscribe libraries. There is planned that ReportViewerCore works on Linux or NanoServer in this case?

Thanks

@lkosson
Copy link
Owner

lkosson commented May 5, 2021

Hello.

You might try putting Uniscribe DLLs from full Windows Server in your application directory in the container and see if it helps. As for now there are no workarounds to get PDF working on Linux or on Windows without GUI support installed. Eventually I might rewrite whole renderer to use other cross-platform typography library, but I cannot provide any timeline due to large amount of work required for such change.

Your best bet now is to switch to rendering to DOCX or HTML.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants