Hi All
I have devloped following Code and I need your help reagrding how to extrct data as per those checkboxes are checked.
[/COLOR]
I can not solve last red line code that how to code that if checkbox1 is checked then code extrcts checkbox1 data or if checkbox1 and checkbox2 are checked then extract both zone data.
I hope you understand that how could a user change seclection to extract data.
Thanks in advance
I have devloped following Code and I need your help reagrding how to extrct data as per those checkboxes are checked.
Code:
With UserForm2
.Show
fdate = .ComboBox1.Value
If .CheckBox1.Value = True Then F1 = .CheckBox1.Caption
If .CheckBox2.Value = True Then F2= .CheckBox2.Caption
If .CheckBox3.Value = True Then F3 = .CheckBox3.Caption
End With
Unload UserForm2
ReDim b(1 To UBound(a, 1), 1 To UBound(a, 2))
'fdate = Format(Sheets("DPS").Range("b19"), "mmm-yy")
' Prod = Sheets("DPS").Range("c19")
With CreateObject("Scripting.Dictionary")
.CompareMode = vbTextCompare
For i = 1 To UBound(a, 1)
[COLOR=red] [COLOR=black]If (Not IsEmpty(a(i, 8))) * (IsDate(a(i, 8))) * (Format(a(i, 8),[/COLOR] "[COLOR=black]mmm-yy") = fdate) * (a(i, 5) <> "B")[/COLOR] * (a(i, 4) = F1) Then
I can not solve last red line code that how to code that if checkbox1 is checked then code extrcts checkbox1 data or if checkbox1 and checkbox2 are checked then extract both zone data.
I hope you understand that how could a user change seclection to extract data.
Thanks in advance