Dear Sirs,
I'm observing next exception during mouse click on selectable object in the report print preview page area:
System.ArgumentException: Value of '-2147483648' is not valid for 'green'. 'green' should be greater than or equal to 0 and less than or equal to 255. at System.Drawing.Color.CheckByte(Int32 value, String name) at System.Drawing.Color.FromArgb(Int32 alpha, Int32 red, Int32 green, Int32 blue) at CrystalDecisions.Windows.Forms.HSVColor.ToARGBColor() at CrystalDecisions.Windows.Forms.PageControl.EnhanceSelectColor(Color selectColor, Color bgColor) at CrystalDecisions.Windows.Forms.PageControl.DrawSelectBox(Graphics g, Rectangle pixelRect, Color bgColor) at CrystalDecisions.Windows.Forms.PageControl.DrawSelections(Graphics g) at CrystalDecisions.Windows.Forms.PageControl.OnPaint(PaintEventArgs e) at System.Windows.Forms.Control.PaintWithErrorHandling(PaintEventArgs e, Int16 layer, Boolean disposeEventArgs) at System.Windows.Forms.Control.WmPaint(Message& m) at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.ScrollableControl.WndProc(Message& m) at System.Windows.Forms.ContainerControl.WndProc(Message& m) at System.Windows.Forms.UserControl.WndProc(Message& m) at CrystalDecisions.Windows.Forms.PageControl.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.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam) at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg) at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32 dwComponentID, Int32 reason, Int32 pvLoopData) at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context) at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context) at System.Windows.Forms.Application.Run(Form mainForm) at MyCode() ---------------------------------------- CrystalDecisions.CrystalReports.Engine Assembly Version: 13.0.2000.0 Win32 Version: 13.0.2.469 ---------------------------------------- CrystalDecisions.Windows.Forms Assembly Version: 13.0.2000.0 Win32 Version: 13.0.2.469 ---------------------------------------- System.Windows.Forms Assembly Version: 2.0.0.0 Win32 Version: 2.0.50727.3623 (GDR.050727-3600)
Environment: Windows Server 2003 R2 32-bit, .NET 3.5 SP1.
After few experiments with changing windows themes, I've found that the source of the error is "Selected Items" "Color 1" set to black RGB(0,0,0). Setting this value to RGB(1,1,1) resolved the issue.
Please, correct your color calculation code to take RGB(0,0,0) into account as a valid windows color.
Greetings
Pavlo Ivakhiv