cancel
Showing results for 
Search instead for 
Did you mean: 

Print the documents Using Unity API

Manikanadanbe
Star Contributor
Star Contributor

Dear All,

I am trying to print the documents using Unity API.But no error is coming up,documents are not printing and i have few question to clarify .Please any one suggest me to solve this issue?

1 )  How to check the documents are printed or not

2) How to configure which printer should print the document.

What is the code i have used in my application given below. please assist me to solve this issue.

List<Hyland.Unity.Document> unityDocs = new List<Hyland.Unity.Document>();                 
unityDocs.Add(unityApp.Core.GetDocumentByID(487));
unityDocs.Add(unityApp.Core.GetDocumentByID(489))

PrintQueue printQueue = unityApp.Core.PrintManagement.PrintQueues.Find(102)

PrintRequestProperties printReqProp = unityApp.Core.PrintManagement.CreatePrintRequestProperties(unityDocs, printQueue);

PrintJob printJob = unityApp.Core.PrintManagement.EnqueuePrintRequest(printReqProp);

1 ACCEPTED ANSWER

Tyler_Sorber
Star Collaborator
Star Collaborator

Hi Manikandakumar

This functionality will only add the Print Job to the Print Queue in OnBase. In order for the Print Job to be executed by a printer, a Print Queue must be mapped to a local printer. In addition, the Thick Client must run with the -PS Command Line to send the Print Job from the Print Queue to the Printer.  Essentially, the API will only add the Print Job to the Print Queue, it will not perform the actual Printing function. 

For more information on preliminary configuration, please review the System Administration MRG.  If there are further questions, please contact you first line of support for assistance.

View answer in original post

5 REPLIES 5

Fabian_Serna
Confirmed Champ
Confirmed Champ

to achieve direct printing you should use a system dll and make the execution with iclientscript executed from a button.