You are working with an SDF file. This file is for SQL Server Compact not for SQL Server Express (or full).
In this case the connection string should be simply:
@"Data Source=<fullpath_and file_to_your_sdf_file>;Persist Security Info=False;"
Notice that in C# you need to add the verbatim character in front of strings that contains special characters like the backslash
Working with Sql Server Compact requires to install the libraries required from the Microsoft Downloads and to use the proper classes. So, remove the SqlConnection and the SqlCommand classes and use the SqlCeConnection and SqlCeCommand (and so on for the other data client classes used in you app).
Of course the SqlCeConnection class can understand this different connection string syntax and allow to work with the SDF file
Said that, please revise your code that builds the sql command. Using string concatenation like your code does is a secure recipe for errors. From parsing errors (quotes inside your strings will break the syntax) to more serious error like Sql Injections
This could be an approach using a parameterized query....
try
{
string cmdText = "insert into user values(@p1, @p2, @p3,@p4,@p5,@p6)";
using(SqlCeConnection cnn = new SqlCeConnection(@"Data Source=C:\Users\Hp\Documents\Visual Studio 2010\Projects\Bank_System\Bank_System\Bank_System.sdf;Integrated Security=True"))
using(SqlCeCommand cmd1 = new SqlCeCommand(cmdText, cnn))
{
cnn.Open();
cmd.Parameters.AddWithValue("@p1", textBox6.Text);
cmd.Parameters.AddWithValue("@p2", textBox1.Text);
cmd.Parameters.AddWithValue("@p3", textBox4.Text);
cmd.Parameters.AddWithValue("@p4", textBox3.Text);
cmd.Parameters.AddWithValue("@p5", textBox2.Text);
cmd.Parameters.AddWithValue("@p6", textBox5.Text);
cmd1.ExecuteNonQuery();
MessageBox.Show(" Record inserted ", " information inserted");
}
}
catch (SqlException ex)
{
MessageBox.Show(ex.Message);
}