officefileapi-devexpress-dot-spreadsheet-dot-encryptedfilepasswordrequesteventargs-36b5364a.md
Gets the name of the encrypted document.
Namespace : DevExpress.Spreadsheet
Assembly : DevExpress.Spreadsheet.v25.2.Core.dll
NuGet Package : DevExpress.Spreadsheet.Core
public string DocumentName { get; }
Public ReadOnly Property DocumentName As String
| Type | Description |
|---|---|
| String |
A string that is the document name.
|
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the DocumentName property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
winforms-spreadsheet-load-and-save-a-password-encrypted-files/CS/EncryptionExample/Form1.cs#L62
private void SpreadsheetControl1_EncryptedFilePasswordRequest(object sender, EncryptedFilePasswordRequestEventArgs e) {
if (e.DocumentName == "encrypted_test.xlsx") e.Password = "test";
if (e.DocumentName == "corrupted.xlsx") e.Password = "000";
winforms-spreadsheet-load-and-save-a-password-encrypted-files/VB/EncryptionExample/Form1.vb#L63
Private Sub SpreadsheetControl1_EncryptedFilePasswordRequest(ByVal sender As Object, ByVal e As EncryptedFilePasswordRequestEventArgs)
If Equals(e.DocumentName, "encrypted_test.xlsx") Then e.Password = "test"
If Equals(e.DocumentName, "corrupted.xlsx") Then e.Password = "000"
See Also
EncryptedFilePasswordRequestEventArgs Class