In .Net is there a class in .Net where you can get the DB name, and all the connection string info without acutally doing a substring on the connection string?
EDIT:
SqlConnection sq = new SqlConnection(ConnectionString);
Reference
Done with "using" statement (from MSDN)
using (SqlConnection connection = new SqlConnection(connectionString)) { connection.Open(); // Do work here; connection closed on following line. }