Dec 26, 2012 at 6:45 AM
Edited Dec 26, 2012 at 6:47 AM
When i first login to the database, I connect to DB-A to get user information, this user information is stored in session..
I am able to get the user information from DB-A. Then when I go to the next page, I need to connect to DB-B which has all the other required information.
I am using EntLib Data and have set up my DB factory class as
public static class DbFactory
/// Create an instance of default database connection.
/// <returns>Database Object</returns>
public static Database Create()
/// Creates an instance of a specified database connection.
/// <param name="name">Database Object</param>
public static Database Create(string name)
Now in the Page after login I am trying to access Db-B by passing the connection string in the Create(name) method. Getting an "activation error occured while trying to get instance of type database".
Can you please help me in resolving this error or letting me know how to connect to different databases using EntLib.