vendredi 25 janvier 2019

is it recommended to have more than one condition in my if statement?

i currently am writing a if statement with a couple of conditions. is there a better or efficient way to write what i have now? Is writing separate if statements better?

If (txtNumberOfVehicles.Text = String.Empty OrElse Not IsNumeric(txtNumberOfVehicles.Text) OrElse CInt(txtNumberOfVehicles.Text) < 0) Then ... End If

Aucun commentaire:

Enregistrer un commentaire