Running a macro containing the following code will format all of the cells
that are selected in that way:
Dim numrange As Range, cellrange As Range
Dim i As Long
Set cellrange = Selection.Range
For i = 1 To cellrange.Cells.Count
Set numrange = cellrange.Cells(i).Range
numrange.End = numrange.End - 1
If IsNumeric(numrange.Text) Then
numrange.Text = Format(numrange.Text, "#,###")
End If
Next i
See the article "What do I do with macros sent to me by other newsgroup
readers to help me out?†at:
http://www.word.mvps.org/FAQs/MacrosVBA/CreateAMacro.htm
--
Hope this helps.
Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.
Doug Robbins - Word MVP, originally posted via msnews.microsoft.com