You need to add a reference to System.Configuration and then use:
System.Configuration.ConfigurationManager.
ConnectionStrings["connectionStringName"].ConnectionString;
You need to add a reference to System.Configuration and then use:
System.Configuration.ConfigurationManager.
ConnectionStrings["connectionStringName"].ConnectionString;