hiding an open form

F

fishqqq

How can I open a form and not have the user see it is open?
I have a rather large macro that opens and closes many forms
(automatically updating fields) but i don't want the user to see these
forms as they open and close.
(i know i should have had the tables updated directly but i've got a
lot of time into this and feel i'm past the point of no return now)

Is there a command i can put at the beginning of the macro to tell it
not to "show" the forms it opens?

thanks
Steve
 
M

Marshall Barton

How can I open a form and not have the user see it is open?
I have a rather large macro that opens and closes many forms
(automatically updating fields) but i don't want the user to see these
forms as they open and close.
(i know i should have had the tables updated directly but i've got a
lot of time into this and feel i'm past the point of no return now)

Is there a command i can put at the beginning of the macro to tell it
not to "show" the forms it opens?

Use the WindowMode argument with the Hidden option.

You really are doing this the hard and slow way.
 
J

John W. Vinson

How can I open a form and not have the user see it is open?
I have a rather large macro that opens and closes many forms
(automatically updating fields) but i don't want the user to see these
forms as they open and close.
(i know i should have had the tables updated directly but i've got a
lot of time into this and feel i'm past the point of no return now)

Is there a command i can put at the beginning of the macro to tell it
not to "show" the forms it opens?

thanks
Steve

Ow.

I once rewrote an application that did that. Very complex multilayer macro,
many forms, incredible intellectual gymnastics to get branching logic...

I gave up, rewrote it to do the same task using VBA code and action queries.
It ran at least ten times faster, and more to the point it WORKED reliably.

Good luck, but you really should bite the bullet and redo it using the proper
tools. Forms are designed for human interaction, and Macros exist only to
assuage the terror of managers who don't understand code and fear that any
code will turn into Count Dracula and slay everyone on the network.
--

John W. Vinson [MVP]
Microsoft's replacements for these newsgroups:
http://social.msdn.microsoft.com/Forums/en-US/accessdev/
http://social.answers.microsoft.com/Forums/en-US/addbuz/
and see also http://www.utteraccess.com
 
D

David-W-Fenton

m:
How can I open a form and not have the user see it is open?
I have a rather large macro that opens and closes many forms
(automatically updating fields) but i don't want the user to see
these forms as they open and close.
(i know i should have had the tables updated directly but i've got
a lot of time into this and feel i'm past the point of no return
now)

Is there a command i can put at the beginning of the macro to tell
it not to "show" the forms it opens?

I would agree with others that you should bite the bullet and fix
the problem.

But one thing you can do before you run the macro is:

Application.Echo False

And when it's done:

Application.Echo True

This entirely turns off screen painting, so if there's a bug, you're
hosed, so you want good error handling (which is rather difficult in
macros...which is another reason to get away from this method).
 
F

fishqqq

Use the WindowMode argument with the Hidden option.

You really are doing this the hard and slow way.

Using the Hidden option in the windowmode argument does hide the
window from the users perspective - which is great. The problem is i
have the macro opening the window to make a change on the form them
close the window again. with the "Hidden" option the change i'm making
to the form gets applied to the form that open (behind) the hidden
form. Is there a way to hide a form yet still have my macro make the
changes to it? Ultimately I want to open a form - change it - close it
again , all without the user seeing the form open and close.

Thanks
Steve
 
M

Marshall Barton

Using the Hidden option in the windowmode argument does hide the
window from the users perspective - which is great. The problem is i
have the macro opening the window to make a change on the form them
close the window again. with the "Hidden" option the change i'm making
to the form gets applied to the form that open (behind) the hidden
form. Is there a way to hide a form yet still have my macro make the
changes to it? Ultimately I want to open a form - change it - close it
again , all without the user seeing the form open and close.

THere must be something wrong with the way you are changing
the value in the form if it's changed in the wrong form.

It kind of sounds like you are using Screen.ActiveForm to
refer to the form you want to edit the value when you should
be using Forms![name of the form]
 

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