Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
Private Sub CommandButton2_Click()
Dim a As Variant
a = WorksheetFunction.SumProduct((" & RefEdit1.Value & " = " & RefEdit2.Value & ") * (" & RefEdit3.Value & " = " & RefEdit4.Value & ") * (" & RefEdit5.Value & " + " & RefEdit6.Value & "))
TextBox1.Text = a
End Sub
.................................
Private sub commandButton1_click()
Dim a,b as stringe
Dim r as double
A=userform1.refedit1.value
B=userform1.refedit2.value
R=worksheetfunction.sumproduct((range(a)=textbox1.text)*(range(b)=textbox2.text)*(‘’ & refedit3.value & ‘’ = ‘’ & refedit4.value&’’))
Msgbox r
End sub