title: VB6 Format equivalent in C#
body: <p>I am converting some VB6 code to C# and am having a problem duplicating certain functionality. I have a string representation of a number ex.6000 and a format specifier of ex. ###0.000.</p>
  
  <p>VB6 Example:</p>
  
  <pre><code>Format(number, "########0.000") = "6.000"
  </code></pre>
  
  <p>I am having trouble finding the C# equivalent to duplicate this functionality. The methods I have tried with <code>ToString()</code> but they are more for formatting the actual number rather than more of an overlay format like VB6 is doing.</p>
  
  <p>C# Example:</p>
  
  <pre><code>number.ToString("########0.000", CultureInfo.InvariantCulture) = 6000.000
  </code></pre>