Assign global connection string

Assign global connection string

Postby Thomas J. » Thu 03 Feb 2011 10:17

Hello all,
I do my first steps in ASP.NET.
I have a WebForm in VS2010 with a MySqlDataSource and the connection string I assign in the Page_Load method. But this I have to do for every page. This is not fine.

In C++Builder Desktop application I have a Connection component and this I assign to the several datasources once via designer and not every time via source.

Is this also possible in ASP.NET with your component.

Right now my code is below
Code: Select all
        protected void Page_Load(object sender, EventArgs e)
            // ConfigurationSettings.AppSettings("CratemakerDB");
            NameValueCollection names = ConfigurationManager.AppSettings;
            String value = names.Get("CratemakerDB");
            MyDsFirma.ConnectionString = value;

Thomas J.
Posts: 95
Joined: Mon 21 Nov 2005 12:16
Location: Germany

Postby Shalex » Fri 04 Feb 2011 14:07

As I understood, you are talking about the capabilities of InterForm Technology: This feature is available only in the WinForms projects.
Devart Team
Posts: 7945
Joined: Thu 14 Aug 2008 12:44

Return to dotConnect for Oracle