How to make horizontal bar chart with 100% as limit?


Am making a 3 series stackedH bar chart

the start is 0% with 20% increments and 100% the last one

Im hoping to show the background color as either white or bland pastel and the value of each item to be colored like dark blue or green

have had trouble with the labels and making it look nice. Am using a standard example and am going to utilize variables for the 3 values of 0-100 but how to code this? have not been able to figure out the design tool, thanks


[code] var1= “@Model.Myvar1”;
quotient1 = (100 - var1);
var2 = “@Model.Myvar1”;
quotient2 = (100 - var2);
var3= “@Model.Myvar2”;
quotient3 = (100 - var3);

                myBarChart = new dhtmlXChart({
                    view: "stackedBarH",
                    container: "chartDiv",
                    value: "#used#",

(… other variables…)

value: “#rrmain#”,
color: “#25c1c4”,
label: “”
my_data = [{ used: var1, rrmain: quotient1, rname: “first bar” },
{ used: var2, rrmain: quotient2, rname: “second bar” },
{ used: var3, rrmain: quotient3, rname: “third bar” }];

                myBarChart.parse(my_data, "json");


so the trick is that you have to subtract from 100 and get the 2 parts so that they end at 100