/// <summary>
        ///     Horizontal Bar Chart Data.
        /// </summary>
        /// <param name="FilePath"></param>
        /// <param name="Domain"></param>
        /// <returns name="Data">Data</returns>
        public static HorizontalBarChartData DataFromCSV(
            object FilePath,
            [DefaultArgumentAttribute("Charts.MiscNodes.GetNull()")] Domain Domain)
        {
            // get full path to file as string
            // if File.FromPath is used it returns FileInfo class
            string _filePath = "";

            try
            {
                _filePath = (string)FilePath;
            }
            catch
            {
                _filePath = ((FileInfo)FilePath).FullName;
            }

            HorizontalBarChartData barData = new HorizontalBarChartData();

            barData.Data   = D3jsLib.Utilities.ChartsUtilities.Data1FromCSV(_filePath);
            barData.Domain = Domain;
            return(barData);
        }
Beispiel #2
0
 /// <summary>
 ///     Horizontal Bar Chart
 /// </summary>
 /// <param name="Data"></param>
 /// <param name="Style"></param>
 /// <returns name="Chart">Chart</returns>
 public static D3jsLib.HorizontalBarChart.HorizontalBarChart Chart(HorizontalBarChartData Data, HorizontalBarChartStyle Style)
 {
     D3jsLib.HorizontalBarChart.HorizontalBarChart chart = new D3jsLib.HorizontalBarChart.HorizontalBarChart(Data, Style);
     return(chart);
 }