# A3DPDFDocumentUpdateData

A3DStatus `A3DPDFDocumentUpdateData`(A3DPDFDocument *pDoc, const A3DUTF8Char *pcAnnot3DUID, const A3DInt32 idxPage, const A3DInt32 idx3dAnnot, A3DAsmModelFile *pModelFile, const A3DRWParamsExportPrcData *pParamsExportData, A3DRWParamsPrcWriteHelper **ppPrcWriteHelper, const A3DPDF3DArtworkData2 *p3DArtworkData, const A3DPDF3DAnnotData *p3DAnnotData, const A3DBool bAddStandardViews, const A3DPDFViewData *pDefaultViewData, const A3DUTF8Char *pcIn3dAttribsFile, const A3DUTF8Char *pcInTextFieldDataFile)
  `A3DStatus` A3DPDFDocumentUpdateData(`A3DPDFDocument`* pDoc, const `A3DUTF8Char`* pcAnnot3DUID, const `A3DInt32` idxPage, const `A3DInt32` idx3dAnnot, `A3DAsmModelFile`* pModelFile, const `A3DRWParamsExportPrcData`* pParamsExportData, `A3DRWParamsPrcWriteHelper`** ppPrcWriteHelper, const `A3DPDF3DArtworkData2`* p3DArtworkData, const `A3DPDF3DAnnotData`* p3DAnnotData, const `A3DBool` bAddStandardViews, const `A3DPDFViewData`* pDefaultViewData, const `A3DUTF8Char`* pcIn3dAttribsFile, const `A3DUTF8Char`* pcInTextFieldDataFile)

  Function to automatically update Publish data into a document generated by Tetra 4D Enrich.

  Updated data are carousels, slide tables, attributes, and text fields. During update, following operations are performed:

  - The 3D object from the specified PDF template is replaced by the CAD data stored in model file,
  - The external information defined by XML files if any (attributes, title block) are read
  - The Tetra4D Enrich widgets present in the template (Carousel of Views, Table) are updated based on the new 3D data and the read XML attributes file,
  - The generic actions (text output on part selection, change of rendering mode…), if any, are updated,
  - The text fields (title block) are updated based on the specified title block XML file if any, and on the new 3D data.

  Parameters

  > pDoc: The Document object to work with. The document should be a PDF file that has been generated by Tetra 4D Enrich. It is also necessary to primarily use the function A3DPDFDocumentCreateFromPDFFile to create the document, so that all necessary information are kept (javascript and all internal data stored in the document).

  > pcAnnot3DUID: Identifier of the 3D annot to update. If not provided, use idxPage and idx3dAnnot to identify the annotation to update.

  > idxPage: Identifier of the 3D annot to update: index of the page in the document (starting from 0). If -1, looks in all the document for the first annot 3D found

  > idx3dAnnot: Identifier of the 3D annot to update: index of the annotation in the page (starting from 0). If -1, looks in all pages for the first annot 3D found.

  > pModelFile: The model file to work with.

  > pParamsExportData: The PRC export parameters that are used to store the model file into the PDF.

  > ppPrcWriteHelper: Used to store the model file into the PDF. ppPrcWriteHelper is filled by this function and can be later used to get PRC data such as unique identifiers of PRC nodes

  > p3DArtworkData: The 3D Artwork parameters.

  > p3DAnnotData: The 3D Annot parameters.

  > bAddStandardViews: Add six standard views: Left Top Front Right Bottom Back.

  > pDefaultViewData: If provided, the parameters of this view are used to create a new automatic view (the view associated to the ‘home’ icon in Adobe Reader). If not provided, the automatic view is created with HOOPS Publish strategy: it is duplicated from the existing default view if there is one in the model file definition; if not, a new ‘automatic’ view is created with hard coded parameters.

  > pcIn3dAttribsFile: XML file containing part attributes. If some of the meta-data to be put in the PDF document are managed by another application (such as ERP, PLM…), so not present in the CAD files, this function enables to import them through an XML file and map them to the 3D. Please refer to the section section`Parts attributes definition XML file <publish_enrich.html#attribs3dxml>`__in our programming guide for more details.

  > pcInTextFieldDataFile: XML file defining text information to populate text fields (title-block) in the PDF document. Please refer to the section section`Text fields values definition XML file <publish_enrich.html#textfieldsxml>`__in our programming guide for more details.

  Returns

  > A3D_SUCCESS in case of success or an error code

Conversation saved
HOOPSY BETA

### Hello! I'm HOOPSY

Your multilingual generative AI assistant for documentation. Ask me anything about HOOPS Exchange in your own language, or choose a sample question below to start a conversation:

What is HOOPS Exchange?
What are the latest release notes for HOOPS Exchange?
How do I start evaluating HOOPS Exchange?
How do I write my first sample application?
How can I get assistance?

HOOPSY may store conversations according to OpenAI's policy. Responses may not always be accurate.

HOOPSY is thinking...