Application Blocks Question RRS feed

  • Question

  • User-498867758 posted

    I am new to App Blocks and would like to use them to support my 3.5 .net web app.  I dl'ed and installed the Enterprise library, but I cannot find the application blocks to reference them in my app.

    What I DO see when I add a refernce to (for example) Enterprise Library Data Library Application Block is a new reference in my project to Microsoft.Practices.EnterpriseLibrary.Data, which doesn't appear to be the same thing (e.g. no SQLHelper class).

    Can anyone please tell me what I am doing wrong here?

    Thank you

    Tuesday, May 4, 2010 12:50 PM

All replies

  • User-1366948256 posted

    Application blocks are part of enterprise library now. You can add reference to following dlls from enterprise library.

    You need to reference enterprise library data access application block.

    Here is the link that might help you.



    Wednesday, May 5, 2010 6:14 AM
  • User-37275327 posted

    Add following referece to your project. Dlls are stored in C:\Program Files\Microsoft Enterprise Library 3.1 - May 2007\Bin folder



    simply you can insert records as following

    using System;
    using System.Collections.Generic;
    using System.Text;
    using System.Data;
    using System.Data.Common;
    using Microsoft.Practices.EnterpriseLibrary.Common;
    using Microsoft.Practices.EnterpriseLibrary.Data;

    public void InsertTestData()
                        Database db = DatabaseFactory.CreateDatabase(Database_Connection_Name);
                        DbCommand command = db.GetStoredProcCommand(SP_InsertTestData);
                        db.AddInParameter(command, "@vcName", DbType.String, txtName.text);
                        db.AddInParameter(command, "@vcAge", DbType.String, txtAge.text);

                    catch (Exception ex)
                        throw ex;


    Friday, May 7, 2010 5:15 AM
  • User480443335 posted

    you have to create the new application settings in your entrerprise library over there u have to add those blocks which u need if for ur application...

    This is how u can do as below mentioned steps:

    1. click start

    2.select programs

    3.select Microsoft Patterns and practices

    4. select Enterprise Library

    5.select Enterprise Library configuration

    6. click on file, then open application

    7. select EntLibConfig.exe.config

    8.Right click on Enterprise Library configuration which is showed in left hand side. then select new application.

    9.Now choose which block of enterprise library u need.

    Please do let me know about the solution i have provided..Mark it as answer if its solution for the problem.......<input name="ctl00$ctl00$bcr$bcr$ctl00$PostList$ctl05$ctl07$ctl01" id="ctl00_ctl00_bcr_bcr_ctl00_PostList_ctl05_ctl07_ctl01_State" value="value:Filed%20under%3A%20%3Ca%20href%3D%22%2Ftags%2FPlease%2Bdo%2Blet%2Bme%2Bknow%2Babout%2Bthe%2Bsolution%2Bi%2Bhave%2Bprovided_2E002E00_Mark%2Bit%2Bas%2Banswer%2Bif%2Bits%2Bsolution%2Bfor%2Bthe%2Bproblem%2Fdefault.aspx%22%20rel%3D%22tag%22%3EPlease%20do%20let%20me%20know%20about%20the%20solution%20i%20have%20provided..Mark%20it%20as%20answer%20if%20its%20solution%20for%20the%20problem%3C%2Fa%3E" type="hidden">

    Friday, May 7, 2010 7:53 AM