I plan on giving members encoded numbers added to the end of a URL. (e.g.(http://homesite/valid.asp?mem_no=123456
The page does a calculation and does a SQL query on a db.
Problem is if an incorrect number is entered, a long may result, so I bypass the query (as it will only work with integers and longs). However, the calculated values are all returning doubles, even when they are integers or longs.
I am using statement:
if vartype(mem_no) = 3 or if vartype(mem_no) = 2
which I hoped would weed out non-valid numbers, but it's weeding them all out.
I'm hoping you can point to a more elegant solution.