N
Nakhi
Hi,
my code is very simple.
dim cm as oledbcommand= new oledbcommand("select * from page " ,cn)
cn.open()
Dim dr As OleDbDataReader = cm.ExecuteReader()
dim cate=dr.getstring(1) 'error line"
label1.text=cate
but there is error for dr.getstring(1), the error reads:the data of this
column does not exist:
I am sure the second line exist(not null) and is string type.
when add a read() before the error line,then there is no error. And in
another sub, I can output the same datareader content using a do while
read() function.
Can anyone give me a hint?
Nakhi
From Lijinag,China.
my code is very simple.
dim cm as oledbcommand= new oledbcommand("select * from page " ,cn)
cn.open()
Dim dr As OleDbDataReader = cm.ExecuteReader()
dim cate=dr.getstring(1) 'error line"
label1.text=cate
but there is error for dr.getstring(1), the error reads:the data of this
column does not exist:
I am sure the second line exist(not null) and is string type.
when add a read() before the error line,then there is no error. And in
another sub, I can output the same datareader content using a do while
read() function.
Can anyone give me a hint?
Nakhi
From Lijinag,China.