Tech
Forums
Jobs
Books
Events
Videos
Conference
Annual Conference
Bcrypt
Ai Conference
Live
More
Interviews
Certification
Training
Career
Members
News
Blogs
Contribute
An Article
A Blog
A Video
An Ebook
An Interview Question
Register
Login
2
Reply
asp.net connectivity with sql server 2008
Ask a question
Ask a question
Upload Source Code:
Select only zip and rar file.
kritika Rana
11y
1.1k
1
Reply
Hi
I am trying to establish a connection between asp.net and sql server using C# connection string but it shows error that the file name is not specified
My code is like this:
SqlConnection con = new SqlConnection("data source=MYserver;initial catalog=master;integrated security=true");
con.Open();
SqlCommand cmd = new SqlCommand("insert into sqldb values("+textBox1.Text+",'"+ textBox2.Text+"',"+textBox3.Text+",'"+textBox4.Text+"')",con);
cmd.ExecuteNonQuery();
con.Close();
Help me in solving the problem
Thanks
Post
Reset
Cancel
Answers (
2
)
Next Recommended Forum
Inserting Query
to display inbox in mail which control is used