All docs
V20.2
20.2
20.1
The page you are viewing does not exist in version 20.1. This link will take you to the root page.
19.2
The page you are viewing does not exist in version 19.2. This link will take you to the root page.
19.1
The page you are viewing does not exist in version 19.1. This link will take you to the root page.
18.2
The page you are viewing does not exist in version 18.2. This link will take you to the root page.
18.1
The page you are viewing does not exist in version 18.1. This link will take you to the root page.
17.2
The page you are viewing does not exist in version 17.2. This link will take you to the root page.

PdfSignatureOptions.DefaultHashAlgorithm Property

Specifies the default hash algorithm to be used in PDF documents generated within the application.

Namespace: DevExpress.XtraPrinting

Assembly: DevExpress.Printing.v20.2.Core.dll

Declaration

public static PdfHashAlgorithm DefaultHashAlgorithm { get; set; }
Public Shared Property DefaultHashAlgorithm As PdfHashAlgorithm

Property Value

Type Description
PdfHashAlgorithm

The default hash algorithm to be used in PDF documents generated within the application.

Property Paths

You can access this nested property as listed below:

Show 15 property paths
Library Object Type Path to DefaultHashAlgorithm
Cross-Platform Class Library RemotePrintingSystem
.ExportOptions.Pdf.SignatureOptions.DefaultHashAlgorithm
ExportOptions
.Pdf.SignatureOptions.DefaultHashAlgorithm
PdfExportOptions
.SignatureOptions.DefaultHashAlgorithm
PrintingSystemBase
.ExportOptions.Pdf.SignatureOptions.DefaultHashAlgorithm
WinForms Controls DiagramControl
DiagramOptionsExport
.PdfExportOptions.SignatureOptions.DefaultHashAlgorithm
PrintingSystem
.ExportOptions.Pdf.SignatureOptions.DefaultHashAlgorithm
XtraSchedulerReport
.ExportOptions.Pdf.SignatureOptions.DefaultHashAlgorithm
WPF Controls DiagramControl
.PdfExportOptions.SignatureOptions.DefaultHashAlgorithm
DiagramDesignerControl
.PdfExportOptions.SignatureOptions.DefaultHashAlgorithm
ExportOptionsContainer
.Pdf.SignatureOptions.DefaultHashAlgorithm
PrintingSystem
.ExportOptions.Pdf.SignatureOptions.DefaultHashAlgorithm
PrintingSystem
.ExportOptions.Pdf.SignatureOptions.DefaultHashAlgorithm
Reporting XtraReport
.ExportOptions.Pdf.SignatureOptions.DefaultHashAlgorithm
DocumentOperationRequest
.ExportOptions.Pdf.SignatureOptions.DefaultHashAlgorithm

Remarks

IMPORTANT

For security reasons, do not set this property to SHA-1.

The code sample below shows how to specify the default hash algorithm for PDF export files to SHA-512.

using DevExpress.XtraReports.UI;
using DevExpress.XtraPrinting;
// ...
// Specify the default hash algorithm.
PdfSignatureOptions.DefaultHashAlgorithm = PdfHashAlgorithm.SHA512;
// Create a simple report.
XtraReport report = new XtraReport() {
  Name = "SimpleReport",
    Bands = {
      new DetailBand() {
        Controls = {
          new XRLabel() {
            Text = "Simple Report"
          }
        }
      }
    }
  }
};
// Export the report to the user's Downloads folder.
report.ExportToPdf(Environment.GetFolderPath(Environment.SpecialFolder.UserProfile) + @"\Downloads\" + report.Name + ".pdf");
See Also