Hi,
I am trying to add sales values inside the bar of the google bar chart. But
did not succeed. Please can someone help me. I have following markup.
<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master"
AutoEventWireup="true" CodeFile="test.aspx.cs" Inherits="test" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent"
runat="Server">
<script type="text/javascript"
src="https://www.google.com/jsapi"></script>
<script type='text/javascript'>
google.load('visualization', '1', { packages: ['bar'] });
google.setOnLoadCallback(drawAntalChart);
function drawAntalChart() {
var data = google.visualization.arrayToDataTable([
['Projektledare', 'Sale', 'Avg Sale'],
['Wiberg', 26030, 13015],
['Andersson ', 461690, 19237.08],
['Ranheimer', 304045, 33782.78]]);
var options = { chart: { title: 'Projektledning: Sales' } };
var chart = new
google.charts.Bar(document.getElementById('div_chart')); chart.draw(data,
options);
} </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent"
runat="Server">
<div id="div_chart" style="height: 400px; text-align: left;"></div>
</asp:Content>
Picture attached how the graph look.
Thanks in advance
--
You received this message because you are subscribed to the Google Groups
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit
https://groups.google.com/d/msgid/google-visualization-api/5d68bf0e-eb70-46ab-8ff1-823b1663e48a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.