Exception with Thumbs

Stimulsoft Reports.NET discussion
Post Reply
rksaskia
Posts: 58
Joined: Fri Apr 27, 2012 9:16 am

Exception with Thumbs

Post by rksaskia »

Hello,

we used the Stimulsoft.Report.Viewer.StiRibbonViewerControl to preview the reports in an Winforms application.
The ShowThumbsPanel property is set to true.

Our customers report the following errors:

System.ArgumentOutOfRangeException
Specified argument was out of the range of valid values.
at Stimulsoft.Controls.Win.DotNetBar.ScrollBarAdv.set_LargeChange(Int32 value)
at Stimulsoft.Report.Viewer.StiViewerControl.BuildThumbsScrollBar()
at Stimulsoft.Report.Viewer.StiViewerControl.lbThumbs_SizeChanged(Object sender, EventArgs e)
at System.Windows.Forms.Control.OnSizeChanged(EventArgs e)
at System.Windows.Forms.Control.UpdateBounds(Int32 x, Int32 y, Int32 width, Int32 height, Int32 clientWidth, Int32 clientHeight)
at System.Windows.Forms.Control.UpdateBounds(Int32 x, Int32 y, Int32 width, Int32 height)
at System.Windows.Forms.Control.SetBoundsCore(Int32 x, Int32 y, Int32 width, Int32 height, BoundsSpecified specified)
at System.Windows.Forms.Control.System.Windows.Forms.Layout.IArrangedElement.SetBounds(Rectangle bounds, BoundsSpecified specified)
at System.Windows.Forms.Layout.DefaultLayout.xLayoutDockedControl(IArrangedElement element, Rectangle newElementBounds, Boolean measureOnly, Size& preferredSize, Rectangle& remainingBounds)
at System.Windows.Forms.Layout.DefaultLayout.LayoutDockedControls(IArrangedElement container, Boolean measureOnly)
at System.Windows.Forms.Layout.DefaultLayout.xLayout(IArrangedElement container, Boolean measureOnly, Size& preferredSize)
at System.Windows.Forms.Layout.DefaultLayout.LayoutCore(IArrangedElement container, LayoutEventArgs args)
at System.Windows.Forms.Layout.LayoutEngine.Layout(Object container, LayoutEventArgs layoutEventArgs)
at System.Windows.Forms.Control.OnLayout(LayoutEventArgs levent)
at System.Windows.Forms.ScrollableControl.OnLayout(LayoutEventArgs levent)
at System.Windows.Forms.Control.PerformLayout(LayoutEventArgs args)
at System.Windows.Forms.Control.System.Windows.Forms.Layout.IArrangedElement.PerformLayout(IArrangedElement affectedElement, String affectedProperty)
at System.Windows.Forms.Control.UpdateBounds(Int32 x, Int32 y, Int32 width, Int32 height, Int32 clientWidth, Int32 clientHeight)
at System.Windows.Forms.Control.UpdateBounds()
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.TreeView.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


The error obviously only occurs with certain printer models.

Can you handle the exception in StiViewerControl.BuildThumbsScrollBar?

Greetings
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: Exception with Thumbs

Post by Alex K. »

Hello,

We couldn't reproduce this bug. Please try to check the last prerelease build.
If the issue still present, please send us a simple project which reproduces the issue for analysis.

Thank you.
rksaskia
Posts: 58
Joined: Fri Apr 27, 2012 9:16 am

Re: Exception with Thumbs

Post by rksaskia »

Correct, i wrote "The error obviously only occurs with certain printer models."

But your Funktion Stimulsoft.Report.Viewer.StiViewerControl.BuildThumbsScrollBar throws the Exceptions, and i can't handle this.

In your funktion you call Stimulsoft.Controls.Win.DotNetBar.ScrollBarAdv.set_LargeChange with an invalid value, and i can't change this.

Only you know where the value for ScrollBarAdv.set_LargeChange comes from, and why this parameter can take an invalid value.

I cannot understand where the problem lies, ensures that the value for ScrollBarAdv.set_LargeChange is valid.

Greetings
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: Exception with Thumbs

Post by Alex K. »

Hello,

This should not be dependent from printers.
Please clarify which version are you use? Some time ago was fixed the similar issue, please try to check the last build and let us know about the result.

Thank you.
Post Reply