title: How to speed up Trim Macro
body: <p>Part of my macro uses the Trim function.  It happens to be the slowest part of my macro and I'm looking to speed it up.  Does anyone have a suggestion for some code that would achieve the same ends, but faster?</p>
  
  <pre><code>Sub Trim()
  
  For Each c In Sheets("Approved Closing Data Draw").UsedRange c.Value = WorksheetFunction.Trim(c.Value) Next c
  
  For Each c In Sheets("Pipeline - Underwriting Data D").UsedRange c.Value = WorksheetFunction.Trim(c.Value) Next c
  
  For Each c In Sheets("Modifications").UsedRange c.Value = WorksheetFunction.Trim(c.Value) Next c
  
  For Each c In Sheets("Lead Data").UsedRange c.Value = WorksheetFunction.Trim(c.Value) Next c
  
  Sheets("Approved Closing Data Draw").Select
  
  End Sub
  </code></pre>