By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,203 Members | 1,358 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,203 IT Pros & Developers. It's quick & easy.

Make a PopUp Dialog Form Invisible

P: n/a
I can't seem to make a PopUp Dialog form Invisible!

'My main form calls the PopUp
DoCmd.OpenForm "F-PAUSE", WindowMode:=acDialog
'My PopUp form "F-PAUSE" contains this code
Private Sub Form_Open(Cancel As Integer)
Forms![F-PAUSE].Visible = False
' Me.Visible = False 'this did not work either
End Sub

The form is visible when in Pops Up???
I ran F-Pause directly, and still the same problem
Also, I do not see a visible property in the properties list for a
form, and I guess this is normal. I am using the Timer in the form to
pause for 3 seconds, but changing this had no affect.

Any ideas???

Thanks
Greg

Mar 16 '07 #1
Share this Question
Share on Google+
10 Replies


P: n/a

The form's Open event occurs before the form is even made visible. Why
would you try to do it there?
What is it you are trying to do? There may be a better way.

Mar 16 '07 #2

P: n/a
Hello Mike

I tried the statement in the Load and Current events as well, without
success.

Purpose:
The Initial stage of my main form calls the PopUp form. The Popup has
a 3-second timer delay that I use to check for a KeyPress sequence.
If the KeyPress sequence is pressed, the mainform will make available
another form to modify the FE data, if not then the mainform executes
normally. This is working, but I just can't seem to make the PopUp
form invisible. I do not want the popup visible.

Thanks
Greg

Mar 16 '07 #3

P: n/a
Hey Greg,

An invisible form cannot have focus, and as such cannot receive user
input.
Have you considered making this feature a menu item, or an AutoKeys
macro?

Mar 16 '07 #4

P: n/a
>An invisible form cannot have focus, and as such cannot receive user
>input.
Damn! This is making me crazy. All I want to do is pause the code in
the initial stage of my main form, so that I can interpret any
keypressed in the first 3-seconds in the life of the form. I tried a
PauseLoop at the start of the main form hoping to capture the
keypressed before the remaining code checks for the result, but the
code does not pause. So, now I pause the code sucessfully and read
the key sequence no problem, but I can't hide the popup form "F-Pause"
because I will lose the forms focus and fail to have the background
code execute (FormsTimer and KeyDown stuff). Catch22&1/2.
>Have you considered making this feature a menu item, or an AutoKeys
macro?
I want to capture a key before the user sees a Menu. I do not think
that AutoKeys will accomodate the key sequence I had in mind, and I
remember some limitations that may cause me problems.

Seems crazy. Can't simply capture a key pressed before the mainform
displays the menu!

Any other thoughts appreciated. Also, Any idea why I cannot make the
form invisible?

Thanks as Always
Greg



Have you considered making this feature a menu item, or an AutoKeys
macro

Mar 16 '07 #5

P: n/a
Ap******@gmail.com wrote:
>An invisible form cannot have focus, and as such cannot receive user
input.

Damn! This is making me crazy. All I want to do is pause the code in
the initial stage of my main form, so that I can interpret any
keypressed in the first 3-seconds in the life of the form. I tried a
PauseLoop at the start of the main form hoping to capture the
keypressed before the remaining code checks for the result, but the
code does not pause. So, now I pause the code sucessfully and read
the key sequence no problem, but I can't hide the popup form "F-Pause"
because I will lose the forms focus and fail to have the background
code execute (FormsTimer and KeyDown stuff). Catch22&1/2.
Open your form with the acDialog option. That will pause your calling code
until the user hides or closes the popup form. If you hide the form your
calling code can continue, pull values from the hidden popup, and then close
it.
--
Rick Brandt, Microsoft Access MVP
Email (as appropriate) to...
RBrandt at Hunter dot com
Mar 16 '07 #6

P: n/a
Use a splash screen. Something that is visible, makes the app look
professional and provides the visible form time to capture the key-
press.

Mar 16 '07 #7

P: n/a
I had to rethink my approach, and will have my key sequence captured
from the menu.
And will do a dance around a Visible PopupForm that will occur before
the menu on an error condition. Convoluted, but can do.

You had to be there!

Thanks guys
Greg

Mar 16 '07 #8

P: n/a

Hey Greg,

I'm not sure what changes to the 'system' you're making at start-up,
and I only mean to help out, but but are you maybe over-designing
something without realizing it? When I need to make changes to a DB,
say a startup setting, table links or something - I would just provide
a utility that can be accessed at anytime from a menu, or 'System
Options' form. If the changes require the app to be restarted, that
can be either forced or other features blocked until restarted.
I hope you don't get into the situation where you keep missing the 3
second interval, and have to frustratingly try several times, finally
mashing the keyboard until you get the timing right.

Ever see that security cam video clip where the guy trashes his office
computer?

Mar 17 '07 #9

P: n/a
On Mar 16, 11:32 pm, "storrboy" <storr...@sympatico.cawrote:
Hey Greg,

I'm not sure what changes to the 'system' you're making at start-up,
and I only mean to help out, but but are you maybe over-designing
something without realizing it? When I need to make changes to a DB,
say a startup setting, table links or something - I would just provide
a utility that can be accessed at anytime from a menu, or 'System
Options' form. If the changes require the app to be restarted, that
can be either forced or other features blocked until restarted.
I hope you don't get into the situation where you keep missing the 3
second interval, and have to frustratingly try several times, finally
mashing the keyboard until you get the timing right.

Ever see that security cam video clip where the guy trashes his office
computer?

Mar 17 '07 #10

P: n/a
Mike
When I need to make changes to a DB,
say a startup setting, table links or something - I would just provide
a utility that can be accessed at anytime from a menu, or 'System
Options' form.
Agreed! This is part of the system already.
>If the changes require the app to be restarted, that
can be either forced or other features blocked until restarted.
This has become part of my new plan. I would not have persued my
orginal thought had I known the outcome in advance. By the way, the
KeyPressed API you discussed in a previous post would have worked, but
I ran scared.
>Ever see that security cam video clip where the guy trashes his office
computer?
Ah! The truly permanent substitute to the Recycle Bin.
I came close this time around :)

Thanks
Greg

Mar 17 '07 #11

This discussion thread is closed

Replies have been disabled for this discussion.