View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Keith Young[_3_] Keith Young[_3_] is offline
external usenet poster
 
Posts: 5
Default Convert Percent Entered as Text in Wksht to Number in VBA

This should be easy but am having a very difficult time.

The percent 10.00% is entered exactly as this in a worksheet cell as text.
What VBA function will convert to a number? Thought Val or CDbl would do it
but both generate an error (Type Mismatch)

Msgbox Val(Sheet1.Range("A1").value)
Msgbox CDbl(Sheet1.Range("A1").value)

Thanks in advance for your help. Keith