New to Telerik UI for ASP.NET MVC? Start a free 30-day trial

Defines the fluent API for configuring the PivotGridV2PdfSettings settings.

Definition

Namespace:Kendo.Mvc.UI.Fluent

Assembly:Kendo.Mvc.dll

Syntax:

C#
public class PivotGridV2PdfSettingsBuilder

Inheritance: objectPivotGridV2PdfSettingsBuilder

Inherited Members object.GetType()object.MemberwiseClone()object.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()...

Constructors

C#
public PivotGridV2PdfSettingsBuilder(PivotGridV2PdfSettings settings)
Parameters:settingsPivotGridV2PdfSettings

The PivotGridV2PdfSettings

Methods

Defines the author of the exported PDF document.

C#
public PivotGridV2PdfSettingsBuilder Author(string value)
Parameters:valuestring

The value that configures the author.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.Author("User1"))
)

Specifies if the Print dialog must be opened immediately after loading the document.

C#
public PivotGridV2PdfSettingsBuilder AutoPrint(bool value)
Parameters:valuebool

The value that configures the AutoPrint option.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.AutoPrint(true))
)

Indicates whether to produce actual hyperlinks in the exported PDF file.

C#
public PivotGridV2PdfSettingsBuilder AvoidLinks(bool value)
Parameters:valuebool

The value that configures the AvoidLinks option.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.AvoidLinks(true))
)

Defines the creator of the exported PDF document.

C#
public PivotGridV2PdfSettingsBuilder Creator(string value)
Parameters:valuestring

The value that configures the creator.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.Creator("User1"))
)

Defines the date when the PDF document is created.

C#
public PivotGridV2PdfSettingsBuilder Date(DateTime value)
Parameters:valueDateTime

The value that configures the date of creation.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.Date(DateTime.Now))
)

Specifies the file name of the exported PDF file.

C#
public PivotGridV2PdfSettingsBuilder FileName(string value)
Parameters:valuestring

The value that configures the file name.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.FileName("Exported_PivotGridV2"))
)

If set to "true", the content will be forwarded to the specified ProxyURL even if the browser supports saving files locally.

C#
public PivotGridV2PdfSettingsBuilder ForceProxy(bool value)
Parameters:valuebool

The value that enables or disabled the ForceProxy option.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.ForceProxy(true).ProxyURL(Url.Action("ExportSave", "Home")))
)

Specifies the quality of the images within the exported file (from 0 to 1).

C#
public PivotGridV2PdfSettingsBuilder JpegQuality(double value)
Parameters:valuedouble

The value that configures the JpegQuality option.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.JpegQuality(1))
)

If set to "true", all PNG images contained in the exported file will be kept in PNG format.

C#
public PivotGridV2PdfSettingsBuilder KeepPNG(bool value)
Parameters:valuebool

The value that configures the KeepPNG option.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.KeepPNG(true))
)

Specifies the keywords of the exported PDF file.

C#
public PivotGridV2PdfSettingsBuilder Keywords(string value)
Parameters:valuestring

The value that configures the keywords.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.Keywords("northwind products"))
)

If set to "true", the paper dimensions are reversed (the width is the larger edge).

C#
public PivotGridV2PdfSettingsBuilder Landscape(bool value)
Parameters:valuebool

The value that configures the Landscape option.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf => pdf.Landscape(true))
)

Specifies the margins of the PDF page (numbers or strings with units). The supported units are "mm", "cm", "in" and "pt" (default).

C#
public PivotGridV2PdfSettingsBuilder Margin(Action<PivotGridV2PdfMarginSettingsBuilder> configurator)
Parameters:configuratorAction<PivotGridV2PdfMarginSettingsBuilder>

The action that configures the margins.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf =&gt; pdf.Margin(m =&gt; m.Top(2).Left(2).Right(2).Bottom(2)))
)

Specifies the paper size of the PDF document. The default value is "auto" meaning the paper size is determined by the content. The supported values are "A4", "A3", and more. The supported units are "mm", "cm", "in", and "pt".

C#
public PivotGridV2PdfSettingsBuilder PaperSize(string value)
Parameters:valuestring

The value that configures the PaperSize option.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf =&gt; pdf.PaperSize("A4"))
)

Defines a name or keyword indicating where to display the document returned from the proxy. The default value is "_self".

C#
public PivotGridV2PdfSettingsBuilder ProxyTarget(string value)
Parameters:valuestring

The value that configures the ProxyTarget option.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf =&gt; pdf.ProxyTarget("_target"))
)

The URL of the server side proxy that will stream the file to the end user. The developer is responsible for implementing the server-side proxy. The proxy will receive a POST request with the following parameters in the request body:

  • contentType: The MIME type of the file.
  • base64: The base-64 encoded file content.
  • fileName: The file name, as requested by the caller.

The proxy must return the decoded file with the "Content-Disposition" header set to 'attachment; filename="<fileName.xslx>"'.

C#
public PivotGridV2PdfSettingsBuilder ProxyURL(string value)
Parameters:valuestring

The value that configures the proxy URL.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf =&gt; pdf.ProxyURL(Url.Action("ExportSave", "Home")))
)

Sets the subject of the exported PDF file.

C#
public PivotGridV2PdfSettingsBuilder Subject(string value)
Parameters:valuestring

The value that configures the subject.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf =&gt; pdf.Subject("Products"))
)

Sets the title of the exported PDF file.

C#
public PivotGridV2PdfSettingsBuilder Title(string value)
Parameters:valuestring

The value that configures the title.

Returns:

PivotGridV2PdfSettingsBuilder

Example:
C#
@(Html.Kendo().PivotGridV2()
.Name("pivotgrid")
.Pdf(pdf =&gt; pdf.Title("Internet Sales Amount"))
)