Take a survey

Developing Applications Using APIs > Assigning Usage Rights > Retrieving Credential Information > Retrieving credential information using the web service API

Retrieving credential information using the web service API
To retrieve credential information using the web service API, perform the following tasks:
1.
2.
Using the Microsoft .NET client assembly, create a ReaderExtensionsServiceService object by invoking its default constructor.
3.
Create a BLOB object by using its constructor. The BLOB object is used to store a rights-enabled PDF document.
Create a System.IO.FileStream object by invoking its constructor and passing a string value that represents the file location of the rights-enabled PDF document and the mode in which to open the file.
Create a byte array that stores the content of the System.IO.FileStream object. You can determine the size of the byte array by getting the System.IO.FileStream object’s Length property.
Populate the byte array with stream data by invoking the System.IO.FileStream object’s Read method and passing the byte array, the starting position, and the stream length to read.
Populate the BLOB object by assigning its binaryData property with the contents of the byte array.
4.
Retrieve information about the credential used to apply usage-rights to the PDF document by invoking the ReaderExtensionsServiceClient object’s getDocumentUsageRights method and passing the com.adobe.idp.Document object that contains the rights-enabled PDF document. This method returns a GetUsageRightsResult object that contains credential information.
Retrieve the date after which the credential is no longer valid by getting the value of the GetUsageRightsResult object’s notAfter data member. The data type of this data member is System.DateTime.
Retrieve the message that is displayed when the rights-enabled PDF document is opened in Adobe Reader by getting the value of the GetUsageRightsResult object’s message data member. The data type of this data member is a string.
Retrieve the number of times that the credential is used by getting the value of the GetUsageRightsResult object’s useCount data member. The data type of this data member is an integer.
View Quick Start
 

 

Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/livecycle/es/sdkHelp/programmer/sdkHelp/usageRightsInformation.59.4.html