我用TextEntryDialog可以正常退出的。能否贴下你报错的代码和错误日志
dialog = wx.TextEntryDialog(None,"Input the subitem name","Subitem", style=wx.OK|wx.CANCEL)
if dialog.ShowModal() == wx.ID_OK:
subitem = dialog.GetValue()
else:
dialog.Destroy()
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…