public void DeleteId(string MemberId)
{
string strSql = "delete Member where MemberId in ( ' " + MemberId + " ') ";
DbHelperSQL.ExecuteSql(strSql);
}
public static int ExecuteSql(string SQLString)
{
using (SqlConnection connection = new SqlConnection(connectionString))
{
using (SqlCommand cmd = new SqlCommand(SQLString, connection))
{
try
{
connection.Open();
int rows = cmd.ExecuteNonQuery();
return rows;
}
catch (System.Data.SqlClient.SqlException E)
{
connection.Close();
throw new Exception(E.Message);
}
}
}
}