Morphic Molecules Diamond Morphic Molecules

jsChart
A Javascript Programmable Chart Applet


These pages and Morphic Molecules Components, VBX's, XCMDs, and images
are Copyright Mona M. Everett, Ph.D., 1995

everett@txdirect.net



Morphic Molecules Home Page

Morphic Molecules Services


Internet Link Exchange
Member of the Internet Link Exchange


jsChart is derived from Sun's demonstration Chart Applet. In order for Javascript to interact directly for an applet, the applet must have public variables or methods. The original chart applet has none and so the only way to change applet parameters on the fly is to do a dynamic write/rewrite of a page containing the applet. This method will work in Netscape 2.02 or 3.0. You can see it work on the page Programming Java Applet Parameters

jsChart.class has been created in order to make the chart applet amenable to direct control by Javascript. Although making all of the variables public might seem the easiest way to do this, a changed variable will not be manifest unless a repaint occurs. Sometimes, other variables must also be changed. Consequently, a collection of public methods was developed for the applet; these can be called from Javascript. Parameters for all of these should be passed as strings Three new parameters have been added to the applet: You cannot change the applet dimensions or positioning once it has been drawn.

This page provides a worksheet for you to tryout jsChart's new Javascript callable routines. If you want to use the applet for your NON-COMMERCIAL pages, you can download a zip file with both the source and class files.
Get HTML Get Java



Graph Parameters

Enter a title and click the button to change the graph title:

Enter a new scale factor and click the button to change the scale:

Enter a new number of columns and click the button to change the graph:
(New columns will not appear until you also add parameters for them below)


Column Parameters
Change parameters of column no.
Change value of column to Change caption of column to Click a radio button to change the style:

solid striped
Click a radio button to change the color:
red
blue
yellow
green
black
navy
pink
orange
gray
magenta
cyan
white
darkgray

The source.

This page was last updated on


Mail comments about Morphic Molecules pages to everett@txdirect.net



direct.net