Dim StrSearch$
'protocole adapté
Private Sub Combo_prot_ini_Change()
With usf
With .Combo_prot_ini
StrSearch = .Text
End With
For i = 1 To 16
With .Controls("Text_vit" & i & "_ini")
.Enabled = IIf(StrSeach = "Protocole adapté", True, False)
.BackColor = IIf( StrSearch = "Protocole adapté", &H80000005, &H80000004)
End With
With .Controls("Text_pente" & i & "_ini")
.Enabled = IIf( StrSearch= "Protocole adapté", True, False)
.BackColor = IIf( StrSearch = "Protocole adapté", &H80000005, &H80000004)
End With
Next i
End With
End Sub
Private Sub Combo_prot_fin_Change()
With usf
With .Combo_prot_fin
StrSearch = .Text
End With
For i = 1 To 16
With .Controls("Text_vit" & i & "_fin")
.Enabled = IIf(StrSeach = "Protocole adapté", True, False)
.BackColor = IIf( StrSearch = "Protocole adapté", &H80000005, &H80000004)
End With
With .Controls("Text_pente" & i & "_fin")
.Enabled = IIf( StrSearch = "Protocole adapté", True, False)
.BackColor = IIf( StrSearch = "Protocole adapté", &H80000005, &H80000004)
End With
Next i
End With
End Sub
'fin protocole adapté
'Tapis roulant vs ergomètre
Private Sub Combo_app_fin_Change()
With usf
With Combo_app_fin
StrSearch = .Text
End With
With .Text_vit_ergo_max_fin
.Enabled = IIf( StrSearch = "Tapis roulant", False, True)
.BackColor = IIf( StrSearch = "Tapis roulant", &H80000004, &H80000005)
End With
With .Text_charge_ergo_max_fin
.Enabled = IIf( StrSearch = "Tapis roulant", False, True)
.BackColor = IIf( StrSearch = "Tapis roulant", &H80000004, &H80000005)
End With
With .Text_vit_tapis_max_fin
.Enabled = IIf( StrSearch = "Tapis roulant", False, True)
.BackColor = IIf( StrSearch = "Tapis roulant", &H80000004, &H80000005)
End With
With .Text_pente_max_fin
.Enabled = IIf( StrSearch = "Tapis roulant", False, True)
.BackColor = IIf( StrSearch = "Tapis roulant", &H80000004, &H80000005)
End With
End With
End Sub
Private Sub Combo_app_ini_Change()
With usf
With .Combo_app_ini
StrSearch = .Text
End With
With .Text_vit_ergo_max_ini
.Enabled = IIf( StrSearch = "Tapis roulant", False, True)
.BackColor = IIf( StrSearch = "Tapis roulant", &H80000004, &H80000005)
End With
With .Text_charge_ergo_max_ini
.Enabled = IIf( StrSearch = "Tapis roulant", False, True)
.BackColor = IIf( StrSearch = "Tapis roulant", &H80000004, &H80000005)
End With
With .Text_vit_tapis_max_ini
.Enabled = IIf( StrSearch = "Tapis roulant", False, True)
.BackColor = IIf( StrSearch = "Tapis roulant", &H80000004, &H80000005)
End With
With .Text_pente_max_ini
.Enabled = IIf( StrSearch = "Tapis roulant", False, True)
.BackColor = IIf( StrSearch = "Tapis roulant", &H80000004, &H80000005)
End With
End With
End Sub