Completed
Last Updated: 02 Feb 2016 07:35 by ADMIN
ADMIN
Nikolay Demirev
Created on: 03 Sep 2015 08:26
Category: PDFViewer
Type: Bug Report
6
Printing does not work with .NET Framework 4.6 installed
Printing document on a machine with .NET Framework 4.6 installed does not work for some documents.

Currently, an issue is opened at Microsoft Connect: "Printing with PrintDialog fails when .NET 4.6 is installed" (https://connect.microsoft.com/VisualStudio/feedback/details/1980419/printing-with-printdialog-fails-when-net-4-6-is-installed).

Workaround: In the attached project.
12 comments
ADMIN
Boby
Posted on: 02 Feb 2016 07:35
Thanks Stefan, we will update the Connect item accordingly. The workaround is now incorporated in our official version, so regardless of whether Microsoft fix the issue, the printing should work as expected with 2016 Q1 SP1 and later.
Stefan
Posted on: 01 Feb 2016 13:33
That's great to hear!
Did you inform Microsoft about the workaround, so they can search for the cause and fix it in a future release?
ADMIN
Aylin
Posted on: 25 Jan 2016 10:01
Hi,

The issue is fixed and is already included in our latest LIB release (v.2016.1.118).
The fix will be included in our next official 2016 Q1 SP 1 release as well.

Do not hesitate to contact us if any issues arise.

Best Regards,
Aylin,
The Telerik Team
Daniel
Posted on: 08 Jan 2016 02:17
The workaround works perfectly for us, and printing is now working on machines with .NET 4.6 installed.

Essentially to get it working, from the Telerik example copy the classes PrintingWorkaroundLayersBuilder and PrintingWorkaroundForNetFramework46UILayer and put them anywhere in your app. Then, ensure that
ExtensibilityManager.RegisterLayersBuilder(new PrintingWorkaroundLayersBuilder()); 
is called somewhere. This only needs to be called once from anywhere in your code before any printing occurs. We put it in the constructor of App.cs in our WPF app, guaranteeing that it gets called when the app launches.
ADMIN
Boby
Posted on: 07 Jan 2016 15:52
We believe we found a workaround for the issue. It includes adding a custom layer to the PDF viewer, which can be done only with the public API of the control even without updating the control. Project demonstrating the approach is attached. We are currently working on incorporating the workaround in the code base. We'll be glad if you share whether this fixes the issue for your printers/documents.
ADMIN
Boby
Posted on: 16 Nov 2015 13:27
@Ahmed Thanks for notifying, we somehow missed the notification. We will continue the discussion with Microsoft. Given the fact that they cannot reproduce the issue, we are starting to believe that it is printer-related. You could check if you can reproduce the problem with the project added to the Connect item - maybe the minimum repro project was too limited to reproduce the original issue in some setups.

I would encourage any of you guys to add any other observations (system setup, printer types, etc.) - directly to the Connect item or here.
Ahmed
Posted on: 14 Nov 2015 03:02
@Borislav It is similar. I am only able to print one page pdf document. If the pdf contains more than one page, it spools and disappears from the printing queue. 
Ahmed
Posted on: 14 Nov 2015 02:59
Hi guys, 

Can some one follow up with Microsoft? They have replied to the connect ticket

Thanks,
Ahmed
ADMIN
Boby
Posted on: 04 Nov 2015 13:52
Here is a link to the item we've reported to Microsoft, in case you are interested: https://connect.microsoft.com/VisualStudio/feedback/details/1980419/printing-with-printdialog-fails-when-net-4-6-is-installed . Feel free to vote for it to add some pressure.
@Ahmed Al-Asaad: Could you confirm that the issue is the same at your side, as we believe KB3088958 is not the problem?
ADMIN
Nikolay Demirev
Posted on: 29 Oct 2015 13:29
It turned out that this issue could be reproduced only on machines where .NET Framework 4.6 is installed. We have contacted Microsoft and we are waiting for their suggestions. Once there is more information on the matter we will post an update here. Currently, the only workaround is to downgrade the .NET Framework to 4.5.2 or lower version.
ADMIN
Tanya
Posted on: 23 Oct 2015 15:10
Hi Ahmed,

We are currently investigating this issue, but at this point don't have much information to share.

I can see that you have already subscribed to this item and will be notified for any status changes on it.

Regards,
Tanya
Ahmed
Posted on: 02 Oct 2015 04:25
Any update on this issue?

I am having the same issue on Windows Server 2012R2 after installing KB3088958 https://support.microsoft.com/en-us/kb/3088958 and when the document is more than one page. Printing one page documents works fine.

Is this related?