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
Zeb Muhammad
NA
67
18k
import Data from Excel to under The columns of DatagridView.
Aug 10 2017 4:07 AM
Dear Friends
first I want to say thank you all , You have a stuning Job here.
Secondly,
I Want to Import Data from Excel File to My DataGrideview columns.
I tried but data coms after My added columns.Please, Check my code bellow.
private
void
button8_Click_1(
object
sender, EventArgs e)
{
string
content =
"provider=Microsoft.Jet.OLEDB.4.0;Data Source="
+ strExcelPathName.Text +
"; Extended Properties=\"Excel 8.0;\";"
;
OleDbConnection con =
new
OleDbConnection(content);
OleDbDataAdapter oda =
new
OleDbDataAdapter(
"SELECT * FROM["
+ txtSheet.Text +
"$]"
, con);
DataTable dt =
new
DataTable();
oda.Fill(dt);
dataGridView1.DataSource = dt;
}
please, help me
Reply
Answers (
3
)
Embedded image in Resource reported error ?
I want 2 convert div tag into link t have 2 try like