EncryptionProvider.Save(Int32, Object) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Saves an encrypted document.
public:
int Save(int SessionHandle, System::Object ^ EncryptionData);
public int Save (int SessionHandle, object EncryptionData);
abstract member Save : int * obj -> int
Public Function Save (SessionHandle As Integer, EncryptionData As Object) As Integer
Parameters
- SessionHandle
- Int32
The ID of the current session.
- EncryptionData
- Object
Contains the encryption information.
Returns
Integer
Remarks
When you save a file to the Office Open XML File Format (which is the only format that supports custom file encryption), then the provider is called by your COM add-in to encrypt the document. If you attempt to save to a format that does not support custom file encryption and you have the appropriate rights to do so, then Microsoft Office will save the document without encryption. This allows documents to be exported to formats that do not support encryption or rights management.