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
ahmed salah
NA
85
58.8k
How to create connection string to excel sheet 2007 by C#
Feb 28 2017 5:07 AM
I need to know are this connection string to excel is wrong or true
public
static
string
fileName =
string
.Format(
"{0}\\Book502"
, Directory.GetCurrentDirectory());
string
connection =
string
.Format(
"Provider=Microsoft.ACE.OLEDB.12.0;"
+
"Data Source={0};Mode=ReadWrite;Extended Properties='Excel 12.0 Xml;HDR=YES'"
, fileName);
my file book 502
have two sheets
sheet 1
i insert data and update and read data from it
it have following column
ID INTEGER
User Name char(255)
Country char(255)
sheet 2
have following columns
ID INTEGER
Member Name char(255)
meaning all two sheets have text except ID
ALSO file have column in header
processes of two sheets insert update read select
size of transaction i will use 5000 rows
3 USER will use excel sheet
so that what correct format to excel file ?
the format i write working good ?
but really i need what i assign IMEX=0 or 1 or 2
HDR = YES OR NO
Reply
Answers (
6
)
Why not should we movie common functionality in non abstract
by default all checkbox checked