TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
sarika sarikaa
NA
60
8.2k
give me solution in c#
Dec 27 2017 6:21 AM
for to add images in gridview column from mysql database.
private void Form2_Load(object sender, EventArgs e)
{
con = new SqlConnection(@"Data Source=(LocalDB)\MSSQLLocalDB;AttachDbFilename=C:\Users\Admin\source\repos\DATABASE\data2.sql.mdf;Integrated Security=True;Connect Timeout=30");
con.Open();
adpt = new SqlDataAdapter("Select * from Details ", con);
dt = new DataTable();
adpt.Fill(dt);
dataGridView.DataSource = dt;
con.Close();
}
private void txtSearch_TextChanged(object sender, EventArgs e)
{
con = new SqlConnection(@"Data Source=(LocalDB)\MSSQLLocalDB;AttachDbFilename=C:\Users\Admin\source\repos\DATABASE\data2.sql.mdf;Integrated Security=True;Connect Timeout=30");
con.Open();
adpt = new SqlDataAdapter(" select * from Details Where [Part No] like '%"+txtSearch.Text+"%'",con);
dt = new DataTable("Details");
adpt.Fill(dt);
dataGridView.DataSource = dt;
con.Close();
txtSearch.Width = 300;
txtSearch.Height = 70;
txtSearch.Font = new Font("Bold", 15,FontStyle.Bold);
}
Reply
Answers (
7
)
What is the Actual use of Interface and Abstraction?
How I get after decimal point three value with round