If I take the same code (for a pie chart) and try to put it in an html, there’s something wrong with the background color : http://puu.sh/2XwaF/ca472d0059.png
I can’t seem to find the problem.
Sunil Urs says:
Mythique,
You are probably using an older version of CanvasJS – that bug has been fixed. Please download the latest version and it should work fine.
Fabrizio says:
Hi all,
is there a way to use a background image instead of background colours?
Cheers
Sunil Urs says:
It is not available directly as part of the API but you can do the same in two steps.
1. Set backgroundColor property of chart to null or empty string “”
2. Set background-image of chart container using CSS.
Hi Sunil garu .. in this pieChart first time its loading the percent value .. and when i do second it will not updating could you please tell me the solutions… if you want check this i will give credentials ……..
It would help us to understand the issue and resolve it if you can reproduce the same in JSFiddle.
manimaran.S says:
How we can add gradient color for bar chat..
manimaran.S says:
In pie chart, i cant able to override background color,,,its showing black color only…,i tried below propery
backgroundColor: “#F5DEB3”..any solution to add custom background color for pie chart…
Naveen Venugopal says:
We are not able to reproduce the issue. Can you please create a jsfiddle for this. So that we can look into it.
I think you are not getting my feeling … ok i will send website with credentials once you will check please for me then you will get an idea …
divewebapp.azurewebsites.net
name: Sekhar
pwd: 123
problem : Web Trafic graps : if u check you will get an idea
Shania Twain says:
Hi, is there any way of colouring the chart area in different colours? I would like to colour above 0 on the y axis in one colour and below 0 in another. Thanks. PS superb library, thanks!
Vishwas R says:
Shania,
You can use multiple stripLines to achieve this. Here is an example.
If you have any questions, please feel free to ask in our forums. Ask Question
If I take the same code (for a pie chart) and try to put it in an html, there’s something wrong with the background color : http://puu.sh/2XwaF/ca472d0059.png
I can’t seem to find the problem.
Mythique,
You are probably using an older version of CanvasJS – that bug has been fixed. Please download the latest version and it should work fine.
Hi all,
is there a way to use a background image instead of background colours?
Cheers
It is not available directly as part of the API but you can do the same in two steps.
1. Set backgroundColor property of chart to null or empty string “”
2. Set background-image of chart container using CSS.
Hi Sunil garu .. in this pieChart first time its loading the percent value .. and when i do second it will not updating could you please tell me the solutions… if you want check this i will give credentials ……..
webdata1 = parseInt((parseInt(webdata[0].ContentCount) / totalCount) * 100);
var webdata2=0;
webdata2 = parseInt((parseInt(webdata[1].ContentCount) / totalCount) * 100);
$(‘#demo-pie-2’).attr(‘data-percent’, webdata2);
window.chart2=webdata2;
$(‘#WTa2’).text(webdata[1].WebSite);
$(‘#WTa2’).attr(“href”, ‘@Url.Action(“ContextIndex”,”Context”)?ContentDetail=’ + window.searchterm + ‘&LastViewType=’ + window.Lastview + ‘&websitetype=’ + window.Websitetype + ‘&IsTrackedTerm=’ + window.Istrackedterm + ‘&SubsearchContent=’ + Subsearchterm + ‘&getRssFeedLinkid=’ + webdata[1].RssFeedLinkID);
$(‘#WTa2’).attr(“Title”,webdata[1].WebSite);
$(‘#demo-pie-2’).pieChart({
barColor: ‘#FACB07’,
trackColor: ‘#eee’,
lineCap: ‘butt’,
lineWidth: 12,
onStep: function () {
$(this.element).find(‘.pie-value’).text(Math.round(window.chart2));
}
});
Raju,
It would help us to understand the issue and resolve it if you can reproduce the same in JSFiddle.
How we can add gradient color for bar chat..
In pie chart, i cant able to override background color,,,its showing black color only…,i tried below propery
backgroundColor: “#F5DEB3”..any solution to add custom background color for pie chart…
We are not able to reproduce the issue. Can you please create a jsfiddle for this. So that we can look into it.
Does it support Transparent Background ?
Debasish,
Yes , it supports transparent background. You can achieve this by setting backgroundColor: “transparent”.
Can some help me in adding Background image if the chart or create a JSFiddle?
Sunshine,
Here is a fiddle that shows how to add background image to chart.
I think you are not getting my feeling … ok i will send website with credentials once you will check please for me then you will get an idea …
divewebapp.azurewebsites.net
name: Sekhar
pwd: 123
problem : Web Trafic graps : if u check you will get an idea
Hi, is there any way of colouring the chart area in different colours? I would like to colour above 0 on the y axis in one colour and below 0 in another. Thanks. PS superb library, thanks!
Shania,
You can use multiple stripLines to achieve this. Here is an example.