Configuring CSV Export for Annotations and Comments in PDF Editor for SharePoint
PDF Editor users now have the option of exporting annotations and comments in CSV format. They can choose which properties to export, along with the column order. This can be configured by adding two storage entity properties using PnP PowerShell, and a CSV button will appear in the main toolbar. It’s possible to export only annotations, only comments, or both. When CSV export isn’t configured, the CSV export button will be hidden.
By exporting annotations and comments to a CSV file, users can easily access and manage this data outside of PDF Editor. CSV files are widely supported and can be opened in various applications, making it convenient for users to analyze and share data. Exported annotation and comment data serves as an audit trail, documenting the history of changes, suggestions, and discussions related to a PDF.
Benefits of CSV Export for Annotations and Comments
There are a handful of benefits to being able to export annotations and comments in CSV format, which are detailed in the following sections.
Enhanced Data Management
Exporting annotations and comments to CSV allows for seamless data management. Users can filter, sort, and organize data using spreadsheet software, which enables efficient handling of large datasets.
Simplified Collaboration
With the CSV export feature, users can easily share annotation and comment data with colleagues who may not have access to PDF Editor. This promotes better collaboration and ensures all stakeholders can review and analyze the feedback and notes.
Audit Trail and Compliance
Maintaining a CSV file of annotations and comments provides a clear audit trail. This is crucial for compliance and record-keeping, as it documents the history of changes and discussions related to a document. Organizations can track who added specific annotations or comments and when they were created.
Integration with Other Tools
CSV files can be imported into various data analysis tools and software applications. This integration capability allows users to leverage advanced analytics and reporting features, providing deeper insights into the data.
Flexibility and Customization
Users have the flexibility to choose which properties of annotations and comments to export. This customization ensures that only relevant data is included in a CSV file, and that it’s tailored to the specific needs of the organization or project.
Refer to the information below for details on how to configure CSV export for annotations and comments in PDF Editor for Sharepoint.
PDF Editor for SharePoint Online
By default, CSV export isn’t enabled. The configuration can be set at either the tenant app catalog level or the site app catalog level, with site-level settings overriding tenant-level ones. Tenant properties can only be set on site collection app catalogs for sites with custom scripts enabled, meaning the app catalog must already exist. However, tenant-level properties can be set without enabling custom scripts. Use the following PowerShell scripts to configure CSV export for annotations and/or comments:
#tenant app catalog level #Enable CSV export for annotations. Set-PnPStorageEntity -Key "Muhimbi.SharePoint.PDFEditor.ExportAnnotationsPropertiesToCsv" -Value "type, id, pageIndex, creatorEmail, note, color" #Enable CSV export for comments. Set-PnpStorageEntity -Key "Muhimbi.SharePoint.PDFEditor.ExportCommentsPropertiesToCsv" -Value "id, rootId, pageIndex, creatorName, createdAt, updatedAt, textFormat, textValue, creatorEmail, isPdfEditor" #Disable CSV export for annotations. Remove-PnpStorageEntity -Key "Muhimbi.SharePoint.PDFEditor.ExportAnnotationsPropertiesToCsv" #Disable CSV export for comments. Remove-PnpStorageEntity -Key "Muhimbi.SharePoint.PDFEditor.ExportCommentsPropertiesToCsv" #site app catalog level #Enable CSV export for annotations. Set-PnPStorageEntity -Scope Site -Key "Muhimbi.SharePoint.PDFEditor.ExportAnnotationsPropertiesToCsv" -Value "type, id, pageIndex, creatorEmail, note, color" #Enable CSV export for comments. Set-PnPStorageEntity -Scope Site -Key "Muhimbi.SharePoint.PDFEditor.ExportCommentsPropertiesToCsv" -Value "id, rootId, pageIndex, creatorName, createdAt, updatedAt, textFormat, textValue, creatorEmail, isPdfEditor" #Disable CSV export for annotations. Remove-PnpStorageEntity -Scope Site -Key "Muhimbi.SharePoint.PDFEditor.ExportAnnotationsPropertiesToCsv" #Disable CSV export for comments. Remove-PnpStorageEntity -Scope Site -Key "Muhimbi.SharePoint.PDFEditor.ExportCommentsPropertiesToCsv"
PDF Editor for SharePoint On-Premises
Refer to our release notes to find out when this feature will become available for PDF Editor for SharePoint On-Premises.
Annotation Properties Available for Export
Choose which properties to export from the following:
Name | Type | Description |
---|---|---|
id |
string | A unique identifier for the annotation. |
type |
string | Annotation type as defined by the PSPDFKit SDK. |
name |
string | An optional property that may be used to identify the annotation. By default, it’s set to the same value as the automatically generated ID. |
subject |
string | An optional annotation subject, representing a short description of the subject being addressed by the annotation. |
pageIndex |
number | The page index on which the annotation is placed. pageIndex is zero-based and has a maximum value of totalPageCount - 1 |
creatorName |
string | The name of the creator of the annotation. |
creatorEmail |
string | The email of the user that created the annotation. |
createdAt |
string | The date and time when the annotation was created. |
updatedAt |
string | The date and time when the annotation was last updated. |
isPdfEditor |
Boolean | Flag set to true for annotations created using PDF Editor for SharePoint. |
pdfObjectId |
number | Internal PDF object identifier. |
note |
string | An optional note that can be set on an annotation. |
noPrint |
Boolean | The annotation flag that prevents the annotation from being printed. |
noZoom |
Boolean | The annotation flag that prevents the annotation from scaling up when the page is zoomed in. |
noView |
Boolean | The annotation flag that prevents the annotation from being rendered in the UI. |
noRotate |
Boolean | The annotation flag that prevents the annotation from rotating when the page is rotated. |
locked |
Boolean | The annotation flag that prevents the annotation from being deleted or modified. |
lockedContents |
Boolean | The annotation flag that prevents the annotation content from being modified. |
readOnly |
Boolean | The annotation flag that makes the annotation read-only. |
hidden |
Boolean | The annotation flag that prevents the annotation from being displayed or printed, or from interacting with the user. |
isCommentThreadRoot |
Boolean | |
opacity |
number | A transparency value applied to the complete annotation. The value is capped between 0 and 1 , |
blendMode |
string | The blend mode defines how the color of the annotation will be applied to its background. |
boundingBoxLeft |
number | Distance to the left side of the page for the upper-left corner of the rectangle that positions the annotation. Provided values are defined in same units used by the page, point units. Point units are only equal to pixels when the zoom value is 1 . |
boundingBoxTop |
number | Distance to the top of the page for the upper-left corner of the rectangle that positions the annotation. Provided values are defined in same units used by the page, point units. Point units are only equal to pixels when the zoom value is 1 . |
boundingBoxWidth |
number | Width of the rectangle that positions the annotation. Provided values are defined in same units used by the page, point units. Point units are only equal to pixels when the zoom value is 1 . |
boundingBoxHeight |
number | Height of the rectangle that positions the annotation. Provided values are defined in same units used by the page, point units. Point units are only equal to pixels when the zoom value is 1 . |
borderColor |
string | Hex border color that will be drawn at the border of an annotation’s bounding box. |
borderColorTransparent |
Boolean | A flag indicating that the color of the border is transparent. |
borderStyle |
string | Optional border style used for the border of an annotation’s bounding box. One of solid , dashed , beveled , inset , or underline . |
borderWidth |
number | Optional border width in PDF pixels that will be used for the border of the bounding box. |
rotation |
number | Angle of an annotation’s rotation, in degrees. |
rectangles |
string | A list of rectangles where a markup annotation is drawn. This is necessary to display a markup annotation on multiple lines. The CSV value is a flattened JSON array. |
color |
string | Hex color for annotations that support a color. |
colorTransparent |
Boolean | A flag indicating that the color of the annotation is transparent. |
actionType |
string | Action type available for an annotation. |
actionUri |
string | The uniform resource identifier (web link) that should be resolved when triggering an annotation action of type URI. |
actionPageIndex |
number | The destination page in the document that should be scrolled to when triggering an annotation action of type GoTo . |
textformat |
string | One of plain or xhtml (for rich text annotations). Applies to text or note annotations. |
textvalue |
string | Annotation’s text for plain annotations or HTML markup and text for xhtml annotations. Applies to text and note annotations. |
icon |
string | The icon that represents the collapsed annotation in the document. Applies to note annotations. |
isFitting |
Boolean | The text annotation flag that indicates if the text fits the bounding box of the annotation without overflowing. It’s set only for annotations modified through PDF Editor. |
callout |
string | JSON-serialized object with the properties of the callout attached to an annotation. |
description |
string | Description of the image content for image annotations. |
contentType |
string | The content type of the connected attachment binary data of an image annotation, i.e. image/jpeg , image-opt-640.WEBP , or application/pdf . |
imageAttachmentId |
string | The attachment identifier of the image. It holds the image data as binary. |
title |
string | The main text of a custom stamp annotation. |
subtitle |
string | The subtext of a custom stamp annotation. |
stampType |
string | A predefined type for a stamp annotation. One of: Approved , NotApproved , Draft , Final , Completed , Confidential , ForPublicRelease , NotForPublicRelease , ForComment , Void , PreliminaryResults , InformationOnly , Rejected , Accepted , InitialHere , SignHere , Witness , AsIs , Departmental , Experimental , Expired , Sold , TopSecret , Revised , RejectedWithText , or Custom . |
formFieldName |
string | The PSPDFKit.FormFields.FormField#name of the linked form field. Applies to widget annotations. |
horizontalAlign |
string | Optional horizontal text alignment for widget annotations. One of left , center , or right . |
verticalAlign |
string | Optional vertical text alignment for widget annotations. One of top , center , or bottom . |
font |
string | The name of the font family that should be used for an annotation if available at runtime. |
fontColor |
string | Hex color for the visible font glyphs. |
fontColorTransparent |
Boolean | A flag indicating that the color of the font is transparent. |
fontSize |
number | The font size in page size pixels. |
lineHeightFactor |
number | The number of pixels per font size unit. |
isBold |
Boolean | Flag indicating the font will be bold if the font family supports this. |
isItalic |
Boolean | Flag indicating the font will be italic if the font family supports this. |
strokeWidth |
number | The width of the line in page size pixels. Applies to shape annotations. |
strokeColor | number | The hex color for shape lines. Applies to shape annotations |
strokeColorTransparent | boolean | A flag indicating that the color of the shape lines is transparent |
measurementPrecision | string | Precision value for length of measurement annotations. One of whole , one , two , three , four , halves , quarters , eighths , sixteenths |
measurementScaleUnitFrom | string | The unit from which you can scale from for measurement annotations. One of inches , millimeters , centimeters , points |
measurementScaleUnitTo | string | The unit to which you can scale from for measurement annotations. One of inches , millimeters , centimeters , points |
measurementScaleFromValue |
number | The relationship between two metrics that represent the scale of an annotation with measurement information. |
measurementScaleToValue |
number | The relationship between two metrics that represent the scale of an annotation with measurement information. |
measurementBBoxLeft |
number | Distance to the left side of the page for the upper-left corner of the rectangle that positions the measurement. |
measurementBBoxTop |
number | Distance to the top of the page for the upper-left corner of the rectangle that positions the measurement. |
measurementBBoxWidth |
number | Width of the rectangle that positions the measurement. |
measurementBBoxHeight |
number | Height of the rectangle that positions the measurement. |
startPointX |
number | X coordinate of the point where a line annotation starts. |
startPointY |
number | Y coordinate of the point where a line annotation starts. |
endPointX |
number | X coordinate of the point where a line annotation ends. |
endPointY |
number | Y coordinate of the point where a line annotation ends. |
lineCapsStart |
string | The shape used for a line annotation’s caps. One of square , circle , diamond , openArrow , closedArrow , butt , reverseOpenArrow , reverseClosedArrow , or slash . |
lineCapsEnd |
string | The shape used for a line annotation’s caps. One of square , circle , diamond , openArrow , closedArrow , butt , reverseOpenArrow , reverseClosedArrow , or slash . |
points |
string | A list of points that define a polyline annotation. The CSV value is a flattened JSON array. |
lines |
string | A list of line segments for ink annotations. Every segment consists of a list of points. The CSV value is a flattened JSON array. |
lineWidth |
number | The width of the lines of an ink annotation in page size pixels. |
isDrawnNaturally |
Boolean | A flag indicating if an ink annotation is drawn using PSPDFKit’s natural drawing mode. |
isSignature |
Boolean | A flag set to true when an ink annotation is created via the signature UI. |
Comment Properties Available for Export
Choose which properties to export from the following:
Name | Type | Description |
---|---|---|
id |
string | A unique identifier for the comment. |
rootId |
string | The ID of the annotation this comment stems from. All comments in a thread share the same root ID. |
pageIndex |
number | The page index the comment resides at. pageIndex is zero-based and has a maximum value of totalPageCount - 1. |
creatorName |
string | The name of the creator of the comment. |
creatorEmail |
string | The email of the user that created the comment. |
createdAt |
string | The date and time when the comment was created. |
updatedAt |
string | The date and time when the comment was last updated. |
textformat |
string | One of plain or xhtml (for rich text comments). |
textvalue |
string | Comment’s text for plain comments or HTML markup and text for xhtml comments, |
isPdfEditor |
Boolean | Flag set to true for comments created using PDF Editor for SharePoint. |
pdfObjectId |
number | Internal PDF object identifier. |
Conclusion
Configuring CSV export for annotations and comments in PDF Editor for SharePoint enhances data management and collaboration capabilities, providing a streamlined way to manage and analyze feedback and annotations outside of the editor. Take control of your document workflows today — try PDF Editor for SharePoint Online free for 14 days, available on Microsoft App Source. Or, check out our free trial page for more options.