all groups > dotnet windows forms > june 2005 >
You're in the

dotnet windows forms

group:

TreeView with XP themes error


TreeView with XP themes error JB
6/29/2005 12:00:00 AM
dotnet windows forms: When I enable XP themes using EnableVisualStyles(), the treeview control on
my form displays an old style 3D scrollbar when the form loads if items are
added to the treeview at design time.

Does anybody know a workaround?

Regards
JB

Re: TreeView with XP themes error Herfried K. Wagner [MVP]
6/29/2005 12:00:00 AM
"JB" <gatulatsofthomedotcom> schrieb:
[quoted text, click to view]

Add the items at runtime.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>
Re: TreeView with XP themes error Mick Doherty
6/29/2005 12:00:00 AM
[quoted text, click to view]

....or resize the treeview at form load (set width to 0 then reset).

A nasty workaround I know, but you shouldn't actually see it resize.

--
Mick Doherty
http://dotnetrix.co.uk/nothing.html


Re: TreeView with XP themes error Herfried K. Wagner [MVP]
6/29/2005 12:00:00 AM
Mick,

"Mick Doherty"
<EXCHANGE#WITH@AND.REMOVE.SQUAREBRACKETS.[mdaudi100#ntlworld.com]> schrieb:
[quoted text, click to view]

Great trick :-).

Hopefully we will see this problem fixed in the final release of .NET 2.0:

<URL:http://lab.msdn.microsoft.com/productfeedback/viewfeedback.aspx?feedbackid=42983f95-9cfd-4616-9744-e6d3766c40e9>

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>
AddThis Social Bookmark Button