Make my form current (on top)

B

Bob Howard

Hi,

I have a modal popup which at one point calls a function located in module
.... which I purchased from a software supplier. They say that the caller
should not be modal, and if it is modal, should leave modal state just
before executing the function and then resume modal upon return.

So I do that.

But there's one odd situation that sometimes occurs where my form becomes
"not the top" form in my application while under control of this other
software.

So when I issue the Me.Modal=True after returning from this other software,
I become modal again, but I"m not on top and the screen locks up.

The user must alt-ctrl-del and terminate the application.

What command (method) can I use to put my form back on top again? I would
execute this either right before or right after resuming modal state.

Thanks.

Bob
 
B

banem2

Hi,

I have a modal popup which at one point calls a function located in module
... which I purchased from a software supplier. They say that the caller
should not be modal, and if it is modal, should leave modal state just
before executing the function and then resume modal upon return.

So I do that.

But there's one odd situation that sometimes occurs where my form becomes
"not the top" form in my application while under control of this other
software.

So when I issue the Me.Modal=True after returning from this other software,
I become modal again, but I"m not on top and the screen locks up.

The user must alt-ctrl-del and terminate the application.

What command (method) can I use to put my form back on top again? I would
execute this either right before or right after resuming modal state.

Thanks.

Bob

Instead of "Me.Modal" you can use something like this Forms!
frmFormName.Modal = True. This will make form which is not in focus
modal.

Regards,
Branislav Mihaljev
 
B

Bob Howard

Instead of "Me.Modal" you can use something like this Forms!
frmFormName.Modal = True. This will make form which is not in focus
modal.

Regards,
Branislav Mihaljev

I'll give that a try, but I suspect that these are identical since
"Forms!frmFormName" is the same as "Me" ---

Bob
 
B

Bob Howard

Instead of "Me.Modal" you can use something like this Forms!
frmFormName.Modal = True. This will make form which is not in focus
modal.

Regards,
Branislav Mihaljev

same result...
 
T

tina

try doing a

DoCmd.SelectObject

before setting the form's Modal property to True again.

hth
 
B

banem2

I'll give that a try, but I suspect that these are identical since
"Forms!frmFormName" is the same as "Me" ---

Bob

Me.Modal applied for form in focus, while Forms!FormName.Modal applies
to any open form.

Regards,
Branislav Mihaljev
 
B

Bob Howard

Tina,

I think you had the right answer as it fit the symptom ... but it didn't
work (there was no change in the screen's behavior).

Bob
 
T

tina

well, my only other suggestion would be to try "turning on" the form's Modal
property in the form's Activate event procedure.

hth
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top