On Tuesday, 11 February 2014 09:42:35 UTC+5:30, Chris Angelico wrote: > On Tue, Feb 11, 2014 at 3:07 PM, Jaydeep Patil <patil.jay2...@gmail.com> > wrote: > > > I have defined one function as below. > > > > > > def InfoDir(msg): > > > msg1 = wx.MessageDialog(msg) > > > msg1.ShowModal() > > > msg1.Destroy() > > > > > > InfoDir("Testing") > > > > > > > > > It gives below error. > > > msg1 = wx.MessageDialog(msg) > > > File "C:\Python27\lib\site-packages\wx-2.8-msw-unicode\wx\_windows.py", > > line 2922, in __init__ > > > > > _windows_.MessageDialog_swiginit(self,_windows_.new_MessageDialog(*args, > > **kwargs)) > > > TypeError: Required argument 'message' (pos 2) not found > > > > > > Process finished with exit code 1 > > > > It looks like you're missing a required argument :) > > > > http://www.wxpython.org/docs/api/wx.MessageDialog-class.html#__init__ > > > > Try passing it a parent window as well as the message. > > > > ChrisA
@ Chris: There is not parent window such. I just write a simple function to define. There is no class. Is it possible to work like the way i am doing? Regards Jay -- https://mail.python.org/mailman/listinfo/python-list