Make a form topmost in access

  • Thread starter Thread starter Nhan
  • Start date Start date
N

Nhan

Hi,
I have a form (frmTop) for different purposes. This form is not set as
"popup" in design time.
Now I want to open this Form and want to show it on top of all other windows
(Forms), same as popup form.

I use API function SetWindowPos(hwnd, HWND_TOPMOST....) in Form_Load event.
but it doesnot work. When I click on another form, frmTop is hide by this
form.

How can I do? Thanks for any help.

Nhan
 
in design view of form, set "Pop Up" and "Modal" values to Yes.
another way is, if you open the form using code, specify Dialog mode,
e.g.:
DoCmd.openForm "frmTop", , , , , acDialog
 
No, I don't think so. I know, what you wrote.
My form is use for different purporses, it is opened in different modus,
dialog, modal, or normal (modaless), therefore I can set it in design time
Popup and modal properties to Yes.
I want to open my form as the standard search dialog (short cut "ctrl+F"),
popup, on the top of all windows, but not modal.
 
Hi,
I have a form (frmTop) for different purposes. This form is not set as
"popup" in design time.

It would seem that "popup" is exactly what you need here, and the whole idea
of popup is to put a form on top of everything else.

Now I want to open this Form and want to show it on top of all other
windows
(Forms), same as popup form.

You don't mention if you have any other forms marked as popup (and,
also..why would this be so? - for what reason are other forms set as
popup?).

If you keep all forms non popup, then opening your form in model will put
the form on top, and it will HAVE TO be closed to return to the form that
opened the box. Unless this form is model, then users can use the mouse and
switch to other forms (I don't think you should allow that).

You ONLY want to use popup if that form is to remain on top, and the user
can SWITCH to using other forms (there is no connection to the form that
launched the popup). If you don't want to user to be able to switch to
other forms, then popup form is the wrong choice here...and you should use
model...
 
Now I want to open this Form and want to show it on top of all other
You don't mention if you have any other forms marked as popup (and,
also..why would this be so? - for what reason are other forms set as
popup?).

Anothers forms aren't popup. I mean, I want to open this Form and ..., same
as popup form.
If you keep all forms non popup, then opening your form in model will put
the form on top, and it will HAVE TO be closed to return to the form that
opened the box. Unless this form is model, then users can use the mouse and
switch to other forms (I don't think you should allow that).

You ONLY want to use popup if that form is to remain on top, and the user
can SWITCH to using other forms (there is no connection to the form that
launched the popup). If you don't want to user to be able to switch to
other forms, then popup form is the wrong choice here...and you should use
model...

The problem is: my form is sometime open as normal (not popup), sometime as
popup. I cannot set popup property to true in design time, and in runtime it
is not allowed to change this property.
I don't want show as modal.
Do you have an idee?
 
Back
Top