|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| |||||||||
| View Poll Results: Do u think this to be a basic level Question ?? | |||
| YES | | 1 | 100.00% |
| NO | | 0 | 0% |
| It a medium range Question. | | 0 | 0% |
| Voters: 1. You may not vote on this poll | |||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Controling Text Box of Form2 from Form1.
Hi all,
I want to enable and disable a textbox in form2 from a command button in form1. Please help me.. ![]() |
|
#2
|
||||
|
||||
|
Example:
Form1 Code:
Private Sub Button1_Click(blah, blah) gblnDisplayTextBox = False End Sub Form2 Code:
Private Sub Form_Load(blah, blah) TextBox1.Visible = gblnDisplayTextBox End Sub Module Code:
Module GlobalVariables Dim gblnDisplayTextBox As Boolean End Module |
|
#3
|
|||
|
|||
|
Code:
Private Sub Command1_Click() If Form2.Text1.Visible = False Then Form2.Text1.Visible = True Else Form2.Text1.Visible = False End If End Sub ^ That should work too. 2 Forms Form1 and Form2 Command Button placed on Form1(Code above) textbox (Text1) placed on Form2. Checks to see if its visible, if it is, it will make it invisible, if its not visible, it will make it visible. |
![]() |
| Viewing: ASP Free Forums > Programming > Visual Basic Programming > Controling Text Box of Form2 from Form1. |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|