M
mark.magill
Guys using the below code how do I obtain the results from the select
query?
//=======================================================
// Create new SQLDataSource
//=======================================================
SqlDataSource SQLDataSourceUsersDB = new SqlDataSource();
SQLDataSourceUsersDB.ConnectionString =
ConfigurationManager.ConnectionStrings["ConnectionString"].ToString();
//=======================================================
// Define SQLDataSource Command Types
//=======================================================
SQLDataSourceUsersDB.SelectCommandType =
SqlDataSourceCommandType.Text;
//=======================================================
// Create Insert and Select Commands
//=======================================================
SQLDataSourceUsersDB.SelectCommand = "SELECT * FROM Users
WHERE Email = @Email";
//=======================================================
// Define parameters for Insertion and Selection
//=======================================================
SQLDataSourceUsersDB.SelectParameters.Add("Email",
txtEmail.Text.ToString());
query?
//=======================================================
// Create new SQLDataSource
//=======================================================
SqlDataSource SQLDataSourceUsersDB = new SqlDataSource();
SQLDataSourceUsersDB.ConnectionString =
ConfigurationManager.ConnectionStrings["ConnectionString"].ToString();
//=======================================================
// Define SQLDataSource Command Types
//=======================================================
SQLDataSourceUsersDB.SelectCommandType =
SqlDataSourceCommandType.Text;
//=======================================================
// Create Insert and Select Commands
//=======================================================
SQLDataSourceUsersDB.SelectCommand = "SELECT * FROM Users
WHERE Email = @Email";
//=======================================================
// Define parameters for Insertion and Selection
//=======================================================
SQLDataSourceUsersDB.SelectParameters.Add("Email",
txtEmail.Text.ToString());