This project is read-only.

Possible limitation when using transactions

Aug 10, 2009 at 3:10 PM

For those, like me, that use external configuration files tho define all application settings there is a limitation on your code. Só I have decided to change the private static SqlConnection GetTransactionSqlConnection(string connectionStringName) method.

//string connectionString = ConfigurationManager.ConnectionStrings[connectionStringName].ConnectionString;
//connection = new SqlConnection(connectionString);

connection = new SqlConnection(connectionStringName);
I've commented the lines i've disabled and added a line to set the connection using the supplied connection string insted of triing to read it from the web.config file. I suppose this is a solution that will support all needs.