Enum TextAutonumberScheme

TextAutonumberScheme enumeration

Represents all automatic number scheme.

public enum TextAutonumberScheme

Values

NameValueDescription
None0
AlphaLcParenBoth1(a), (b), (c), …
AlphaLcParenR2a), b), c), …
AlphaLcPeriod3a., b., c., …
AlphaUcParenBoth4(A), (B), (C), …
AlphaUcParenR5A), B), C), …
AlphaUcPeriod6A., B., C., …
Arabic1Minus7Bidi Arabic 1 (AraAlpha) with ANSI minus symbol
Arabic2Minus8Bidi Arabic 2 (AraAbjad) with ANSI minus symbol
ArabicDbPeriod9Dbl-byte Arabic numbers w/ double-byte period
ArabicDbPlain10Dbl-byte Arabic numbers
ArabicParenBoth11(1), (2), (3), …
ArabicParenR121), 2), 3), …
ArabicPeriod131., 2., 3., …
ArabicPlain141, 2, 3, …
CircleNumDbPlain15Dbl-byte circle numbers (1-10 circle[0x2460-], 11-arabic numbers)
CircleNumWdBlackPlain16Wingdings black circle numbers
CircleNumWdWhitePlain17Wingdings white circle numbers (0-10 circle[0x0080-],11- arabic numbers)
Ea1ChsPeriod18EA: Simplified Chinese w/ single-byte period
Ea1ChsPlain19EA: Simplified Chinese (TypeA 1-99, TypeC 100-)
Ea1ChtPeriod20EA: Traditional Chinese w/ single-byte period
Ea1ChtPlain21EA: Traditional Chinese (TypeA 1-19, TypeC 20-)
Ea1JpnChsDbPeriod22EA: Japanese w/ double-byte period
Ea1JpnKorPeriod23EA: Japanese/Korean w/ single-byte period
Ea1JpnKorPlain24EA: Japanese/Korean (TypeC 1-)
Hebrew2Minus25Bidi Hebrew 2 with ANSI minus symbol
HindiAlpha1Period26Hindi alphabet period - consonants
HindiAlphaPeriod27Hindi alphabet period - vowels
HindiNumParenR28Hindi numerical parentheses - right
HindiNumPeriod29Hindi numerical period
RomanLcParenBoth30(i), (ii), (iii), …
RomanLcParenR31i), ii), iii), …
RomanLcPeriod32i., ii., iii., …
RomanUcParenBoth33(I), (II), (III), …
RomanUcParenR34I), II), III), …
RomanUcPeriod35I., II., III., …
ThaiAlphaParenBoth36Thai alphabet parentheses - both
ThaiAlphaParenR37Thai alphabet parentheses - right
ThaiAlphaPeriod38Thai alphabet period
ThaiNumParenBoth39Thai numerical parentheses - both
ThaiNumParenR40Thai numerical parentheses - right
ThaiNumPeriod41Thai numerical period

Examples

namespace AsposeCellsExamples
{
    using Aspose.Cells;
    using Aspose.Cells.Drawing;
    using Aspose.Cells.Drawing.Texts;
    using System;

    public class TextsClassTextAutonumberSchemeDemo
    {
        public static void Run()
        {
            // Create a new workbook
            Workbook workbook = new Workbook();
            Worksheet worksheet = workbook.Worksheets[0];

            // Add a text box to the worksheet
            int textboxIndex = worksheet.TextBoxes.Add(2, 1, 160, 200);
            Aspose.Cells.Drawing.TextBox textbox = worksheet.TextBoxes[textboxIndex];
            
            // Set text with different autonumber schemes
            textbox.Text = "Autonumber Scheme Examples:\n\n";

            // Demonstrate various TextAutonumberScheme values
            textbox.Text += GetAutonumberExample(TextAutonumberScheme.AlphaLcParenBoth, "Lowercase alpha with both parentheses");
            textbox.Text += GetAutonumberExample(TextAutonumberScheme.AlphaUcPeriod, "Uppercase alpha with period");
            textbox.Text += GetAutonumberExample(TextAutonumberScheme.ArabicParenR, "Arabic numbers with right parenthesis");
            textbox.Text += GetAutonumberExample(TextAutonumberScheme.RomanLcPeriod, "Lowercase roman numerals with period");
            textbox.Text += GetAutonumberExample(TextAutonumberScheme.CircleNumDbPlain, "Double-byte circle numbers");

            // Set paragraph with autonumber scheme
            TextParagraphCollection paragraphs = textbox.TextBody.TextParagraphs;
            TextParagraph paragraph = paragraphs[paragraphs.Count - 1];
            paragraph.Bullet.Type = BulletType.AutoNumbered;
            ((AutoNumberedBulletValue)paragraph.Bullet.BulletValue).AutonumberScheme = TextAutonumberScheme.AlphaUcParenR;
            ((AutoNumberedBulletValue)paragraph.Bullet.BulletValue).StartAt = 1;

            // Save the workbook
            workbook.Save("TextAutonumberSchemeDemo.xlsx");
        }

        private static string GetAutonumberExample(TextAutonumberScheme scheme, string description)
        {
            return $"{scheme.ToString()} ({description}):\n" +
                   "1. First item\n" +
                   "2. Second item\n" +
                   "3. Third item\n\n";
        }
    }
}

See Also