There are no errors, but I see no data being stored in the database on a form submit.
Code to insert a row is as follows:
Code: Select all
public int run_sql(string msg)
{
SqlConnection conn = new SqlConnection();
SqlCommand cmd = new SqlCommand();
SqlDataAdapter da = new SqlDataAdapter();
DataSet ds = new DataSet();
conn.ConnectionString = connString;
cmd = conn.CreateCommand();
cmd.CommandText = msg;
conn.Open();
cmd.ExecuteNonQuery();
conn.Close();
return 1;
}
[/code]