Greetings,
In my form, I have textboxes which cannot have negative values - with than in mind, I have code such as
If CDbl(PopRiskTB.Value)< 0 Then MsgBox("The value for so and so must be positive.")
That works fine when the value is negative.
The issue is, there is an option to leave the box blank and it will calculate a default value based on previously entered parameters.
So, when the user leaves the box blank, it comes up with type mismatch when performing the above check.
I tried
If CDbl(PopRiskTB.Value) < 0 And PopRiskTB.Value <> "" Then MsgBox("The value for so and so must be positive.")
Any suggestions?
Bookmarks