def OnComponentBlacklistAdd(self, event):
    item = wx.GetTextFromUser('Characters other than A-Z 0-9 and * will be ignored.', 'Add blacklist item')
    item = re.sub('[^A-Z0-9*]', '', item.upper())
    if (item == ''):
        return
    found = self.blacklistBox.FindString(item)
    if (found != wx.NOT_FOUND):
        self.blacklistBox.SetSelection(found)
        return
    self.blacklistBox.Append(item)
    self.blacklistBox.SetSelection((self.blacklistBox.Count - 1))
def OnComponentBlacklistAdd(self, event):
    item = wx.GetTextFromUser('Characters other than A-Z 0-9 and * will be ignored.', 'Add blacklist item')
    item = re.sub('[^A-Z0-9*]', , item.upper())
    if (item == ):
        return
    found = self.blacklistBox.FindString(item)
    if (found != wx.NOT_FOUND):
        self.blacklistBox.SetSelection(found)
        return
    self.blacklistBox.Append(item)
    self.blacklistBox.SetSelection((self.blacklistBox.Count - 1))