Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
UDF return
I have a problem,
When my UDF return a value in a worksheet I need that the value will b numerical value with format (like %). How can I do it? Thank -- Message posted from http://www.ExcelForum.com |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
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/ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
UDF return
Hi
I would suggest to format the target cell as percentage and just return the correct numerical value. I wouldn't return a string as this may be problematic in further calculations -- Regards Frank Kabel Frankfurt, Germany 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/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Return date if in range, else return blank | Excel Worksheet Functions | |||
Compare Value in Cell 1 to a List, Return Value if Match otherwise Return Null | Excel Discussion (Misc queries) | |||
LOOKUP and return the column heading for IF/THEN return for False | Excel Discussion (Misc queries) | |||
check if reference exists, then return its value or return 0 | Excel Worksheet Functions | |||
VBA Syntax for VLOOKUP to return array of return values | Excel Programming |