易截截图软件、单文件、免安装、纯绿色、仅160KB

看看这段Python代码问题出在哪

照着书上写的,执行时报错(Python2.6)
import wx
class InsertFrame(wx.Frame):
    def __init__(self,parent,id):
        wx.Frame.__init__(self,parent,id,'Frame With Button',size=(300,100))
        panel = wx.Panel(self)
        button = wx.Button(panel,label="Close",pos=(125,20),
                          size=(50,50))
        self.Bind(wx.EVT_BUTTON,self.OnCloseMe,button)
        self.Bind(wx.EVT_CLOSE,self.OnCloseWindow)

    def OnCloseMe(self,event):
        self.Close(True)

    def OnCloseWindow(self,event):
        self.Destroy()

if __name__=='__main__':
    app = wx.PySimpleApp()
    frame = InsertFrame(parent=None,id=-1)
    frame.Show()
    app.MainLoop()
   
报错信息如下:
Traceback (most recent call last):
  File "D:\Python26\test\wx\button.py", line 19, in <module>
    frame = InsertFrame(parent=None,id=-1)
  File "D:\Python26\test\wx\button.py", line 4, in __init__
    wx.Frame.__init__(self,parent,id,'


相关问答:

python编译器问题

    我现在用的是eclipse 那个插件,可能是因为没配置明白的问题,感觉不好,没有一些必要的功能。
    后来我换了Eric4,比eclipse插件好用不少,但是缺少一个我最希望有的功能:代码追踪, ......

python的引用计数

我用了def CreateMyDialog(self):
        dlg = MyDialog(None, -1, ''.decode('utf8'), (300,300), (300,200), wx.DEFAULT_DIALOG_STYLE | wx.DIALOG_NO_PARENT )
&nbs ......

[免费分享]Let's Python第二集发布, 可稳定下载.

详细信息请查看:
http://blog.csdn.net/lgg201/archive/2009/10/08/4643635.aspx

  Let's-python-系列视频发布专贴 收藏
视频较早的时候就说是要录了, 这一周录了第一集, 由于第一次录视频, ......

关于用Python处理大量数据的问题

我现在要处理数百万条数据,处理过程是通过比较数据里是否有指定的字符串,再插入到另外的表中,请问用Python如何高效完成?先谢谢各位了。

建议:别直接跟数据库比较。太耗费IO。
把你需要比较的字段从数据 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号