12 tane textbox ve bir tanedede bu günün tarihini gösteren textboxım var. m kolonunda erkek yazıyorsa ve bugünün tarihi 01./07/2009 ile31/07/2009 arasında kalıyorsa erkek yazan kaç tane ise texbox17 ye at bugüntarihi texbox24 te yazıyor.yani textbox24 hangi tarihi gösteriyorsa aşağıda kodlarla anlatım ama yanlış bişey var yardımcı olrsanız sevinirim.
u = WorksheetFunction.CountIf(Worksheets("sayfa1").Range("M2:M5550"), "ERKEK")
If 1 / 1 / 2009 >= TextBox24.Value < =31 / 1 / 2009 Then
TextBox11.Value = u
Else
If 1 / 2 / 2009 = TextBox24.Value =28 / 2 / 2009 Then
TextBox12.Value = u
Else
If 1 / 3 / 2009 = TextBox24.Value = 31 / 3 / 2009 Then
TextBox13.Value = u
Else
If 1 / 4 / 2009 = TextBox24.Value = 30 / 4 / 2009 Then
TextBox14.Value = u
Else
If 1 / 5 / 2009 = TextBox24.Value = 31 / 5 / 2009 Then
TextBox15.Value = u
Else
If 1 / 6 / 2009 = TextBox24.Value = 30 / 6 / 2009 Then
TextBox16.Value = u
Else
If 1 / 7 / 2009 < TextBox24.Value < 31 / 7 / 2009 Then
TextBox17.Value = u
Else
If 1 / 8 / 2009 = TextBox24.Value = 31 / 8 / 2009 Then
TextBox18.Value = u
Else
If 1 / 9 / 2009 = TextBox24.Value = 30 / 9 / 2009 Then
TextBox19.Value = u
Else
If 1 / 10 / 2009 = TextBox24.Value = 31 / 10 / 2009 Then
TextBox20.Value = u
Else
If 1 / 11 / 2009 = TextBox24.Value = 30 / 11 / 2009 Then
TextBox21.Value = u
Else
If 1 / 12 / 2009 = TextBox24.Value = 31 / 12 / 2009 Then
TextBox22.Value = u
Else
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End Sub
u = WorksheetFunction.CountIf(Worksheets("sayfa1").Range("M2:M5550"), "ERKEK")
If 1 / 1 / 2009 >= TextBox24.Value < =31 / 1 / 2009 Then
TextBox11.Value = u
Else
If 1 / 2 / 2009 = TextBox24.Value =28 / 2 / 2009 Then
TextBox12.Value = u
Else
If 1 / 3 / 2009 = TextBox24.Value = 31 / 3 / 2009 Then
TextBox13.Value = u
Else
If 1 / 4 / 2009 = TextBox24.Value = 30 / 4 / 2009 Then
TextBox14.Value = u
Else
If 1 / 5 / 2009 = TextBox24.Value = 31 / 5 / 2009 Then
TextBox15.Value = u
Else
If 1 / 6 / 2009 = TextBox24.Value = 30 / 6 / 2009 Then
TextBox16.Value = u
Else
If 1 / 7 / 2009 < TextBox24.Value < 31 / 7 / 2009 Then
TextBox17.Value = u
Else
If 1 / 8 / 2009 = TextBox24.Value = 31 / 8 / 2009 Then
TextBox18.Value = u
Else
If 1 / 9 / 2009 = TextBox24.Value = 30 / 9 / 2009 Then
TextBox19.Value = u
Else
If 1 / 10 / 2009 = TextBox24.Value = 31 / 10 / 2009 Then
TextBox20.Value = u
Else
If 1 / 11 / 2009 = TextBox24.Value = 30 / 11 / 2009 Then
TextBox21.Value = u
Else
If 1 / 12 / 2009 = TextBox24.Value = 31 / 12 / 2009 Then
TextBox22.Value = u
Else
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End Sub
Son düzenleme:
