Thank you very much! Here is the code...
HTML Mark up:
<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="MyPage.aspx.vb" Inherits="X.MyPage" UICulture="es-CR" Culture="es-CR" MaintainScrollPositionOnPostback="true" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>MyPage</title>
</head>
<body>
<form id="form1" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server" EnableScriptGlobalization="true" EnableScriptLocalization="true"></asp:ScriptManager>
<div>
<asp:UpdatePanel ID="UpdatePanel1" runat="server" ChildrenAsTriggers="false" UpdateMode="Conditional">
<ContentTemplate>
<div style="margin:auto auto">
<cc1:Accordion ID="Accordion1" runat="server" CssClass="center_" FadeTransitions="true" TransitionDuration="500" SelectedIndex="-1" RequireOpenedPane="false" HeaderCssClass="headers" ContentCssClass="contents" Width="80%" AutoSize="none">
<Panes>
<cc1:AccordionPane ID="AccordionPane1" runat="server" ContentCssClass="contents" HeaderCssClass="headers">
<Header>
<h2>Sample</h2>
</Header>
<Content>
<table>
<tr>
<td style="margin:0 auto;">
<cc1:PieChart ID="PieChart1" BackColor="White" runat="server" BorderStyle="None" Width="100%" > </cc1:PieChart>
</td>
</tr>
</table>
</Content>
</cc1:AccordionPane>
</Panes>
</cc1:Accordion>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</form>
</body>
</html>
Code Behind
Imports System.Data.SqlClient
Imports System.IO
Public Class MyPage
Inherits System.Web.UI.Page
Dim conn As New SqlClient.SqlConnection("Connection_string")
Dim cmd As New SqlClient.SqlCommand
Dim dr As SqlClient.SqlDataReader
Dim SQL_trans As SqlTransaction
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
PieChart1.PieChartValues.Add(New AjaxControlToolkit.PieChartValue() With { _
.Category = "Value1", _
.Data = 8})
PieChart1.PieChartValues.Add(New AjaxControlToolkit.PieChartValue() With { _
.Category = "Value2", _
.Data = 0})
PieChart1.PieChartValues.Add(New AjaxControlToolkit.PieChartValue() With { _
.Category = "Value3", _
.Data = 0})
End If
End Sub
Here I set fixed values to the piechart to reduce the code size, but it works on the same way if I got data from database.
I think that this code may show a piechart with a single slice representing a 100%, but it doesn't show nothing...