|
-
Dec 12th, 2000, 01:36 AM
#1
Thread Starter
Frenzied Member
Hey all.
what is happening here?
I have two forms and I'm using the same code I've used 100s of times before to switch back and forth.
On formA, a button click event:
Load formB
formB.Show
Unload formA
On formB, a button click event:
Load formA
formA.Show
Unload formB
Isn't that what everybody does?
Well, I don't know what's happening here, but I have a case where formB loads but it won't unload. When I click to formB, it appears and A unloads. But then when i click back to A, formB is still there, behind formA. I don't know why! I've tried several things:
in the queryunload, I put Set formB = Nothing
I've typed unload formB several times in the code
At runtime, when the form is still visible behind formA, I can close it by clicking on its X block ( after the first try at closing via the button). Or I can leave via the xblock on the form (and put a Load formA in the queryunload sub). But I'm really just wondering what would cause this.
Oh, I am using a Form_MouseMove sub but I used a boolean to exit this sub if the form changing button is pressed.
Ideas?
Thanks
Wengang
Wen Gang, Programmer
VB6, QB, HTML, ASP, VBScript, Visual C++, Java
-
Dec 12th, 2000, 09:53 PM
#2
Fanatic Member
Just rem out your code in the mouse_move and see if it still plays up...
Pretty sure it's in there somewhere
DocZaf
{;->
-
Dec 12th, 2000, 10:01 PM
#3
Addicted Member
Put the Unload statement before the .Show method and see.
And make sure they are not Modal forms (We can see they are not from your code).
-
Dec 13th, 2000, 03:05 AM
#4
There is nothing wrong with the code you submitted so it has to be somewhere else.
If possible post all of your code so that people around here can have a look at it.
Best regards
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|