Hiding the Access background application?

  • Thread starter Thread starter test guy
  • Start date Start date
T

test guy

I've built an "application" in Access 2002 and want the users to see the
forms, but not with Access in the background. How does one do this? Thanks
 
I found that article, and can do half of it.. but it talks about calling the
fSetAccessWindow function, but doesn't tell me how or where. Do you know?
THanks in advance-
 
In A97, it works in the Form_Open Event of the Startup Form. However, A97
is truly MDI while A2K & AXP are not really MDI and the code may not work in
the Open Event. You need to experiment to find out since I haven't tried it
with A2K or AXP.

Personally, I never hid the Access application window since my clients know
that I use Access to develop their databases.
 
IIRC, In the Form_Open Event Procedure of the Startup Form you simply use
the statement

Call fSetAccessWindow(SW_HIDE)

Read the warning in the article carefully. If anything goes wrong it will
be very confusing for your users.
 
Thanks Van.. hmmm... when i try this, I get an error on execute that the sub
function is not defined...
A-
 
I tried that David, and access told me that I can't use an [Event Procedure]
in the OnOpen event of the form.. (even though its right there to select!)..
Other thoughts? WHat might I be doing wrong???
 
Hey Van.. I can't seem to win... When I compile the code from the webpage, I
get the message from the VBeditor that the function called "apiShowWindow"
is throwing a compile error:

"Sub or Function not defined" ... how do I work around this I wonder?
 
I just copied the code and it worked the first time.

Did you copy the full code including the declaration:

Private Declare Function apiShowWindow Lib "user32" _
Alias "ShowWindow" (ByVal hwnd As Long, _
ByVal nCmdShow As Long) As Long

to a *Standard* module?
 
Hi again Van... you'll please pardon my ignorance.. but how do I know if the
module I created was "standard" or not? I can't find anything in the
VBeditor that says anything like that...
 
test guy said:
Hi again Van... you'll please pardon my ignorance.. but how do I know if the
module I created was "standard" or not? I can't find anything in the
VBeditor that says anything like that...

A standard module is one that is not a class module and is not attached to a form or
report (you see it on the modules tab of the db window).
 
Back
Top