Integration/Tutorials/Customizing-Izenda-Settings.md
... ...
@@ -2,11 +2,11 @@
2 2
3 3
[[_TOC_]]
4 4
5
-###Introduction: common code additions
5
+##Introduction: common code additions
6 6
7 7
Izenda Reports can be integrated with the navigation, security, and appearance of existing applications. This is done through the code-level API, which can be accessed and extended through the **AdHocConfig** and **AdHocSettings** classes. By default, the Izenda starter kit includes pre-built code templates, which can be found in Global.asax. Here you will find settings that set critical values like the connection string and license key as well as a custom **AdHocConfig** implementation that overrides common methods. Here is an example of what a common global.asax might look like.
8 8
9
-###Sample Global.asax file
9
+##Sample Global.asax file
10 10
11 11
``` c#
12 12
<%@ Application Language="C#" %>
... ...
@@ -62,7 +62,7 @@ For more a more detailed code sample, click any of the headings.
62 62
* PostLogin() Add per-user code here, such as setting the username and other per-user settings.
63 63
* PreExecuteReportSet() Add hidden filters and other code which needs to run before the report is displayed to the user.
64 64
65
-###How do I add custom code?
65
+##How do I add custom code?
66 66
67 67
To enable a custom configuration, we must put the key and connection string in the ``Session_Start()`` method, even though they have already been set in the **Settings.aspx** page. Otherwise, the Izenda Reports application will ignore the ``Configure_Settings()`` method completely and only use the settings set in the **settings.aspx** page. To enable custom code:
68 68
... ...
@@ -74,7 +74,7 @@ To enable a custom configuration, we must put the key and connection string in t
74 74
75 75
You may now add custom code to Izenda Reports.
76 76
77
-**AdHocSettings and AdHocConfig: The Main Integration Objects**
77
+##AdHocSettings and AdHocConfig: The Main Integration Objects
78 78
79 79
Izenda Reports is an ASP.NET application and utilizes an object model. There are two classes upon which an integrator should primarily focus. These classes contain many settings and methods that will help you integrate our application with yours.
80 80
... ...
@@ -85,7 +85,7 @@ Izenda Reports is an ASP.NET application and utilizes an object model. There are
85 85
86 86
Both of these classes are customized by adding your code into the global.asax file, as shown above.
87 87
88
-**Creating a custom AdHocConfig class using the Global.asax file**
88
+##Creating a custom AdHocConfig class using the Global.asax file
89 89
90 90
By putting code in the **global.asax** file, you are simply choosing to use the ``CustomAdHocConfig`` class, which will extend either database mode or file system mode. Unless you specifically override the methods, they will retain their default behavior.
91 91
... ...
@@ -95,7 +95,7 @@ In general, most custom code will be placed in the **Global.asax** file. [[Pleas
95 95
* Per User Basis/Per Role Basis/etc - This type of code applies to different users in different ways. We recommend that this type of code should be contained in the ``PostLogin()`` method. Note that this method needs to be called from your application's authentication process. [[Please see this example for details]].
96 96
* Per Report/Custom Processing of Reports - Applied before execution of each report. Generally, this is used for applying hidden filters. This code needs to be placed in the ``PreExecuteReportSet()`` method. [[Please see this example for details]].
97 97
98
-**Calling Izenda Reports from your application**
98
+##Calling Izenda Reports from your application
99 99
100 100
The ``CustomAdHocConfig`` class contains a variety of methods that can be overridden to your specifications. Initially, the two most important are global and per-user configuration settings.
101 101
... ...
@@ -103,7 +103,7 @@ The ``CustomAdHocConfig`` class contains a variety of methods that can be overri
103 103
* Per-user settings: place your code in the ``PostLogin()`` method and invoke this method from your application by calling:
104 104
* ``Izenda.AdHoc.AdHocSettings.AdHocConfig.PostLogin();``
105 105
106
-**What if my **global.asax** is already integrated or I cannot use it?**
106
+##What if my global.asax is already integrated or I cannot use it?
107 107
108 108
In the case that you will not be using the **global.asax** file or that you are using a different **global.asax** than Izenda's, you will need to make sure that you set the license key before invoking any of the configuration methods or settings in Izenda Reports. You can set the license key with:
109 109