title: Word VBA format number in a Table cell - cell text unrecognized
body: <p>I'm constructing a Word doc from VBA (Excel) with Excel table data.
  The data was placed in the table OK.
  The last column has numbers (e.g. 456789) That I want to number-format (e.g. $456,789).</p>
  
  <p>Word adds chr(13) and chr(7) at the end of each table cell value (so that the length of the visible value 456789 is not 6 but 8).</p>
  
  <p>Without the Replace statement below to eliminate these two chars I could not treat the value as a string and further manipulate.</p>
  
  <p>Is this the best way vba has to offer for accessing table cells values as a standard type such as String? Why do I need to eliminate the ending chars in the process? what am I missing?</p>
  
  <pre><code>        For Each cell In .Columns(3).Cells
              strCellValue = CStr(cell.Range.Text)
              strCellValue = Replace(strCellValue, Chr(13) &amp; Chr(7), "")
              If IsNumeric(strCellValue) Then
                  cell.Range.Text = Format(strCellValue, "$#,##0")
              End If
          Next
  </code></pre>
  
  <p>Thanks!</p>