Private Sub RushOrder() If DateOut.SelectedDate - DateIn.SelectedDate < TimeSpan.FromDays(7) Then chkRush = True Else chkRush = False End If End Sub
Dim ts as TimeSpan = DateOut.Value - DateIn.Value If (ts.TotalDays > 7) '' Do something when difference is greater than 7 days Else '' Do something when the difference is less than 7 days End If
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)