Show Modal form?

Show Modal form?

Anonymous
Not applicable
644 Views
6 Replies
Message 1 of 7

Show Modal form?

Anonymous
Not applicable
Hi How do I show an addin form modally in Inv frmAbout.Show vbModal, ??? / Michael Christoffersen
0 Likes
645 Views
6 Replies
Replies (6)
Message 2 of 7

Anonymous
Not applicable
Don't pass any parameter to Show method of form.
frmAbout.Show
Call the SetParent windows API. The InventorApp.MainFramehwnd will provide you the handle of the enventor application and frmAbout.hwnd will give the child window handle..
0 Likes
Message 3 of 7

Anonymous
Not applicable
Thanks :-) / Michael "manoj_vest" skrev i en meddelelse news:15706201.1099901722508.JavaMail.jive@jiveforum2.autodesk.com... > Don't pass any parameter to Show method of form. > frmAbout.Show > Call the SetParent windows API. The InventorApp.MainFramehwnd will provide > you the handle of the enventor application and frmAbout.hwnd will give the > child window handle..
0 Likes
Message 4 of 7

Anonymous
Not applicable
Hi Manoj Just worked some more in it - my form is now a child of the MainInventor, but that is not the same as "Modal" It is still possible to access the Inventor commands. / Michael "CADmageren ApS" wrote in message news:418f3682$1_1@newsprd01... > Thanks :-) > > / Michael > > > "manoj_vest" skrev i en meddelelse > news:15706201.1099901722508.JavaMail.jive@jiveforum2.autodesk.com... > > Don't pass any parameter to Show method of form. > > frmAbout.Show > > Call the SetParent windows API. The InventorApp.MainFramehwnd will provide > > you the handle of the enventor application and frmAbout.hwnd will give the > > child window handle.. > >
0 Likes
Message 5 of 7

Anonymous
Not applicable
Hi Michael,

Sorry to lead you in wrong direction. Actually for showing your for as modal dialog through you don't need any thing extra. You have to call the show method of form as follows

frmMyForm.Show vbModal

No argument is passed as parent and will automatically accept Inventor window as parent. Since it was direct call, I thought you ware looking for modeless dialog.

Hope this will solve your problem and again sorry for miss-interpreting your question.

Manoj
0 Likes
Message 6 of 7

Anonymous
Not applicable
Hi Manoj Your previous advice actually worked great in another of my apps, so thanks anyway for the tip. / Michael "manoj_vest" wrote in message news:7900930.1100061843218.JavaMail.jive@jiveforum2.autodesk.com... > Hi Michael, > > Sorry to lead you in wrong direction. Actually for showing your for as modal dialog through you don't need any thing extra. You have to call the show method of form as follows > > frmMyForm.Show vbModal > > No argument is passed as parent and will automatically accept Inventor window as parent. Since it was direct call, I thought you ware looking for modeless dialog. > > Hope this will solve your problem and again sorry for miss-interpreting your question. > > Manoj
0 Likes
Message 7 of 7

Anonymous
Not applicable
It is still possible to access the Inventor commands. I think you need to be looking at the .DisabledCommandTypes property of the Document object. -------------------------------------------------------------------------------- Brian R. Iwaskewycz Senior Mechanical Engineer PA Transformer Technology, Inc. I've got a feelin' Pittsburgh's goin' to the Superbowl
0 Likes