LFileSettings::GetDecryptOptions

#include "ltwrappr.h"

static L_INT LFileSettings::GetDecryptOptions(pOptions, uStructSize)

Gets the file options used by LEADTOOLS when loading encrypted files.

Parameters

pFILEDECRYPTOPTIONS pOptions

Pointer to a structure to be updated with the options used when loading encrypted files.

L_UINT uStructSize

Size of the structure pointed to by pOptions. Use sizeof(FILEDECRYPTOPTIONS) to calculate this value.

Returns

Value Meaning
SUCCESS The function was successful.
< 1 An error occurred. Refer to Return Codes.

Comments

The options obtained by this function are valid for the current thread.

These settings are used for loading all encrypted files (DOC, DOCX, PDF, PPT, PPTX, XLS, XLSX, etc). LFileSettings::GetPDFOptions can also be used to check an additional password used only for PDF files.

To change the current options, change the values in the FILEDECRYPTOPTIONS structure and call LFileSettings::SetDecryptOptions. Again, this will change the values only for the current thread.

FILEDECRYPTOPTIONS.pszPassword points to the internal buffer used by LEADTOOLS for decrypting files. You should not attempt to free this pointer and assume this pointer is valid. It is only valid until the next call to LFileSettings::SetDecryptOptions. If you need to use this pointer for extended amount of time, you should make a copy of it.

For example, if you wish to get a copy of this structure and use it to initialize any worker threads, then try the following:

Required DLLs and Libraries

Platforms

Win32, x64.

See Also

Functions

Topics

Example

For an example, refer to LFileSettings::SetDecryptOptions.

Help Version 22.0.2021.9.12
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2021 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Raster Imaging C++ Class Library Help