To use features of the Enterprise Library with your data provider, download Microsoft Enterprise Library from http://www.codeplex.com/entlib. The Enterprise Library installation by default includes the Enterprise Library documentation, which contains detailed information about using the application blocks.To enable the Logging Application Block output, set the environment property DDTek_Enable_Logging_Application_Block_Trace to true. Alternatively, in the app.config file, set the AppSetting property DDTek.EnableLoggingApplicationBlock to true.
1 Select Start / Programs / Microsoft patterns and practices / Enterprise Library 4.1 - October 2008 / Enterprise Library Configuration. The Enterprise Library Configuration window appears.
2
3
4
5 In the Name pane, select Name. Type the name of the new category, and then press ENTER. In the following example, the category name DDTek Error will be created.
7 Right-click the new category and select New / TraceListener Reference. A Formatted EventLog TraceListener node is added. From the ReferencedTraceListener drop-down list, select Formatted EventLog TraceListener.
9 Select File / Save Application. The Save As window appears. Type a name for your configuration file. By default, the file is saved to C:\Program Files\Microsoft Enterprise Library October 2008\Bin\filename.exe.config, where filename is the name that you typed in the Save As window.
1 Select Start / Programs / Microsoft patterns and practices / Enterprise Library 4.1 - October 2008 / Enterprise Library Configuration, and select File / New Application.
2 Right-click Application Configuration, then select New / Logging Application Block. The Configuration section appears in the right pane.