Re-labelling wx.wizard buttons

119 views
Skip to first unread message

poogie

unread,
Jan 26, 2011, 11:49:32 PM1/26/11
to wxPython-users
Hi,

I have a multi-page wx.Wizard using wxPython 2.8.9.2. I'm trying to
change the 'Next >' label on one page to a custom value - let's say
'Checkout >' for teh sake or argument.

The only way I can think of doing this seems a bit hacky:

self.nextBtn = self.wizard.FindWindowByLabel( '&Next >' )
self.nextBtn.SetLabel( '&Commit >' )

poogie

unread,
Jan 26, 2011, 11:51:13 PM1/26/11
to wxPython-users
Ug premature post. What I wanted to say was can anyone think of
anything smarter than this:

self.nextBtn = self.wizard.FindWindowByLabel( '&Next >' )
self.nextBtn.SetLabel( '&Checkout >' )

Regards.

Robin Dunn

unread,
Jan 27, 2011, 4:05:49 AM1/27/11
to wxpytho...@googlegroups.com

Maybe only a little smarter, but I would use FindWindowById(wx.ID_FORWARD)


--
Robin Dunn
Software Craftsman
http://wxPython.org

Reply all
Reply to author
Forward
0 new messages