Use
vNumber = Val(strNumber)
Or
vNumber = CInt(strNumber)
Val() and CInt() have slightly different functionality for unusual
conditions.
For example, CInt(“234a”) returns an error, while Val(“234a”) returns 234.
It’s up to you which one is more appropriate in your application.
There’s also CLng() to convert to a Long (and CBool() to convert to Boolean,
CSng() to convert to Single, CDbl() to convert to Double, CStr() to convert
to String, CDate() to convert to Date, etc.).