juaritos Report post Posted October 12, 2010 I'm trying to export using ASP.NET MVC. Found the export handlers for ASP.NET, but these won't compile as is. What changes do we need to do in order include these on an MVC based app? Thanks Share this post Link to post Share on other sites
FusionCharts Support Report post Posted November 25, 2010 Please find the attached Zip containing sample in MVC with export feature. SimpleWebMVC_WithExport.zip.txt Share this post Link to post Share on other sites
osalmon Report post Posted December 14, 2010 Please find the attached Zip containing sample in MVC with export feature. Thank you. Is there a similar sample with data coming from a database? Share this post Link to post Share on other sites
FusionCharts Support Report post Posted May 18, 2011 Hi, I am afraid as of now there is no sample with data from database, but you can always use the code from our ASP.NET database samples from Code folder of our download pack. Share this post Link to post Share on other sites
mganley2000 Report post Posted November 16, 2011 That MVC3 sample validates what I did at the root level. But it does not use Areas. But, I did figure out the issue when Areas are in-play. I have to adjust the path to the SWF file when I am adding the chart javascript when I am in a particular view within an area. Seems simple, now that I have it figured out. Basically, if you have defined an area name "Demo", so that it essentially lives within the Areas folder. And, say your controller is "HomeController", and your view is "Home", action is "Index", you would reach that page with one of these URL's, for example (given that you route this correctly.) www.mysite.com/MyApp/Demo/Home www.mysite.com/MyApp/Demo/Home/Index To allow that path to render a chart you have place on your page in Flash, the path to your FusionCharts folder off your root would need to be as shown here: var myChart = new FusionCharts("../../FusionCharts/Line.swf", "myChartId", "400", "300", "0", "1"); If you did NOT use Areas, and your URL was straight to a Home controller, your path would have just been: var myChart = new FusionCharts("FusionCharts/Line.swf", "myChartId", "400", "300", "0", "1"); **** And, I realized, that if you are forcing pure javascript/HTML5 rendering, it simply parses the chart type from that first argument. You can simply provide "Line", and you get a line chart. Not sure if that is documented. Probably not, since it desires the full path if you let it run normally with Flash as the first choice. **** Share this post Link to post Share on other sites
Guest Angshu Report post Posted November 17, 2011 Hi, Thank you very much for your valuable feedback. Happy FusionCharting! Share this post Link to post Share on other sites