Download the graph javascript file from this location: Graphs.zip
This must be unpacked and the graphs.js file placed on your IFS in folder esdi/websmart/javascript/
In the PML:
Add a workfield called selstring which is 256 Alpha
Add a workfield called atotal which is 10 Alpha
Add a workfield called ordtot which is 9, 2 Numeric
Add a workfield called month which is 2, 0 Numeric
Add the function monthvalues taken from this PDW. This function grabs the data used to create the graph
In the HTML:
Add the javascript into the HTML by adding the following line of code into the HEAD portion of MainSeg: < script language="JavaScript" type="text/javascript" src="/websmart/javascript/graphs.js">< /script> Note: Spaces were added for display purposes. You can copy and paste the correct code from this PDW
Add the javascript function that creates the graph: < script language="JavaScript">
graph = new BAR_GRAPH("vBar");
graph.values = "< func name="monthvalues">";
graph.labels = "Jan.,Feb.,Mar.,Apr.,May,Jun.,Jul.,Aug.,Sep.,Oct.,Nov.,Dec.";
document.write(graph.create());
< /script> Note: Spaces were added for display purposes. You can copy and paste the correct code from this PDW