OrderedList.GetOverFlowList

Overloads

GetOverFlowList()Gets a OrderedList object containing the List Text.
GetOverFlowList(Single, Single)Gets a OrderedList object containing the List Text.

GetOverFlowList()

Gets a OrderedList object containing the List Text.

public OrderedList GetOverFlowList()
Function GetOverFlowList() As OrderedList

Returns

OrderedList

Returns a OrderedList object.

Licensing Info

This method is a full DynamicPDF Core Suite feature. One of the following is required for non-evaluation usage:

Examples

The following example shows you how to use the GetOverflowList object to allow text of variable length to flow onto new pages as needed.
using System;
using ceTe.DynamicPDF;
using ceTe.DynamicPDF.PageElements;

public class Example
{
    public static void CreatePDF(string outputPath)
	{
        Document document = new Document();

        // Create a Page.
        Page page = new Page();

        // Create a OrderedList.
        OrderedList list = new OrderedList(50, 50, 300, 250);

        list.ListItemTopMargin = 5;
        list.ListItemBottomMargin = 5;
        list.BulletPrefix = "(";
        list.BulletSuffix = ")";
        list.TextColor = RgbColor.BlueViolet;

        // Add ListItem to the List.
        ListItem item1 = list.Items.Add("List item 1");
        item1.Underline = true;
        ListItem item2 = list.Items.Add("List item 2");
        item2.Underline = true;
        ListItem item3 = list.Items.Add("List item 3");
        item3.Underline = true;
        ListItem item4 = list.Items.Add("List item 4");
        item4.Underline = true;

        // Add OrderedSubList under ListItem item1
        OrderedSubList subList1 = item1.SubLists.AddOrderedSubList(NumberingStyle.RomanUpperCase);
        subList1.TextColor = RgbColor.HotPink;
        ListItem item5 = subList1.Items.Add("Sub-list item 1");
        ListItem item6 = subList1.Items.Add("Sub-list item 2");

        OrderedSubList subList2 = item5.SubLists.AddOrderedSubList(NumberingStyle.AlphabeticLowerCase);
        subList2.TextColor = RgbColor.DarkGoldenRod;
        ListItem item7 = subList2.Items.Add("Second level sub-list item 1");
        ListItem item8 = subList2.Items.Add("Second level sub-list item 2");

        OrderedSubList subList3 = item6.SubLists.AddOrderedSubList(NumberingStyle.AlphabeticLowerCase);
        subList3.TextColor = RgbColor.DarkGoldenRod;
        ListItem item9 = subList3.Items.Add("Second level sub-list item 1");
        ListItem item10 = subList3.Items.Add("Second level sub-list item 2");

        OrderedSubList subList4 = item2.SubLists.AddOrderedSubList(NumberingStyle.RomanUpperCase);
        subList4.TextColor = RgbColor.HotPink;
        ListItem item11 = subList4.Items.Add("Sub-list item 1");
        ListItem item12 = subList4.Items.Add("Sub-list item 2");

        OrderedSubList subList5 = item11.SubLists.AddOrderedSubList(NumberingStyle.AlphabeticLowerCase);
        subList5.TextColor = RgbColor.DarkGoldenRod;
        ListItem item13 = subList5.Items.Add("Second level sub-list item 1");
        ListItem item14 = subList5.Items.Add("Second level sub-list item 2");

        OrderedSubList subList6 = item12.SubLists.AddOrderedSubList(NumberingStyle.AlphabeticLowerCase);
        subList6.TextColor = RgbColor.DarkGoldenRod;
        ListItem item15 = subList6.Items.Add("Second level sub-list item 1");
        ListItem item16 = subList6.Items.Add("Second level sub-list item 2");

        OrderedSubList subList7 = item3.SubLists.AddOrderedSubList(NumberingStyle.RomanUpperCase);
        subList7.TextColor = RgbColor.HotPink;
        ListItem item17 = subList7.Items.Add("Sub-list item 1");
        ListItem item18 = subList7.Items.Add("Sub-list item 2");

        // Add the OrderedList to the page
        page.Elements.Add(list);

        // Add the Page to the Document.
        document.Pages.Add(page);

        // if all the text did fit, GetOverflowList will return null
        list = list.GetOverFlowList();

        while (list != null)
        {
            page = new Page(PageSize.A4);
            page.Elements.Add(list);
            document.Pages.Add(page);
            list = list.GetOverFlowList();
        }
        //save the PDF.
        document.Draw(outputPath);
	}
}

Remarks

This method returns a new OrderedList object that contains the remaining text that did not fit.

GetOverFlowList(Single, Single)

