XP DoCmd.Maximize OnOpen Event Problem

Sorrells

Registered User.
Local time
Today, 05:18
Joined
Jan 13, 2001
Messages
258
Hello,

I've got an interesting problem in Access XP. I am redesigning my forms to take up the entire screen and started with the Switchboard. This is happening on both the OnLoad and OnOpen events.

If I place the DoCmd.Maximize command in design mode, then open the form, I get an hourglass and cannot regain control of the program. This is occurring on two PCs with XP. I then tried it with Access97 with no problem at all.

I find this truly weird.

Somewhat new to the XP O/S, when I Ended Task (many times), the message to send the problem to Microsoft appeared. Is this a hoax? Anyway this led me to a page where I downloaded SP1 for the Office and later SP1 for XP Developer. But no help in this problem.

I'd appreciate any suggestions or if someone has run across this or if someone would replicate this and confirm that this is a problem.
 
Hello again,

Quite naturally, after a bit of rest, I returned to this immediate obstacle. My searching and web posting seeds of yesterday have yet to germinate so I returned to Access XP and its mysterious Help System.

I typed in Maximize and surprisingly obtained a response including the following text:

"Note: This action cannot be applied to code windows in the Visual Basic Editor. For information about how to affect code windows, see the WindowState property topic."

Brushing aside the obvious question of why a perfectly good VBA command would be swept aside; I entered the keyword WindowState in both the Index and Answer Wizard. The results, to me are somewhat telling of the state of the XP Help subsystem.

The Index returned nothing to the words "Window State" and "WindowState". The Wizard would not accept "WindowState" but returned 2 worthless topics to the term ""Window State". Posing my wording in an 'acceptable' question, I entered "What is the WindowState Property?" This garnered over 20 topics, all with no value for me. How did Microsoft let their Help system get into such a pathetic state?

Well, XP left me with one other possibility: a box at the bottom of the frame 'Search on the Web'. I thought this would be a real farce; and so it was. All kinds of documents of no help were offered, 73 sorted by best match. And the best match???????????? "Print the ShapeSheet in Visio 2002".

OK, so I have struck out again. The boys in Redmond are slowly but surely going to cost me my home as I continue to waste precious time trying to fix what should not have been broken.

If this story generates any emotion of sympathy ("I've been there before") and you have Access XP, Please throw a DoCmd.Maximize in the OnOpen Event of any form then open it. Perhaps I have a bad PC or a poor version of Access XP or live in a cosmic vortex! If it works for you, then at least I can feel that a solution is out there somewhere!


:confused:
 
Is anyone up for the challenge?

I need help to verify a problem with the DoCmd.Maximize command in AccessXP. This is really a simple test that would verify if my software is off or not.

1) Create a new form
2) Place in the OnOpen event the command DoCmd.Mazimize
3) Open the form
4) Respond with the result to this thread

On my PC the above will send AccessXP off in la-la land and I have to perform an EndTask to stop the application.

I wouid greatly appreciate a few responses. This is a perfectly good command in Access97. Perhaps I have a hardware or software problem. My AccessXP was installed with the MOD developer so if you have that installed also, please mention this in your reply.
 
sorry

This may not be what you want to hear...

but i have been using XP and the docmd.maximize works fine for me. Thus there is something at your end.

Instead of writing it in the property, code it in the VB code view.

not sure if that is what you were doing..

sorry again
perturbed
:(
 
yessir,

Thanks for taking a look! There is nothing to be sorry about. I am glad it works. Now I need to figure out what is wrong with my program. Do you by chance have Access XP as part of Developer? I do and think this may be part of my problem.
I'm going to take a look at WayneRyan's links, perhaps the answer lies there.
 
Sorrells,

One of the links does reference modifying code in your
switchboard and generating errors.

Wayne
 
WayneRyan and yessir,

This is most interesting. I looked at the links provided; much of which was beyond my immediate knowledge. But I did like the phrase below:

Try the docmd.maximize in the Form_Activate event of the first form. This way as soon as Form1 regains operational control, it will return to a maximized state.

I did so and it worked. I then asked myself, why not on the OnOpen event. I did so and it worked. So was I having a mental problem here?

After some contemplation, I remembered that I was attempting to maximize the opening Switchboard. My test today was on another form. I went back to the Switchboard and tested it. I could get it to open Maximized but when I tried to go into design mode, I lost control of Access. In addition, when I opened the program in 'user mode' or without the SHIFT key where the Switchboard opens automatically, I still lose control of the program.

The implication at this time is that I have something amiss in the Switchboard, must better than in Access.

If I find the actual culprit, I'll post it to close this thread. It looks to me that the solution is close by. My only remaining concern with this issue is the Help Subsystem.

" I typed in Maximize and surprisingly obtained a response including the following text: Note: This action cannot be applied to code windows in the Visual Basic Editor. For information about how to affect code windows, see the WindowState property topic."

As far as I can tell, there is no WindowState property nor does the same Help Subsystem recognize it. The above quote is what led me to quit experimenting and query this forum.
 
This continues to get more interesting. In my Switchboard in the OnOpen event, I use Ken Getz's AHDresizer code. I thought it might be the culprit, however I did have it in the form that worked without error.

I then decided to rebuild the Switchboard from scratch (copying it to another form name did not resolve the problem). I copied and pasted labels and controls and then the code until I had a duplicate form.

This duplicate would open and close with the DoCmd.Maximize with no problem. So there was something mysterious going on with the original Switchboard, right?

Well, maybe. Get this, after completing the creation of this clone form that worked, I returned to the original Switchboard to see it mess up again. Now it works without a flaw!

Well, I shall move on scratching my head, but I will keep the clone, just in case. :confused: :)
 

Users who are viewing this thread

Back
Top Bottom