LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 43
Default TreeView.Nodes.Clear crashes Excel 2002.

When, that is, TV.Visible = False.

Actually, the crash doesn't seem to happen right on the .Clear, but
when you try to add a new node to a cleared-while-hidden TV.

I'm too embarrassed to say how long it took me to think of this cute
but obvious fix:

Push TV.Visine, set to True, .Clear, then pop it again.

It should all happen fast enough not to see on-screen.

***

What about .Nodes.Remove, you ask?

Cheerfully fails too, when TV.Invisible. Only it doesn't crash Excel.

***
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Iterate through treeview nodes Jonathan Brown Excel Programming 4 February 9th 09 12:53 AM
VBA croaks on Nodes.Clear if TreeView is *not* Visible. [email protected] Excel Programming 1 August 24th 08 12:54 AM
Adding nodes to treeview John Excel Programming 3 December 1st 04 09:07 PM
treeview add nodes Serkan[_2_] Excel Programming 3 October 3rd 03 09:55 AM
TreeView: add more than one node to nodes collection Peter[_25_] Excel Programming 3 September 5th 03 12:15 PM


All times are GMT +1. The time now is 07:04 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"