(Note last message was bounced, so I've now set Thunderbird mail
preference to 'Plain Text' hoping that was the problem)
Trying to create MDI forms on WinXP.
Ed Leafe wrote:
> On Apr 18, 2007, at 2:00 PM, Dave Nation wrote:
>
>
>> Uwe advised :
>>
>> frmclass = "nameofcdxmlfile.cdxml"
>> frm = dabo.ui.createForm(frmclass)
>> if frm:
>> frm.show() # or frm.showModal()
>>
>> This works fine, except the forms don't load as MDI children.
>> If I open a command window from the main form menu it opens as a
>> MDI child, but my ClassDesigner forms do not.
>>
>
> You need to pass a reference to the parent form to the createForm()
> method. So that line should read:
>
> frm = dabo.ui.createForm(frmclass, parentForm)
>
>
>
I tried this with the following code in the main form menu event
handler, but the form is still not loaded as an MDI child.
def openRecipes(evt):
mainForm = evt.Application.MainForm
print "mainForm.MDI",mainForm.MDI # This Prints True
mainForm.Caption = "New Title'" # Changes caption on main
form showing mainForm if a good Reference
frm = dabo.ui.createForm("recipes.cdxml",mainForm)
if frm:
frm.show()
When I open a Command window from the same menu, it opens as an MDI child.
Any advice would be much appreciated
_______________________________________________
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/dabo-users/[EMAIL PROTECTED]