S
Scott M.
A DataReader has exactly 1 record in it at any one time and therefore does
not support a RecordCount like classic ADO did.
You could do this though...
Dim i as Integer
Dim ReaderValue as String
Do While objDataReader.Read()
i += 1
ReaderValue = "Municipio=" & objDataReader("Municipio") & "&vr=" &
objDataReader("vr")
Loop
'At this point, i is equal to the amount of records in the DataReader
'and ReaderValue is equal to the name/value pairs in the reader
On a side note, in ASP.NET, you really don't need "Response.Write()"
statements anymore (allthough they still work). Just set up a Web Form
Label control and set its text property:
lblData.Text = ReaderValue
Scott M.
not support a RecordCount like classic ADO did.
You could do this though...
Dim i as Integer
Dim ReaderValue as String
Do While objDataReader.Read()
i += 1
ReaderValue = "Municipio=" & objDataReader("Municipio") & "&vr=" &
objDataReader("vr")
Loop
'At this point, i is equal to the amount of records in the DataReader
'and ReaderValue is equal to the name/value pairs in the reader
On a side note, in ASP.NET, you really don't need "Response.Write()"
statements anymore (allthough they still work). Just set up a Web Form
Label control and set its text property:
lblData.Text = ReaderValue
Scott M.