public void store(string a)
{
SqlConnection connect=null;
connect = new SqlConnection("Data Source= (local) ; initial catalog=Student_TrackerDB ; integrated security= true ;");
connect.Open();
connect = new SqlConnection("insert into dbo.Student_Details (named) values (a)");
connect.Close();
}
Remove the space between the "Student_Tracker DB" and Change the Database name and use Credentials if any. For example if you connect database using userID =sa then Also provide password.