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
|
Private Sub CommandButton1_Click()
Unload Me
degustation.Show
End Sub
Private Sub CheckBox1_Click()
' si elle a coché la case vrac, la case conditionnement ne peut pas etre coché
If CheckBox1.Value = True Then
CheckBox2.Value = False
Call appel_vrac
End If
End Sub
Private Sub CheckBox2_Click()
' si elle a coché la case conditionnement, la case vrac ne peut pas etre coché
If CheckBox2.Value = True Then
CheckBox1.Value = False
Call appel_conditionnement
End If
End Sub
Private Sub appel_conditionnement()
planing.Clear
planing.ColumnCount = 6
i = 4
j = 0
montant_ht = 0
planing.AddItem
planing.List(j, 0) = "Nom du produit"
planing.List(j, 1) = "Catégorie"
planing.List(j, 2) = "N°of/code"
planing.List(j, 3) = "N°de lot/N° de caisse"
planing.List(j, 4) = "Date de dégustation"
planing.List(j, 5) = "date d'entrée"
j = j + 1
Do While Worksheets("planification conditionnement").Cells(i, 1) <> ""
If Worksheets("planification conditionnement").Cells(i, 1) = Year(Now) And Worksheets("planification conditionnement").Cells(i, 2) = Month(Now) Then
planing.AddItem
planing.List(j, 0) = Worksheets("planification conditionnement").Cells(i, 5)
planing.List(j, 1) = Worksheets("planification conditionnement").Cells(i, 6)
planing.List(j, 2) = Worksheets("planification conditionnement").Cells(i, 4)
planing.List(j, 3) = Worksheets("planification conditionnement").Cells(i, 8)
planing.List(j, 4) = Worksheets("planification conditionnement").Cells(i, 3)
planing.List(j, 5) = Worksheets("planification conditionnement").Cells(i, 9)
End If
j = j + 1
i = i + 1
Loop
End Sub
Private Sub appel_vrac()
planing.Clear
planing.ColumnCount = 6
i = 4
j = 0
planing.AddItem
planing.List(j, 0) = "Nom du produit"
planing.List(j, 1) = "Catégorie"
planing.List(j, 2) = "N°of/code"
planing.List(j, 3) = "N°de lot/N° de caisse"
planing.List(j, 4) = "Date de dégustation"
planing.List(j, 5) = "date d'entrée"
j = j + 1
Do While Worksheets("planification vrac").Cells(i, 1) <> ""
If Worksheets("planification vrac").Cells(i, 1) = Year(Now) Then 'And Worksheets("planification vrac").Cells(i, 2) = Month(Now) Then
planing.AddItem
planing.List(j, 0) = Worksheets("planification vrac").Cells(i, 5)
planing.List(j, 1) = Worksheets("planification vrac").Cells(i, 6)
planing.List(j, 2) = Worksheets("planification vrac").Cells(i, 4)
planing.List(j, 3) = Worksheets("planification vrac").Cells(i, 8)
planing.List(j, 4) = Worksheets("planification vrac").Cells(i, 3)
planing.List(j, 5) = Worksheets("planification vrac").Cells(i, 9)
j = j + 1
End If
i = i + 1
Loop
End Sub
Private Sub UserForm_Click()
End Sub |
Partager