title: Formatting a field using ToText in a Crystal Reports formula field
body: <p>I'm trying to create a Crystal Reports formula field (to calculate the percentage change in a price) that will return "N/A" if a particular report field is null, but return a number to two decimal places using accounting format (negative numbers surrounded by parentheses) if it is not.</p>
  
  <p>The closest I have been able to manage is this:</p>
  
  <pre><code>If IsNull({ValuationReport.YestPrice}) Then
      'N/A'
  Else
      ToText({@Price}/{ValuationReport.YestPrice}*100-100, '###.00', 2)
  </code></pre>
  
  <p>However this represents negative numbers using a negative sign, not parentheses. </p>
  
  <p>I tried format strings like '###.00;(###.00)' and '(###.00)' but these were rejected as invalid. How can I achieve my goal?</p>