notebook.RemovePage("Title")

Hello,

When a page with the title "Title" is inserted into a notebook, one uses the

notebook.AddPage(page, "Title")

command. In turn, is there a way to remove the page in a similar way:

notebook.RemovePage("Title")

The current implementation with the index passed to RemovePage() leaves the responsibility to the programmer to manage the indices of all pages.

peter

Peter Wurmsdobler wrote:

Hello,

When a page with the title "Title" is inserted into a notebook, one uses the

notebook.AddPage(page, "Title")

command. In turn, is there a way to remove the page in a similar way:

notebook.RemovePage("Title")

The current implementation with the index passed to RemovePage() leaves the responsibility to the programmer to manage the indices of all pages.

Not built in but simple enough to do using GetPageCount and GetPageText and a for loop to find the matching text.

ยทยทยท

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!