On May 24, 2007, at 9:34 AM, Uwe Grauer wrote:
>>> How do i have to extend my ug.__init__?
>>> Is there a general receipt for this?
>>
>> You should *never* have to mess with __init__(). You should be using
>> the various hook methods instead, such as beforeInit(), afterInit(),
>> afterInitAll(), initProperties(), and initEvents().
>>
>
> Does this mean it is not allowed to have a ug/__init__.py to import
> the
> various module files?
My mistake - when you said __init__, I assumed you meant __init__()
method, not the __init__.py file.
> Do i have to use:
> myForm.py:
> from ug import ugApp
> from ug import ugForm
> ...
> instead of:
> from ug import *
I would follow the example of the directory structure created the
AppWizard. Create an __init__.py file in your ui/biz/db directory,
and the lines to import all of your classes in there. Then, from your
app, you can simply refer to these classes as ui.MyFormClass, or
biz.MyBizobj.
You shouldn't need an __init__.py file in your main app dir, though.
-- Ed Leafe
-- http://leafe.com
-- http://dabodev.com
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message: http://leafe.com/archives/byMID/dabo-dev/[EMAIL PROTECTED]