MuscatMimi
XLDnaute Accro
Bonsoir tous
J'aimerais savoir s'il est possible de modifier ce code ,afin que je ne soit pas obligé de noter les noms de compte dans le Code
Private Sub CbxN°Compte_Change()
If CbxN°Compte <> "Christian" Then 'Cbx N° Compte
TextBox5.Visible = False 'TextBox compte1
BtnCpte1.Visible = False
Label1.Visible = False
End If
If CbxN°Compte = "Christian" Then
TextBox5.Visible = True
Label1.Visible = True
Label1 = CbxN°Compte
BtnCpte1.Visible = True
End If
'========
If CbxN°Compte <> "Nicole" Then 'Cbx N° Compte
TextBox6.Visible = False 'TextBox compte2
BtnCpte2.Visible = False
Label2.Visible = False
End If
If CbxN°Compte = "Nicole" Then
TextBox6.Visible = True
Label2.Visible = True
Label2 = CbxN°Compte
BtnCpte2.Visible = True
End If
'=====================
If CbxN°Compte <> "Toto" Then 'Cbx N° Compte
TextBox7.Visible = False 'TextBox compte1
BtnCpte3.Visible = False
Label3.Visible = False
End If
If CbxN°Compte = "Toto" Then
TextBox7.Visible = True
Label3.Visible = True
Label3 = CbxN°Compte
BtnCpte3.Visible = True
End If
'=============
If CbxN°Compte <> "Titi" Then 'Cbx N° Compte
TextBox8.Visible = False 'TextBox compte1
BtnCpte4.Visible = False
Label4.Visible = False
End If
If CbxN°Compte = "Titi" Then
TextBox8.Visible = True
Label4.Visible = True
Label4 = CbxN°Compte
BtnCpte4.Visible = True
End If
End Sub
Bonne soirée a tous
ciaooooo
J'aimerais savoir s'il est possible de modifier ce code ,afin que je ne soit pas obligé de noter les noms de compte dans le Code
Private Sub CbxN°Compte_Change()
If CbxN°Compte <> "Christian" Then 'Cbx N° Compte
TextBox5.Visible = False 'TextBox compte1
BtnCpte1.Visible = False
Label1.Visible = False
End If
If CbxN°Compte = "Christian" Then
TextBox5.Visible = True
Label1.Visible = True
Label1 = CbxN°Compte
BtnCpte1.Visible = True
End If
'========
If CbxN°Compte <> "Nicole" Then 'Cbx N° Compte
TextBox6.Visible = False 'TextBox compte2
BtnCpte2.Visible = False
Label2.Visible = False
End If
If CbxN°Compte = "Nicole" Then
TextBox6.Visible = True
Label2.Visible = True
Label2 = CbxN°Compte
BtnCpte2.Visible = True
End If
'=====================
If CbxN°Compte <> "Toto" Then 'Cbx N° Compte
TextBox7.Visible = False 'TextBox compte1
BtnCpte3.Visible = False
Label3.Visible = False
End If
If CbxN°Compte = "Toto" Then
TextBox7.Visible = True
Label3.Visible = True
Label3 = CbxN°Compte
BtnCpte3.Visible = True
End If
'=============
If CbxN°Compte <> "Titi" Then 'Cbx N° Compte
TextBox8.Visible = False 'TextBox compte1
BtnCpte4.Visible = False
Label4.Visible = False
End If
If CbxN°Compte = "Titi" Then
TextBox8.Visible = True
Label4.Visible = True
Label4 = CbxN°Compte
BtnCpte4.Visible = True
End If
End Sub
Bonne soirée a tous
ciaooooo