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
yokzu
NA
306
0
Writing a column's all rows
Nov 4 2010 10:51 PM
Hi,
Im working with an excel file. For exampler there is 500 rows in the sheet and 4 columns in the sheet. First 3 columns have data but 4th columns is empty. I want to write this column's all rows' "1. row", "2. row", "3.row"...
My codes below.. How can i do that?
4.th colon
-------
1.row
2.row
3.row
...
------
string query_ci = "SELECT [Kolon1],[Kolon2],[Kolon3] FROM[Sheet6$A:J] WHERE [Kolon1]='" + kolon_bul+ "'";
OleDbDataReader rdr_ci;
OleDbCommand komut_ci = new OleDbCommand(query_ci, conn);
rdr_ci = komut_ci.ExecuteReader();
int a=0;
while (rdr_ci.Read())
{
OleDbCommand komut = new OleDbCommand("UPDATE [Sheet6$] SET [Kategori]='"+a.ToString()+ column"' WHERE="
??????
" ", baglanti); ---->
What should be here?
komut.ExecuteNonQuery();
a += 1;
}
Reply
Answers (
2
)
Date control
Datareader's row count?