On Aug 4, 2009, at 10:27 AM, Manoharan Durga wrote:
> And, I created the following function doQuit.
>
> def doQuit(evt):
> self.Form.close()
>
> But, clicking this Quit menu does not close the form or exiting the
> application. (Clicking the x button of the window does close the
> form!)
> Can someone help?
If you want to exit the app, the best method to call is the
application's finish() method.
The method you wrote is not part of a control, right? There is no
'self' argument, so I assume that it's a simple procedural call. You
cannot therefore do 'self.Form', as this will not mean anything (the
'Form' property only has meaning for objects contained in a form).
You can always reference the application object via the
"dabo.dAppRef" module-level attribute. If you need to reference the
app object from any Dabo object, you can use the universal Dabo
property "self.Application". So in the case of your code, I would
recommend calling dabo.dAppRef.finish() to quit your app.
-- Ed Leafe
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message:
http://leafe.com/archives/byMID/[email protected]