Exports a selection of views in PDF format.
Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 24.0.0.0 (24.0.0.0)
Since: 2022
Syntax
C# |
---|
|
Visual Basic |
---|
|
Visual C++ |
---|
|
Parameters
- folder
- Type: SystemString
Output folder, into which file(s) will be exported. The folder must exist.
- viewIds
- Type: System.Collections.GenericIListElementId
Selection of ordered views to be exported. The list must contain at least one valid view.
- options
- Type: Autodesk.Revit.DBPDFExportOptions
Various options applicable to the PDF format.
Return Value
True if all specified views are exported successfully, False if exporting of any view fails, even if some views might have been exported successfully.Exceptions
Exception | Condition |
---|---|
Autodesk.Revit.ExceptionsArgumentException | non empty list of views must be provided. -or- NullOrEmpty -or- There are duplicate views in viewIds -or- some of the views are not printable (exportable). -or- Thrown when one or more input arguments are invalid. |
Autodesk.Revit.ExceptionsArgumentNullException | A non-optional argument was null |
Autodesk.Revit.ExceptionsFileAccessException | Thrown when the target PDF file is inaccessible, e.g. already opened. |
Autodesk.Revit.ExceptionsInvalidOperationException | Export is temporarily disabled. -or- Exporting is not allowed in the current application mode. |
Autodesk.Revit.ExceptionsInvalidPathArgumentException | The folder does not exist. |