Our centralized logging system detected the following exception in one of our customers machines. It's not systematic or frequent: it just randomly happens on that machine:
System.Printing.PrintQueueException: PrintTicket provider failed to merge and validate PrintTicket. Win32 error: The data
is
invalid.
at MS.Internal.Printing.Configuration.PTProvider.MergeAndValidatePrintTicket(MemoryStream basePrintTicket, MemoryStream deltaPrintTicket, PrintTicketScope scope, ConflictStatus& conflictStatus)
at System.Printing.PrintTicketManager.MergeAndValidatePrintTicket(PrintTicket basePrintTicket, PrintTicket deltaPrintTicket, PrintTicketScope scope)
at System.Printing.PrintQueue.MergeAndValidatePrintTicket(PrintTicket basePrintTicket, PrintTicket deltaPrintTicket)
at Telerik.Windows.Controls.Diagrams.Extensions.PrintSettingsViewModel.MergeAndValidatePrintTicket(PrintTicket originalTicket, PrintTicket modificationTicket)
at Telerik.Windows.Controls.Diagrams.Extensions.RadDiagramPrintPreview.DoPrint(String title)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.Controls.Primitives.ButtonBase.OnClick()
at System.Windows.Controls.Button.OnClick()
at Telerik.Windows.Controls.RadButton.OnClick()
at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
at System.Windows.UIElement.OnMouseUpThunk(Object sender, MouseButtonEventArgs e)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler).
And here is the code causing the issue:
var printPreviewWindow =
new
Telerik.Windows.Controls.RadWindow();
var printPreview =
new
RadDiagramPrintPreview { Diagram = selectedDiagram.diagram };
printPreviewWindow.Content = printPreview;
printPreviewWindow.ResizeMode = ResizeMode.NoResize;
printPreviewWindow.WindowStartupLocation = WindowStartupLocation.CenterOwner;
printPreviewWindow.Width = 800;
printPreviewWindow.Height = 600;
printPreviewWindow.Owner = _owner;
printPreviewWindow.ShowDialog();
They are on a quite old version of our product using Telerik 2014.3.1021.40 (.NET 4.0 and Microsoft Windows NT 6.2.9200.0 64 bit).
Our latest version includes Telerik 2015.3.930.40: as far as you guys know, the new version solves that issue?
Thank you,
Regards,
Manuel