Hi ...
I'm using the sqldatasource control to retrieve data. I'd like to bind or dump that data into a datareader so that I can iterate through it and populate some labels on my form. I don't see anyway to do this programmatically ... is this possible?
I have the datasourcemode set to datareader but how do I access the datareader?
Here is my code:
Many Thanks,
- VB Rookie
I'm using the sqldatasource control to retrieve data. I'd like to bind or dump that data into a datareader so that I can iterate through it and populate some labels on my form. I don't see anyway to do this programmatically ... is this possible?
I have the datasourcemode set to datareader but how do I access the datareader?
Here is my code:
Code:
SqlDataSource1.SelectCommand = "usp_ccTransLog"
SqlDataSource1.SelectCommandType = SqlDataSourceCommandType.StoredProcedure
SqlDataSource1.SelectParameters.Add("ActionCode", "SEL")
SqlDataSource1.SelectParameters.Add("SelectCode", "5")
SqlDataSource1.SelectParameters.Add("TransactionID", Request.QueryString.Item("TransID"))
SqlDataSource1.DataSourceMode = SqlDataSourceMode.DataReader
SqlDataSource1.ConnectionString = DB.GetConn("TestConnect")
Many Thanks,
- VB Rookie