Gets a OrderedList object containing the List Text.

public OrderedList GetOverFlowList(float x, float y)
Function GetOverFlowList(x As Single, y As Single) As OrderedList

Parameters

x
Single

New X coordinate of the OrderedList.

y
Single

New Y coordinate of the OrderedList.

Returns

OrderedList

Returns a OrderedList object.

Licensing Info

This method is a full DynamicPDF Core Suite feature. One of the following is required for non-evaluation usage:

Examples

The following example shows you how to use the GetOverflowList object to allow text of variable length to flow onto new pages as needed.
using System;
using ceTe.DynamicPDF;
using ceTe.DynamicPDF.PageElements;

public class Example
{
    public static void CreatePDF(string outputPath)
	{
 		Document document = new Document();

        // Create a Page.
        Page page = new Page();

        // Create a OrderedList.
        OrderedList list = new OrderedList(50, 50, 300, 250);

        list.ListItemTopMargin = 5;
        list.ListItemBottomMargin = 5;
        list.BulletPrefix = "(";
        list.BulletSuffix = ")";
        list.TextColor = RgbColor.BlueViolet;

        // Add ListItem to the List.
        ListItem item1 = list.Items.Add("List item 1");
        item1.Underline = true;
        ListItem item2 = list.Items.Add("List item 2");
        item2.Underline = true;
        ListItem item3 = list.Items.Add("List item 3");
        item3.Underline = true;
        ListItem item4 = list.Items.Add("List item 4");
        item4.Underline = true;

        // Add OrderedSubList under ListItem item1
        OrderedSubList subList1 = item1.SubLists.AddOrderedSubList(NumberingStyle.RomanUpperCase);
        subList1.TextColor = RgbColor.HotPink;
        ListItem item5 = subList1.Items.Add("Sub-list item 1");
        ListItem item6 = subList1.Items.Add("Sub-list item 2");

        OrderedSubList subList2 = item5.SubLists.AddOrderedSubList(NumberingStyle.AlphabeticLowerCase);
        subList2.TextColor = RgbColor.DarkGoldenRod;
        ListItem item7 = subList2.Items.Add("Second level sub-list item 1");
        ListItem item8 = subList2.Items.Add("Second level sub-list item 2");

        OrderedSubList subList3 = item6.SubLists.AddOrderedSubList(NumberingStyle.AlphabeticLowerCase);
        subList3.TextColor = RgbColor.DarkGoldenRod;
        ListItem item9 = subList3.Items.Add("Second level sub-list item 1");
        ListItem item10 = subList3.Items.Add("Second level sub-list item 2");

        OrderedSubList subList4 = item2.SubLists.AddOrderedSubList(NumberingStyle.RomanUpperCase);
        subList4.TextColor = RgbColor.HotPink;
        ListItem item11 = subList4.Items.Add("Sub-list item 1");
        ListItem item12 = subList4.Items.Add("Sub-list item 2");

        OrderedSubList subList5 = item11.SubLists.AddOrderedSubList(NumberingStyle.AlphabeticLowerCase);
        subList5.TextColor = RgbColor.DarkGoldenRod;
        ListItem item13 = subList5.Items.Add("Second level sub-list item 1");
        ListItem item14 = subList5.Items.Add("Second level sub-list item 2");

        OrderedSubList subList6 = item12.SubLists.AddOrderedSubList(NumberingStyle.AlphabeticLowerCase);
        subList6.TextColor = RgbColor.DarkGoldenRod;
        ListItem item15 = subList6.Items.Add("Second level sub-list item 1");
        ListItem item16 = subList6.Items.Add("Second level sub-list item 2");

        OrderedSubList subList7 = item3.SubLists.AddOrderedSubList(NumberingStyle.RomanUpperCase);
        subList7.TextColor = RgbColor.HotPink;
        ListItem item17 = subList7.Items.Add("Sub-list item 1");
        ListItem item18 = subList7.Items.Add("Sub-list item 2");

        // Add the OrderedList to the page
        page.Elements.Add(list);

        // Add the Page to the Document.
        document.Pages.Add(page);

        // if all the text did fit, GetOverflowList will return null
        list = list.GetOverFlowList(50,50);

        while (list != null)
        {
            page = new Page(PageSize.A4);
            page.Elements.Add(list);
            document.Pages.Add(page);
            list = list.GetOverFlowList(50,50);
        }
        //save the PDF.
        document.Draw(outputPath);
	}
}

Remarks

This method returns a new OrderedList object that contains the remaining text that did not fit.

See Also

OrderedList
ceTe.DynamicPDF.PageElements

In this topic