This is a migrated thread and some comments may be shown as answers.

RadTreeView "Control does not support background colors" error?

2 Answers 76 Views
Treeview
This is a migrated thread and some comments may be shown as answers.
Kenyatta
Top achievements
Rank 1
Kenyatta asked on 10 Oct 2008, 10:38 PM
I am experiencing an issue with RadTreeView giving me an error in Visual Studio that is to the effect of the following:

System.ArgumentException "Control does not support transparent background colors."

I have a split container control, which is a slider control that allows me to resize the panel that contains the RadTreeView. I notice whenever I resize the panel so that the text on a node is not visible, this exception will appear. Here is the stack trace from the error:



   at System.Windows.Forms.Control.set_BackColor(Color value)
   at Telerik.WinControls.UI.RadTreeView.InitializeBlankSpot()
   at Telerik.WinControls.UI.RadTreeView.InitializeUIElements()
   at Telerik.WinControls.UI.RadTreeView.OnLayout(LayoutEventArgs args)
   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.Layout.LayoutTransaction.DoLayout(IArrangedElement elementToLayout, IArrangedElement elementCausingLayout, String property)
   at System.Windows.Forms.Control.OnResize(EventArgs e)
   at Telerik.WinControls.UI.RadTreeView.OnResize(EventArgs e)
   at System.Windows.Forms.Control.OnSizeChanged(EventArgs e)
   at Telerik.WinControls.UI.RadTreeView.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()
   at System.Windows.Forms.Control.WmWindowPosChanged(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at Telerik.WinControls.RadControl.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.SafeNativeMethods.SetWindowPos(HandleRef hWnd, HandleRef hWndInsertAfter, Int32 x, Int32 y, Int32 cx, Int32 cy, Int32 flags)
   at System.Windows.Forms.Control.SetBoundsCore(Int32 x, Int32 y, Int32 width, Int32 height, BoundsSpecified specified)
   at Telerik.WinControls.RadControl.Telerik.WinControls.IComponentTreeHandler.CallSetBoundsCore(Int32 x, Int32 y, Int32 width, Int32 height, BoundsSpecified specified)
   at Telerik.WinControls.ComponentLayoutElementTree.SetBoundsCore(Int32 x, Int32 y, Int32 width, Int32 height, BoundsSpecified specified)
   at Telerik.WinControls.RadControl.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.ApplyCachedBounds(IArrangedElement container)
   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.PerformLayout()
   at DevExpress.XtraEditors.PanelControl.OnGroupLayout()
   at DevExpress.XtraEditors.PanelControl.CheckInfoCore(GroupObjectInfoArgs info)
   at DevExpress.XtraEditors.PanelControl.CheckInfo()
   at DevExpress.XtraEditors.SplitGroupPanel.OnResize(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()
   at System.Windows.Forms.Control.WmWindowPosChanged(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at DevExpress.Utils.Controls.PanelBase.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.SafeNativeMethods.SetWindowPos(HandleRef hWnd, HandleRef hWndInsertAfter, Int32 x, Int32 y, Int32 cx, Int32 cy, Int32 flags)
   at System.Windows.Forms.Control.SetBoundsCore(Int32 x, Int32 y, Int32 width, Int32 height, BoundsSpecified specified)
   at System.Windows.Forms.Control.SetBounds(Int32 x, Int32 y, Int32 width, Int32 height, BoundsSpecified specified)
   at System.Windows.Forms.Control.set_Bounds(Rectangle value)
   at DevExpress.XtraEditors.SplitGroupPanel.UpdateBounds(Rectangle bounds)
   at DevExpress.XtraEditors.SplitContainerControl.UpdateDockPosition()
   at DevExpress.XtraEditors.SplitContainerControl.set_SplitterPosition(Int32 value)
   at DevExpress.XtraEditors.Drawing.SplitContainerSplitter.StopSplit(Boolean resize)
   at DevExpress.XtraEditors.Drawing.SplitContainerSplitter.CheckMouseUp(Point point)
   at DevExpress.XtraEditors.SplitContainerControl.OnMouseUp(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at DevExpress.Utils.Controls.PanelBase.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)

I am unsure if there is a value in text that I have not yet but I'm sure it isn't. I notice the tree automatically gives me a vertical scroll bar and I can scroll up and down without any issues. Maybe this issue can be resolved if I can implement a horizontal scroll bar in my application whenever the panel is resized?

Your help is greatly appreciated, thank you
~Kenyatta

2 Answers, 1 is accepted

Sort by
0
Martin Vasilev
Telerik team
answered on 13 Oct 2008, 04:10 PM
Hello Kenyatta,

The reported exception is a known issue and it has already been fixed in latest Q2 2008 Service Pack 1 release. Please, download and have it a try.

I am looking forward to your answer about licensing in your other ticket.
 

Sincerely yours,
Martin Vasilev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Kenyatta
Top achievements
Rank 1
answered on 13 Oct 2008, 06:00 PM
Hello Martin,

I installed SP1 and this appears to resolve my issue. Thanks for the help

~Kenyatta
Tags
Treeview
Asked by
Kenyatta
Top achievements
Rank 1
Answers by
Martin Vasilev
Telerik team
Kenyatta
Top achievements
Rank 1
Share this question
or