ImageGear Professional DLL v17.1 for Windows Accusoft
IG_PDF_doc_create_new_page
Send Feedback  
ImageGear Professional DLL v17.1 for Windows > API Reference Guide > PDF Component API Reference > PDF Component Objects Reference > General Objects > HIG_PDF_DOC > IG_PDF_doc_create_new_page

Glossary Item Box

This function creates a new PDF page for the hMPIDoc.

Declaration:

  Copy Code
AT_ERRCOUNT ACCUAPI IG_PDF_doc_create_new_page(
        HMIGEAR hMPIDoc,
        LONG nAfterPage,
        LPAT_PDF_FIXEDRECT lpMediaBox );

Arguments:

hMPIDoc The document in which the page is created.
nAfterPage The page number after which the new page is inserted. The first page is 0. Use IG_PDF_BEFORE_FIRST_PAGE to insert the new page at the beginning of a document.
lpMediaBox Rectangle specifying the page's media box, specified in user space coordinates.

Return Value:

Error count.

Supported Raster Image Formats:

This function does not process image pixels.

Remarks:

The new PDF page is created at the specified position.

The previous value (if any) is not deleted with the IG_image_delete function. The size of the multi-page image is not changed, so that page arrays is not expanded when nAfterPage is greater than pageCount-1.

To obtain a handle to the PDF page, use the following:

  Copy Code
HIGEAR hNewPage = NULL;
IG_mpi_page_get(m_hMPDoc, nAfterPage+1, &hNewPage);
HIG_PDF_PAGE hNewPDFPage = NULL;
IG_vector_data_get( hNewPage, (LPVOID*)&hNewPDFPage );
©2012. Accusoft Corporation. All Rights Reserved.