[]
Draws the pages in a page collection onto a PDF page.
This method divides the target PDF page into a grid defined by rows
and columns, then draws the specified PageInfo objects into that
layout. This overload uses OverThenDown by default when placing pages.
public void Draw(Page page, IList<PageInfo> pages, int rows, int columns, Order order = Order.OverThenDown, PdfSaveOptions options = null)
Public Sub Draw(page As Page, pages As IList(Of PageInfo), rows As Integer, columns As Integer, Optional order As Order = Order.OverThenDown, Optional options As PdfSaveOptions = Nothing)
| Type | Name | Description |
|---|---|---|
| Page | page | The target PDF page. Must not be |
| IList<PageInfo> | pages | The page collection to draw. Must not be |
| int | rows | The number of rows used to divide the target page layout. Must be greater than 0. |
| int | columns | The number of columns used to divide the target page layout. Must be greater than 0. |
| Order | order | The direction used to arrange the pages in the target layout. |
| PdfSaveOptions | options | The PDF save options applied when drawing the page content; may be |
worksheet.Range["A1:B4"].Value = new object[,]
{
{ "Name", "Value" },
{ "A", 100 },
{ "B", 200 },
{ "C", 300 }
};
PrintManager printManager = new PrintManager();
IList<PageInfo> pages = printManager.Paginate(worksheet);
GcPdfDocument doc = new GcPdfDocument();
GrapeCity.Documents.Pdf.Page page = doc.NewPage();
printManager.Draw(page, pages, 1, 1);
Draw the range data to the specific location in a specified pdf page.
public void Draw(Page page, PointF location, IRange range, PdfSaveOptions options = null)
Public Sub Draw(page As Page, location As PointF, range As IRange, Optional options As PdfSaveOptions = Nothing)
| Type | Name | Description |
|---|---|---|
| Page | page | The page in a GcPdfDocument. |
| PointF | location | The location of the range data to be drawn. |
| IRange | range | The print data range. |
| PdfSaveOptions | options | Options for saving pdf file. |
worksheet.Range["A1:B2"].Value = new object[,]
{
{ "Name", "Value" },
{ "Test", 100 }
};
IRange range = worksheet.Range["A1:B2"];
PrintManager printManager = new PrintManager();
GcPdfDocument doc = new GcPdfDocument();
GrapeCity.Documents.Pdf.Page page = doc.NewPage();
printManager.Draw(page, new PointF(36, 72), range);
Draw the range data to the specific location in a specified pdf page.
public void Draw(Page page, RectangleF rect, IRange range, PdfSaveOptions options = null)
Public Sub Draw(page As Page, rect As RectangleF, range As IRange, Optional options As PdfSaveOptions = Nothing)
| Type | Name | Description |
|---|---|---|
| Page | page | The page in a GcPdfDocument. |
| RectangleF | rect | The location and size of the range data to be drawn. |
| IRange | range | The print data range. |
| PdfSaveOptions | options | Options for saving pdf file. |
worksheet.Range["A1:B2"].Value = new object[,]
{
{ "Name", "Value" },
{ "Test", 100 }
};
IRange range = worksheet.Range["A1:B2"];
PrintManager printManager = new PrintManager();
GcPdfDocument doc = new GcPdfDocument();
GrapeCity.Documents.Pdf.Page page = doc.NewPage();
printManager.Draw(page, new RectangleF(36, 72, 240, 120), range);
Draw the page info to the specific location in a specified pdf page.
public void Draw(Page page, RectangleF rect, PageContentInfo pageContent, PdfSaveOptions options = null)
Public Sub Draw(page As Page, rect As RectangleF, pageContent As PageContentInfo, Optional options As PdfSaveOptions = Nothing)
| Type | Name | Description |
|---|---|---|
| Page | page | The page in a GcPdfDocument. |
| RectangleF | rect | The location and size of the data to be drawn. |
| PageContentInfo | pageContent | The printed page content info. |
| PdfSaveOptions | options | Options for saving pdf file. |
worksheet.PageSetup.PrintArea = "A1:B4";
worksheet.Range["A1:B4"].Value = new object[,]
{
{ "Name", "Value" },
{ "A", 100 },
{ "B", 200 },
{ "C", 300 }
};
PrintManager printManager = new PrintManager();
PageContentInfo pageContent = printManager.Paginate(worksheet)[0].PageContent;
GcPdfDocument doc = new GcPdfDocument();
GrapeCity.Documents.Pdf.Page page = doc.NewPage();
printManager.Draw(page, new RectangleF(36, 72, 360, 240), pageContent);
Draw the page info to the specific location in a specified pdf page.
public void Draw(Page page, RectangleF rect, PageInfo pageInfo, PdfSaveOptions options = null)
Public Sub Draw(page As Page, rect As RectangleF, pageInfo As PageInfo, Optional options As PdfSaveOptions = Nothing)
| Type | Name | Description |
|---|---|---|
| Page | page | The page in a GcPdfDocument. |
| RectangleF | rect | The location and size of the data to be drawn. |
| PageInfo | pageInfo | The printed page info. |
| PdfSaveOptions | options | Options for saving pdf file. |
worksheet.PageSetup.PrintArea = "A1:B4";
worksheet.Range["A1:B4"].Value = new object[,]
{
{ "Name", "Value" },
{ "A", 100 },
{ "B", 200 },
{ "C", 300 }
};
PrintManager printManager = new PrintManager();
PageInfo pageInfo = printManager.Paginate(worksheet)[0];
GcPdfDocument doc = new GcPdfDocument();
GrapeCity.Documents.Pdf.Page page = doc.NewPage();
printManager.Draw(page, new RectangleF(36, 72, 360, 240), pageInfo);