Generate Documentation (Basic)
The basic method generates documentation for the current version of the specified item in either Microsoft Word document (DOCX) format, or Adobe PDF format.
- Connect to the configuration web service.
- Specify the identifier of the item.
- Specify the file format as either "DOCX" or "PDF".
Code Sample
# Set the file format to DOCX/PDF.
$fileformat = "DOCX";
# Set the item identifier.
$itemIdentifier = 1234;
# Generate the documentation.
$documentPackage = $xia.GET_DocumentationBasic($itemIdentifier, $fileformat);
# Save and open the file.
$filename = "$($env:TEMP)\$($documentPackage.Filename)"
[IO.File]::WriteAllBytes($filename, $documentPackage.FileData);
[System.Diagnostics.Process]::Start($filename);