Minimize a dll form

P

Peter

I have an application in Access 2000 that runs a custom
dll written in VB6. One method in the dll shows a form.
I wish to make the form minimize if the user minimizes
the Access Application Window.

The VB6 Show method seems to offer a way to do this. I
use something like frmTestForm.Show vbModal, OwnerForm in
the dll, but cannot find how to make OwnerForm refer to
the Access Application Window.

Anybody know how to do it?
 
J

jabbott

Peter said:
*I have an application in Access 2000 that runs a custom
dll written in VB6. One method in the dll shows a form.
I wish to make the form minimize if the user minimizes
the Access Application Window.

The VB6 Show method seems to offer a way to do this. I
use something like frmTestForm.Show vbModal, OwnerForm in
the dll, but cannot find how to make OwnerForm refer to
the Access Application Window.

Anybody know how to do it? *

You can use the WinAPI function SetParent to specify the parent as
non-VB6 Form. To get the MS Office app's hwnd, make that applicatio
topmost, use the Access.Application function hWndAccessApp().

Hope that helps


-
jabbot
 
Top