thousands comma separator in VBA

W

Wendy Francis

Hi
I have variables defined in an Excel macro as Long, and I want them to
return the value in a Word Report with thousand comma separators - is there
a way of doing this please?
Wendy Francis
[email protected]
 
S

ShaunM

Hi Wendy

You can use FormatNumber() to format your variable before you produce
your report.

eg. YourVariable = FormatNumber(YourNum, , , , vbTrue)

Regards
Shaun
 
Top