Thread: UDF return
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Nigel Nigel is offline
external usenet poster
 
Posts: 923
Default UDF return

use FormatPercent to create a string representation of the numeric value.

Dim x As Double, fx As String
x = 0.1235
fx = FormatPercent(x)

You can control the number of decimal values eg

fx = FromatPercent(x,4)

Cheers
Nigel


"ampm " wrote in message
...
I have a problem,

When my UDF return a value in a worksheet I need that the value will be
numerical value with format (like %).

How can I do it?

Thanks


---
Message posted from http://www.ExcelForum.com/