@MDarwish, you mean like this:
Here's my code:
Dim com As New SqlCommand("SELECT * FROM tblJOL")
If txtShipoutDatePlan.Text <> "" Then
If com.Parameters.Add("DRsda", SqlDbType.VarChar).Value Then
Dim dateValueSDA As Date
dateValueSDA = txtShipoutDateActual.Text
lblDaysda.Text = WeekdayName(Weekday(dateValueSDA))
End If
Else
com.Parameters.Add("DRsda", SqlDbType.VarChar).Value = DBNull.Value
End If