sirkülasyon
Altın Üye
- Katılım
- 10 Temmuz 2012
- Mesajlar
- 2,543
- Excel Vers. ve Dili
- 2021 LTSC TR
DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
Altın Üyelik Hakkında Bilgi
Private Sub ComboBox2_Change()
Dim Ay As Integer
If ComboBox2.Value = "Ocak" Then
eskiay = 12
eskiyil = ComboBox1.Value - 1
Ay = 1
yil = ComboBox1.Value
Label18.Caption = "Aralık"
Label33.Caption = ComboBox2.Value
Else
eskiay = ComboBox2.ListIndex
eskiyil = ComboBox1.Value
Ay = ComboBox2.ListIndex + 1
yil = ComboBox1.Value
Label18.Caption = ComboBox2.List(ComboBox2.ListIndex - 1)
Label33.Caption = ComboBox2.Value
End If
For i = 1 To 31
If ComboBox2 = "Mayıs" Or ComboBox2 = "Temmuz" Or ComboBox2 = "Ekim" Or ComboBox2 = "Aralık" Then
TextBox17.Visible = False
Label17.Visible = False
ElseIf ComboBox2 = "Mart" Then
If Day(WorksheetFunction.EoMonth(DateSerial(ComboBox1.Value, 2, 1), 0)) = 29 Then
TextBox17.Visible = False
Label17.Visible = False
TextBox16.Visible = False
Label16.Visible = False
ElseIf Day(WorksheetFunction.EoMonth(DateSerial(ComboBox1.Value, 2, 1), 0)) = 28 Then
TextBox17.Visible = False
Label17.Visible = False
TextBox16.Visible = False
Label16.Visible = False
TextBox15.Visible = False
Label15.Visible = False
End If
Else
TextBox17.Visible = True
Label17.Visible = True
TextBox16.Visible = True
Label16.Visible = True
TextBox15.Visible = True
Label15.Visible = True
End If
If Me.Controls("TextBox" & i).Visible = True Then
If i < 18 Then
If WorksheetFunction.Weekday(DateSerial(eskiyil, eskiay, Me.Controls("Label" & i).Caption), 2) > 5 Then
Me.Controls("Textbox" & i).Enabled = False
Me.Controls("Textbox" & i).BackColor = &HFF&
Else
Me.Controls("Textbox" & i).Enabled = True
Me.Controls("Textbox" & i).BackColor = &H80000005
End If
Else
If WorksheetFunction.Weekday(DateSerial(yil, Ay, Me.Controls("Label" & i + 1).Caption), 2) > 5 Then
Me.Controls("Textbox" & i).Enabled = False
Me.Controls("Textbox" & i).BackColor = &HFF&
Else
Me.Controls("Textbox" & i).Enabled = True
Me.Controls("Textbox" & i).BackColor = &H80000005
End If
End If
End If
Next
End Sub