Save Generated PDF into Server File Location


Do you have trouble saving the generated PDF document into a server file location? Currently, K2 has provide an OOB function to generate PDF via their PDF Converter SmartObject. With this, I came out with an assembly to transfer the generated PDF into server file location.

Before we proceed, you may wish to visit Save PDF Control to understand more about the PDF conversion.


This assembly helps to transfer the generated PDF and save it into the file location. This should be installed as an endpoint assembly which you will be able to use in both SmartForms and Workflow.


Prior to the installation, please download the assembly DLL before your proceed. Extract and copy the DLL into the K2 BlackPearl APP server.

Register the service instance

1. Register the service instance under Endpoints Assembly via SmartObject Tester Tool.

Register Service Instance

2. Select your authentication mode and specified the path that you have copy the assembly DLL over. Click Next.

Service Instance

3. Rename the system and display name and click Add. (You should be seeing Add button instead of Update button)

New Service Instance

Create the Smart Object

1. Create the SmartObject for the newly created assembly

Create SMO

2. Select only SAVEPDFFileToServer Objects and click OK.

Create SMO 2

3. Success message prompted, click OK.


4. You will see the SmartObject being created as below:SMO Created


After the SmartObject is created using this assembly, you will be able to use it as a normal SmartObject function.


This SmartObject will only works when you generate the PDF document via the PDF Converter SmartObject. Refer to Save PDF Control on how to create the PDF.

The account that is used to run this service instance would require read & write permission to the file/folder path.

Transfer PDF File To Server SmartObject

SmartObject Properties (examples shown in the screenshot):

  • HostName – K2 Server Host Name
  • PDF_ID – ID that is generated after creating the PDF
  • FilePath – Location of the file path
  • RemovePDFSMO – set as “True”, if you would like to remove the PDF from the PDF Converter SmartObject

Execute SMO

Additional Notes

This solution is built and tested on K2 BlackPearl 4.6.11 version. It could not be compatible to other version prior to future K2 software releases.



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s