View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Vergel Adriano Vergel Adriano is offline
external usenet poster
 
Posts: 857
Default Convert a string to number

CInt(Right(Environ("UserName"), 1))

--
Hope that helps.

Vergel Adriano


"WLMPilot" wrote:

I am using "Right(Environ("UserName"), 1)" to pull the last character in the
username. This character happens to be a number. Since it is a string, I
need to know have to convert to a numeric in order to use in a formula.

Thanks