|
-
Sep 14th, 2001, 09:57 AM
#1
Thread Starter
New Member
me.hide form.visible commands
What is really the major diff. between these commands below...can you provide examples & circumstances?
Thanks!!
me.hide
form2.show
vs.
form.visible=false
form2.show
I mean is there any major diffs. hiding a form vs. making it invisible? I can still pull data from form1 even if its hidden vs. invisible.
-
Sep 14th, 2001, 10:04 AM
#2
PowerPoster
No major difference, and yes you can get data from controls on invisible forms.
-
Sep 14th, 2001, 10:05 AM
#3
Frenzied Member
Hide Method
Hides an MDIForm or Form object but doesn't unload it.
Syntax
object.Hide
The object placeholder represents anobject expression that evaluates to an object in the Applies To list. If object is omitted, the form with thefocus is assumed to be object.
Remarks
When a form is hidden, it's removed from the screen and its Visible property is set to False. A hidden form's controls aren't accessible to the user, but they are available to the running Visual Basic application, to other processes that may be communicating with the application through DDE, and to Timer control events.
When a form is hidden, the user can't interact with the application until all code in the event procedure that caused the form to be hidden has finished executing.
If the form isn't loaded when the Hide method is invoked, the Hide method loads the form but doesn't display it.
Note When closing a modal form that has been opened from another modal form, the following code worked in previous versions of Visual Basic:
Me.Hide
Me.Hide ' This now causes an error.
In current versions of Visual Basic, this code now fails on the second Me.Hide. You can substitute Me.Hide with Me.Visible = False as shown below:
Me.Visible = False
Me.Visible = False ' No error occurs.
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
|