Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

Industrial Graphic Editor

Format string examples

  • Last UpdatedAug 30, 2024
  • 1 minute read

The following string is an example of a currency string:

String.Format("{0:$#,##0.00;($#,##0.00);Zero}", value);

This string example will output values as follows:

  • $1,240.00 if passed 1243.50.

  • ($1,240.00) if passed -1243.50.

  • The string Zero if passed the number zero.

The following string is an example of a phone number string:

String.Format("{0:(###) ###-####}", 8005551212);

This string example will output (800) 555-1212.

TitleResults for “How to create a CRG?”Also Available in