wxPython provides a powerful functionality that allows you to use a "Notebook" user interface with multiple panels - whose interface each is determined by individual Python scripts. Each panel runs in the background (even when it is not selected), and maintains the state it is in as the user switches back and forth.
This recipe is actually located at http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/65249
There is a simple example here.
There are two events you need to consider when dealing with wxNotebooks: EVT_NOTEBOOK_PAGE_CHANGED and EVT_NOTEBOOK_PAGE_CHANGING. When the user clicks on a tab in the notebook, an EVT_NOTEBOOK_PAGE_CHANGING event is sent off, and this event can be vetoed. Once the page has changed, the EVT_NOTEBOOK_PAGE_CHANGED event is sent.
You can change pages directly without user action using the wx.Notebook.SetSelection() or wx.Notebook.ChangeSelection() methods. SetSelection() sends the two events listed above, but ChangeSelection() doesn't. ChangeSelection() is the preferred method to use.