FormatPercent [VBA]
        Returns a string with a number formatting applied to a numeric expression. A percent sign is appended to the returned string.
    
    
    
This constant, function or object is enabled with the statement Option VBASupport 1 placed before the executable program code in a module.
 
 
    
    
      FormatPercent( expression, [numDigitsAfterDecimal As Integer], [includeLeadingDigit As Integer], _
          [useParensForNegativeNumbers As Integer], [groupDigits As Integer] ) As String
    
    
    String
    
    expression: Required. A numeric expression to be formatted. If expression is a string, then the decimal and thousands separator need to be localized.
    numDigitsAfterDecimal: не обов'язково. Числове значення, що вказує кількість цифр, які слід відображати після десяткової коми. Якщо опущено, застосовується значення -1, тобто використовуються типові параметри локалі інтерфейсу користувача.
    includeLeadingDigit: не обов'язково. Значення з переліку vbTriState, що вказує, чи повинен виводитися нуль на початку дробових значень.
    
        - 
            vbTrue або -1: показувати нуль на початку. 
- 
            vbFalse або 0: не показувати нуль на початку. 
- 
            vbUseDefault or -2: Use the user interface locale settings. This is the default when omitted. 
useParensForNegativeNumbers: не обов'язково. Значення з переліку vbTriState, що вказує, чи повинні від'ємні числа братися в дужки.
    
        - 
            vbTrue або -1: брати від'ємні числа в дужки. 
- 
            vbFalse або 0: не брати в дужки. 
- 
            vbUseDefault or -2: Same as vbFalse. This is the default when omitted. 
groupDigits: не обов'язково. Значення з переліку vbTriState, яке вказує, чи треба згрупувати цифри (тисячі і т. д.), використовуючи розділювач груп, вказаний у регіональних налаштуваннях системи.
    
        - 
            vbTrue або -1: групувати цифри. 
- 
            vbFalse або 0: не групувати цифри. 
- 
            vbUseDefault or -2: Same as vbFalse. This is the default when omitted. 
 
    
    13 Невідповідність типів даних
        Sub TestFormatNumber
          Const UseComputerRegionalSettings = -1
          MsgBox FormatPercent(12.2, NumDigitsAfterDecimal:=2) ' 1220.00% if selected user interface is english
          MsgBox FormatPercent("-,2", 2, IncludeLeadingDigit:=vbTrue) ' -20,00% if french user interface
          MsgBox FormatPercent("-0.2", 2) ' -20.00% for en-US, -0,00 for fr-CA, de-AT or pt-BR
          MsgBox FormatPercent(-0.2, UseComputerRegionalSettings, UseParensForNegativeNumbers:=vbTrue) ' (20,00)% if pt-BR
          MsgBox FormatPercent("-0,2", UseComputerRegionalSettings, vbUseDefault, vbTrue) ' (20,00)% if german
          MsgBox FormatPercent("-12345678", -1, vbUseDefault, vbUseDefault, GroupDigits:=vbTrue) ' -1 234 567 800,00% for fr-BE
        End Sub