<%@ Page AutoEventWireup="false" CodeFile="DefaultVB.aspx.vb" Inherits="ClientExportManager.Functionality.Types.DefaultVB"Language="vb" %>
<%@ Register TagPrefix="qsf" Namespace="Telerik.QuickStart" %>
<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
<!DOCTYPE html>
<html xmlns='http://www.w3.org/1999/xhtml'>
<head runat="server">
<title>Telerik ASP.NET Example</title>
<!-- Load Pako ZLIB library to enable PDF compression -->
<script src="../../../Common/Scripts/pako.min.js"></script>
</head>
<body>
<form id="form1" runat="server">
<telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
<telerik:RadSkinManager ID="RadSkinManager1" runat="server" ShowChooser="true" />
<div class="demo-container">
<telerik:RadButton RenderMode="Lightweight" runat="server" OnClientClicked="exportPDF" Text="Export RadGrid to PDF" AutoPostBack="false" UseSubmitBehavior="false"></telerik:RadButton>
<telerik:RadButton RenderMode="Lightweight" runat="server" OnClientClicked="exportImage" Text="Export RadGrid to Image" AutoPostBack="false" UseSubmitBehavior="false"></telerik:RadButton>
<telerik:RadButton RenderMode="Lightweight" runat="server" OnClientClicked="exportSVG" Text="Export RadGrid to SVG" AutoPostBack="false" UseSubmitBehavior="false"></telerik:RadButton>
<telerik:RadClientExportManager runat="server" ID="RadClientExportManager1">
</telerik:RadClientExportManager>
<br />
<telerik:RadGrid RenderMode="Lightweight" runat="server" ID="GridView1" CssClass="MyGrid" DataSourceID="SqlDataSource1">
</telerik:RadGrid>
<asp:SqlDataSource runat="server" ID="SqlDataSource1" ConnectionString="<%$ ConnectionStrings:NorthwindConnectionString %>" SelectCommand="SELECT TOP 10 ProductID, ProductName, SupplierID, CategoryID, QuantityPerUnit, UnitPrice, UnitsInStock, UnitsOnOrder, ReorderLevel, CategoryName FROM [Alphabetical list of products]"></asp:SqlDataSource>
</div>
<script>
var $ = $telerik.$;
function exportPDF() {
$find('<%=RadClientExportManager1.ClientID%>').exportPDF($(".MyGrid"));
}
function exportImage() {
$find('<%=RadClientExportManager1.ClientID%>').exportImage($(".MyGrid"));
}
function exportSVG() {
$find('<%=RadClientExportManager1.ClientID%>').exportSVG($(".MyGrid"));
}
</script>
</form>
</body>
</html>