Connection Information

To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.

Connection Type

Export.PDF.NativePDF.UserPassword – PB Docs 2022 – PowerBuilder Library

Export.PDF.NativePDF.UserPassword – PB Docs 2022

Export.PDF.NativePDF.UserPassword

property (DataWindow object)

Description

Setting that enables you to set a password for opening the
generated PDF file, when you use the PDFlib method to save data from a
DataWindow object to a PDF file. Therefore, this user password is also
referred to as open password.

Applies to

DataWindow objects

Syntax

PowerBuilder dot notation:

Describe argument:

Parameter

Description

value

(exp) The password for opening the generated PDF
file.

The value can be a string containing at least
one character or no more than 37 characters. If more than 37
characters are set, the first 37 characters will be used as the
password. The characters must be printable ASCII characters. Any
unprintable ASCII characters will cause PB dot notation to throw
an exception.

When the value is empty, it indicates
no password is required to open the file.

Usage

If you set the user password for opening the PDF file, you must
also set the master password by the Export.PDF.NativePDF.MasterPassword
property. If the master password is empty, it indicates no master
password or user password is required to open the file or
copy/print/edit the file (which means any one can open the file and
copy/print/edit the file with no restrictions).

If you set the user password without setting the restrictions, a
user with the user password can open the PDF file for viewing only. You
can use the Export.PDF.NativePDF.Restrictions
property to set whether the user with the user password can have
permissions of printing, copying, editing etc.

The user password and the master password cannot be the same,
otherwise SaveAs function will fail and return -1.

If a PDF file requires a password to open, you can either input
the user password or the master password. When inputting the user
password, you will have the permissions set by the Export.PDF.NativePDF.Restrictions
property; when inputting the master password, you automatically have
access to all of the permissions.

This property takes no effect for files created using PDF/A
standard.

Examples

This example sets the user password and the master password, and
saves the data to a file called custom.pdf:

This example uses Modify to set the user password and the master
password:

See also

Export.PDF.Method

Export.PDF.NativePDF.Author

Export.PDF.NativePDF.CustomOrientation

Export.PDF.NativePDF.CustomSize

Export.PDF.NativePDF.ImageFormat

Export.PDF.NativePDF.Keywords

Export.PDF.NativePDF.MasterPassword

Export.PDF.NativePDF.PDFStandard

Export.PDF.NativePDF.Restrictions

Export.PDF.NativePDF.Subject

Export.PDF.NativePDF.UsePrintSpec

Print.property


Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x