Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin

...

Description

Excerpt

To decrypt an encrypted template, set DecryptPassword to the password set using EncryptPassword or in Microsoft Excel (Tools -> Options... -> Security).

Signature
C#
C#
 public System.String DecryptPassword{ get; set; }
{signature}
{signature:
}
Signature
vb.net
vb.net
Public Property DecryptPassword() As String
{signature}
{remarks}Set {{DecryptPassword}} before calling [Open|ExcelTemplate.Open].

{remarks}
{example}{code:csharp|title=C#}
Remarks

Set DecryptPassword before calling Open.

Example
Code Block
csharp
csharp
titleC#


          ExcelTemplate xlt = new ExcelTemplate();
          xlt.DecryptPassword = "password";
          xlt.Open(Application["templatepath"] +
               @"\DataBinding\EmployeeOrdersTemplate.xls");
        
{code} {code:
Code Block
vb.net
|title=
vb.net
titlevb.net
}


          Dim xlt As New ExcelTemplate()
          xlt.DecryptPassword = "password"
          xlt.Open(Application["templatepath"] & _
               "\DataBinding\EmployeeOrdersTemplate.xls")
        
{code} {example}