-
Solved: return formatted number from function?
I just want to format TEST as a percentage in the following simple example. I cannot seem to get "NumberFormat" property to work. I'm new to excel so any help is appreciated.
Function TEST(x As Range) As Double
Dim cnt As Integer
Dim tmp As Double
Dim i As Integer
cnt = x.Cells.Count
tmp = 0
For i = 1 To cnt
tmp = tmp + x.Cells(i)
Next i
TEST = tmp
End Function
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules