Visual design tools and DAL in VS 2005 / .NET 2.0

Ask a Question related to ASP.NET Data Grid Control, Design and Development.

  1. #1

    Default Visual design tools and DAL in VS 2005 / .NET 2.0

    Hi
    I wrote quite a few apps with .NET 1.0 and 1.1, which made use of a Data
    Access Layer, and also used the Microsoft Application Blocks for Data Access
    (v2).

    In VS 2005, there is a huge improvement in 'visually' designing the data
    access, and binding it to the controls on the form.

    I have 'played around' with the SqlDataSource component, which allows very
    quick, easy and simple access to a SQL DB.
    However, I have a couple of considerations, which I would like to get
    opinions on....

    1). If I want to use a common ConnectionString (ie. just have it coded in
    one place), how can I bind each of my controls to this connection?? (ie. I
    don't want to change 100's of controls if my connection string changes).

    2). I want to keep in mind the 'Enterprise' way of doing things, via a DAL
    or Business Layer.
    Does anyone have any good source (C#), which shows the implementation of a
    Front end, DAL, and the component bindings. This can be using SQL commands,
    or Stored procedures, but I would appreciate details of Updates / Inserts
    etc, as well as simple selects (so that I can see the impact on Table
    Adapters etc).

    Thanks in advance


    Paul


    Paul Aspinall Guest

  2. Similar Questions and Discussions

    1. Visual Studio 2005
      Can anyone install VS2005 on Vista 5308?
    2. Visual Studio .NET 2005 using Web Application Project
      Because I wanted the builds for my ASP.NET sites to be a single *.dll in a /bin/ directory (like VSNET 2003), I decided to try the Web Application...
    3. Asp framework 1.1 with Visual Studio 2005
      i try to develop an application asp web on Visual Studio 2005 with the framework 1.1. Is it possible to have this configuration? It 's possible to...
    4. Custom controls / Toolbox / Visual studio 2005
      Hi, Recently upgraded to VS 2005 from 2003. Started rebuilding an asp.net app from scratch. Not using projects (not sure at this point whether I...
    5. Visual Studio 2005 .master extension
      :cool; Has anyone been able to use a template page to update a .master file in Dreamweaver? I've created a template page (ASPTest.dwt) and I want...
  3. #2

    Default Re: Visual design tools and DAL in VS 2005 / .NET 2.0

    Paul,

    See inline:
    > 1). If I want to use a common ConnectionString (ie. just have it coded in
    > one place), how can I bind each of my controls to this connection?? (ie. I
    > don't want to change 100's of controls if my connection string changes).
    Well, you could always load it and then store it in a static variable.
    Then, you just access the static variable.

    The preferred way though is to store it in the app config file. There
    is a specific section for connection strings now. Since there is only one
    app config file for an app, if you know the appropriate key, you can get the
    connection string from any assembly.
    > 2). I want to keep in mind the 'Enterprise' way of doing things, via a DAL
    > or Business Layer.
    > Does anyone have any good source (C#), which shows the implementation of a
    > Front end, DAL, and the component bindings. This can be using SQL
    > commands, or Stored procedures, but I would appreciate details of Updates
    > / Inserts etc, as well as simple selects (so that I can see the impact on
    > Table Adapters etc).
    That's a bit of a tall order. Basically, you are asking for the source
    for a full enterprise application, which is no small task. At the core of
    it though, you should create stored procedures to handle your
    updates/deletes/inserts, as well as your queries. Then, you create your
    data adapters, which will perform the necessary updates, and populate your
    data sets.

    Now, you can use an object layer, if you want, or use data sets for
    transporting your data. Once you decide on that, you can easily bind that
    to your UI.

    Hope this helps.


    --
    - Nicholas Paldino [.NET/C# MVP]
    - [email]mvp@spam.guard.caspershouse.com[/email]
    >
    > Thanks in advance
    >
    >
    > Paul
    >

    Nicholas Paldino [.NET/C# MVP] Guest

  4. #3

    Default Re: Visual design tools and DAL in VS 2005 / .NET 2.0

    Thanks for the reply.

    I'm not asking for code for a full enterprise application. As mentioned, I
    have written Enterprise scale apps with 1.0, and 1.1, using a DAL, and they
    scale well.
    However, the IDE in VS2005 gives a lot more flexibility to put together a
    design graphically.
    I'm really looking for 'Best Practice' guides for creating a DAL, but
    making use of the Graphical design functionality provided by the IDE in VS
    2005, rather than doing it all in code, as I did in 1.0, & 1.1.

    Does such a guide exist?? or are there any examples of doing this anywhere?

    Thanks


    "Nicholas Paldino [.NET/C# MVP]" <mvp@spam.guard.caspershouse.com> wrote in
    message news:Ou25%23x68FHA.1020@TK2MSFTNGP15.phx.gbl...
    > Paul,
    >
    > See inline:
    >
    >> 1). If I want to use a common ConnectionString (ie. just have it coded in
    >> one place), how can I bind each of my controls to this connection?? (ie.
    >> I don't want to change 100's of controls if my connection string
    >> changes).
    >
    > Well, you could always load it and then store it in a static variable.
    > Then, you just access the static variable.
    >
    > The preferred way though is to store it in the app config file. There
    > is a specific section for connection strings now. Since there is only one
    > app config file for an app, if you know the appropriate key, you can get
    > the connection string from any assembly.
    >
    >> 2). I want to keep in mind the 'Enterprise' way of doing things, via a
    >> DAL or Business Layer.
    >> Does anyone have any good source (C#), which shows the implementation of
    >> a Front end, DAL, and the component bindings. This can be using SQL
    >> commands, or Stored procedures, but I would appreciate details of Updates
    >> / Inserts etc, as well as simple selects (so that I can see the impact on
    >> Table Adapters etc).
    >
    > That's a bit of a tall order. Basically, you are asking for the source
    > for a full enterprise application, which is no small task. At the core of
    > it though, you should create stored procedures to handle your
    > updates/deletes/inserts, as well as your queries. Then, you create your
    > data adapters, which will perform the necessary updates, and populate your
    > data sets.
    >
    > Now, you can use an object layer, if you want, or use data sets for
    > transporting your data. Once you decide on that, you can easily bind that
    > to your UI.
    >
    > Hope this helps.
    >
    >
    > --
    > - Nicholas Paldino [.NET/C# MVP]
    > - [email]mvp@spam.guard.caspershouse.com[/email]
    >
    >>
    >> Thanks in advance
    >>
    >>
    >> Paul
    >>
    >
    >

    Paul Aspinall Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139