1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107
|
'Supprimer la croix'
Private Declare PtrSafe Function GetWindowLongA Lib "User32" (ByVal hWnd As Long, ByVal nIndex As Long) As Long
Private Declare PtrSafe Function SetWindowLongA Lib "User32" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal dwNewLong As Long) As Long
Private Declare PtrSafe Function FindWindowA Lib "User32" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Private Sub UserForm_Initialize()
Dim hWnd As Long
hWnd = FindWindowA("Thunder" & IIf(Application.Version Like "8*", "X", "D") & "Frame", Me.Caption)
SetWindowLongA hWnd, -16, GetWindowLongA(hWnd, -16) And &HFFF7FFFF
ComboBox3.AddItem "secondes"
ComboBox3.AddItem "minutes"
ComboBox3.AddItem "heures"
ComboBox3.AddItem "jours"
ComboBox3.AddItem "années"
ComboBox2.AddItem "Lambda"
ComboBox2.AddItem "T1/2"
TextBox1.Value = ""
TextBox1.SetFocus
TextBox2.Value = ""
TextBox2.SetFocus
End Sub
Private Sub CommandButton2_Click()
Unload Me
choixetude.Show
End Sub
Private Sub textbox3_change()
If Not (IsNumeric(TextBox3)) Then
MsgBox "Valeur numérique SVP", vbOKOnly + vbCritical, "Erreur"
TextBox3.SetFocus
Else
Varrad = TextBox3.Value
End If
End Sub
Private Sub TextBox6_Change()
If Not (IsNumeric(TextBox6)) Then
MsgBox "Valeur numérique SVP", vbOKOnly + vbCritical, "Erreur"
TextBox6.SetFocus
Else
T = TextBox6.Value
End If
End Sub
Private Sub TextBox4_Change()
If Not (IsNumeric(TextBox4)) Then
MsgBox "Valeur numérique SVP", vbOKOnly + vbCritical, "Erreur"
TextBox4.SetFocus
Else
A0 = TextBox4.Value
End If
End Sub
Private Sub TextBox5_Change()
If Not (IsNumeric(TextBox5)) Then
MsgBox "Valeur numérique SVP", vbOKOnly + vbCritical, "Erreur"
TextBox5.SetFocus
Else
A = TextBox5.Value
End If
End Sub
Private Sub ComboBox3_Change()
basetemps = ComboBox3.Value
End Sub
Private Sub ComboBox2_Change()
Choixrad = ComboBox2.Value
End Sub
Private Sub CommandButton1_Click()
If Not (IsNumeric(TextBox3)) Then
MsgBox "Valeur numérique poue la variable lambda ou T1/2 SVP", vbOKOnly + vbCritical, "Erreur"
TextBox3.SetFocus
Else
If Not (IsNumeric(TextBox4)) Then
MsgBox "Valeur numérique pour la Valeur de l'Activité A0 SVP", vbOKOnly + vbCritical, "Erreur"
TextBox4.SetFocus
Else
If Not (IsNumeric(TextBox5)) Then
MsgBox "Valeur numérique pour la valeur de l'activité A SVP", vbOKOnly + vbCritical, "Erreur"
TextBox5.SetFocus
Else
If Not (IsNumeric(TextBox6)) Then
MsgBox "Valeur numérique pour la valeur de T A SVP", vbOKOnly + vbCritical, "Erreur"
TextBox6.SetFocus
Else
Unload Me
ResultatT.Show
End If
End If
End If
End If
End Sub |
Partager