In a tree how do i test if item is good or i nvalid????

Found this on the web:

"
wxTreeCtrl

A tree control presents information as a hierarchy, with items that may be
expanded to show further items. Items in a tree control are referenced by
wxTreeItemId handles. The only method of wxTreeItemId class which can be
used is IsOk() which returns TRUE if the handle is valid and FALSE
otherwise.
"

···

-----Original Message-----
From: Tiago Duarte Felix [mailto:tdf@mega.ist.utl.pt]
Sent: Wednesday, November 06, 2002 9:38 AM
To: wxPython-users@lists.wxwindows.org
Subject: Re: [wxPython-users] In a tree how do i test if item is good or
invalid???

all i can find in the manul is wxTreeCtrl and wxTreeItemData...... i
can't find anithing on wxTreeItemId.... which manual are you using?? where
can i get it??

Thanks!

----- Original Message -----
From: "Joshua Judson Rosen" <rozzin@geekspace.com>
To: <wxPython-users@lists.wxwindows.org>
Sent: Wednesday, November 06, 2002 2:38 PM
Subject: Re: [wxPython-users] In a tree how do i test if item is good or
invalid???

On Wed, Nov 06, 2002 at 02:15:47PM -0000, Tiago Duarte Felix wrote:
> i need help again.... i can't find this IsOk method in the reference

manual

> in the
> wxTreeCtrl subject..... i didn't find it also on the classes that the

tree

> ctrl inherits....
>
> i am using the reference manual that comes with wxpython for windows...
> version 2.3.... is there another reference manual?? if not... how do i

use

> the IsOk method!!... tree.IsOk( Item Id??) is this it?

It's item.IsOk(), as described in the section of the reference-manual
about wxTreeItemId.

If you want to iterate through the children of a tree, you basically
want to do something like:

child, cookie = tree.GetFirstChild(root, 0)
while child.IsOk():
    ... do stuff...
    child, cookie = tree.GetNextChild(child, cookie)

--
"Human beings can be bright, in a sort of `look what my 2-year-old can
do' sort of way, if, for two minutes, they can keep their mind off of
large-breasted life-guards, coffee-cake that doesn't make you fat, and
Celine Dion." --Third Rock from the Sun

---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwindows.org
For additional commands, e-mail: wxPython-users-help@lists.wxwindows.org

---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwindows.org
For additional commands, e-mail: wxPython-users-help@lists.wxwindows.org