API/CodeSamples/ChartingEngine.md
... ...
@@ -0,0 +1,57 @@
1
+#ChartingEngine
2
+
3
+[[_TOC_]]
4
+
5
+##About
6
+Sets the charting engine to be DundasCharts or HTMLCharts.
7
+
8
+**Default Value:** The Global.asax file in C# is defaulted to be HTMLCharts. If left unspecified in the global.asax file, it will resort to DundasCharts, which is the default in the Izenda DLL. For VisualBasic, nothing is defaulted in the Global.asax file, so it is defaulted to DundasCharts.
9
+
10
+##Global.asax (C#)
11
+
12
+```csharp
13
+public class CustomAdHocConfig : FileSystemAdHocConfig {
14
+ public static void InitializeReporting() {
15
+ //Check to see if we've already initialized.
16
+ if (HttpContext.Current.Session == null || HttpContext.Current.Session["ReportingInitialized"] != null)
17
+ return;
18
+ //Initialize System
19
+ AdHocSettings.LicenseKey = "INSERT LICENSE KEY HERE";
20
+ AdHocSettings.SqlServerConnectionString = @"INSERT CONNECTION STRING HERE";
21
+ AdHocSettings.GenerateThumbnails = true;
22
+ AdHocSettings.DashboardViewer = "Dashboards.aspx";
23
+ AdHocSettings.ShowSimpleModeViewer = true;
24
+ AdHocSettings.IdentifiersRegex = "^.*[iI][Dd]$";
25
+ AdHocSettings.TabsCssUrl = "Resources/css/tabs.css";
26
+ AdHocSettings.ReportCssUrl = "Resources/css/Report.css";
27
+ AdHocSettings.ShowBetweenDateCalendar = true;
28
+ AdHocSettings.AdHocConfig = new CustomAdHocConfig();
29
+ AdHocSettings.PrintMode = PrintMode.Html2PdfAndHtml;
30
+ AdHocSettings.ChartingEngine = ChartingEngine.HtmlChart; //relevent setting, default in Global.asax
31
+
32
+
33
+```
34
+
35
+```visualbasic
36
+
37
+ <Serializable()> Public Class CustomAdHocConfig
38
+ Inherits FileSystemAdHocConfig
39
+ Public Shared Sub InitializeReporting()
40
+ 'Check to see if we've already initialized.
41
+ If (HttpContext.Current.Session Is Nothing OrElse (Not (HttpContext.Current.Session("ReportingInitialized") Is Nothing))) Then
42
+ Return
43
+ End If
44
+ 'Initialize System
45
+ AdHocSettings.LicenseKey = "Insert_license_key_here"
46
+ AdHocSettings.SqlServerConnectionString = "Insert_connction_string_here"
47
+ AdHocSettings.GenerateThumbnails = True
48
+ AdHocSettings.DashboardViewer = "Dashboards.aspx"
49
+ AdHocSettings.ShowSimpleModeViewer = True
50
+ AdHocSettings.IdentifiersRegex = "^.*[iI][Dd]$"
51
+ AdHocSettings.TabsCssUrl = "Resources/css/tabs.css"
52
+ AdHocSettings.ReportCssUrl = "Resources/css/Report.css"
53
+ AdHocSettings.ShowBetweenDateCalendar = True
54
+ AdHocSettings.AdHocConfig = New CustomAdHocConfig()
55
+ AdHocSettings.ChartingEngine = ChartingEngine.HtmlChart //relevent setting to change to HTML Charts
56
+
57
+```
... ...
\ No newline at end of file