si usas el componente Microsoft Calendar esto te cuenta los dias que tiene el mes actual
Código PHP:
Dim VTotal As Integer
mes = CStr(Cal.Month)
mes_actual = Mid(Format(Date, "DD/MM/YYYY"), 5, 1)
Cal.Day = 1
VTotal = 0
For i = 1 To 31
If mes = mes_actual Then
VTotal = VTotal + 1
mes = CStr(Cal.Month)
Cal.NextDay
End If
Next i
MsgBox VTotal - 1
salu2