Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin

...

Description

Excerpt

Creates a string for displaying percentages.

Signature
C#
C#
 public System.String CreatePercentage(int numDecimalPlaces)
{signature}{signature:
}
Signature
vb.net
vb.net
Public Function CreatePercentage(ByVal numDecimalPlaces As Integer) As String
{signature}
{parameters}
{param:numDecimalPlaces}The number of decimal places to display.{param}
{returns}A format string for percentages.{returns}
{example}{code:csharp|title=C#}
Parameters
Param
numDecimalPlaces
numDecimalPlaces

The number of decimal places to display.

Returns

A format string for percentages.

Example
Code Block
csharp
csharp
titleC#


          //--- Create a style.
          Style styl = wb.CreateStyle();

          //--- Create the percentage format "0.000%".
          styl.NumberFormat = wb.NumberFormat.CreatePercentage(3);
        
{code} {code:
Code Block
vb.net
|title=
vb.net
titlevb.net
}


          '--- Create a style.
          Dim styl As Style = wb.CreateStyle()

          '--- Create the percentage format "0.000%".
          styl.NumberFormat = wb.NumberFormat.CreatePercentage(3)
        
{code} {example}