Ok, sorry about the above question. I solved it adding this to the main thread: try: SrvrTCP = module.ThreadedTCPServer(ip,port) SrvrTCP.start() except Exception, description: MsgBox(self,"TCPServer Error:\n\n"+str(description),title="TCPServer",style=wx.OK | wx.ICON_ERROR) return Peter, thank you very much.