I've been working on some code that needs to sort measurements as doubles. I am forced to use a bunch of If..Then statements to figure out which bucket the value goes into. It works but it just looks bad. What would be nice is to use a Select...Case structure but I would have to call out every value. It sure would be nice if I could use:
...and have 1.72341 fall into bucket "A".
Dim a As Double a=1.72341 Select a Case 0 to 2 Log ("A") Case 2 to 4 Log ("B") Case Else Log ("C") End Select