A connection, to be opened, need to know where is located the server, what database you want to open and other administrative information. Your code doesn't supply these info when you call the constructor of the SqlConnection. You need to pass a connectionstring.
con = ( con == null ? new SqlConnection(connectionString) : con );
if (con.State != System.Data.ConnectionState.Open)
con.Open();
An example of a connection string is:
string connectionstring = @"Server=serverName;Database=dbName;
User Id=userName;Password=password;"
Other examples of a connection string could be found at this site