init repo
This commit is contained in:
47
OfficeWeb/sdk/Common/Charts/examples/basic.html
Normal file
47
OfficeWeb/sdk/Common/Charts/examples/basic.html
Normal file
@@ -0,0 +1,47 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="X-UA-Compatible" content="chrome=1">
|
||||
<title>A basic example of an OfficeExcel chart</title>
|
||||
|
||||
<meta name="keywords" content="javascript charts html5 canvas basic example" />
|
||||
<meta name="description" content="A basic example of an OfficeExcel chart for implementation help" />
|
||||
<meta name="googlebot" content="NOODP">
|
||||
|
||||
<script src="../libraries/OfficeExcel.common.core.js" ></script>
|
||||
<script src="../libraries/OfficeExcel.bar.js" ></script>
|
||||
<!--[if lt IE 9]><script src="../excanvas/excanvas.original.js"></script><![endif]-->
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>A basic example</h1>
|
||||
|
||||
<!-- 2/3. This is the canvas that the graph is drawn on -->
|
||||
<canvas id="myBar" width="1000" height="250">[No canvas support]</canvas>
|
||||
|
||||
<!--
|
||||
3/3. This creates and displays the graph. As it is here, you can call this from the window.onload event,
|
||||
allowing you to put it in your pages header.
|
||||
-->
|
||||
<script>
|
||||
window.onload = function ()
|
||||
{
|
||||
var bar = new OfficeExcel.Bar('myBar', [12,13,16,15,16,19,19,12,23,16,13,24]);
|
||||
bar.Set('chart.gutter.left', 35);
|
||||
bar.Set('chart.colors', ['red']);
|
||||
bar.Set('chart.title', 'A basic chart');
|
||||
bar.Set('chart.labels', ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec']);
|
||||
bar.Draw();
|
||||
}
|
||||
</script>
|
||||
|
||||
<p>
|
||||
This is a very basic example that does little more than display a chart. If you're trying to understand how OfficeExcel
|
||||
works, this should help as there is very little happening on this page. To see the source code of this
|
||||
page simply view the source (Right click > View Source).
|
||||
</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user