N
news.microsoft.com
I get an error on the variable @ObjectName. Can anyone suggest what is
wrong?
_name = _lvi.Text;
_type = "T";
_sql = "INSERT INTO QueryBuilderTableViews(ObjectName,ObjectType) VALUES " +
" (@ObjectName, @ObjectType)";
cmd.CommandText = _sql;
cmd.Parameters.AddWithValue("@ObjectName", _name); //
error on this line.
cmd.Parameters.AddWithValue("@ObjectType", _type);
cmd.ExecuteNonQuery();
Thanks
Bill
wrong?
_name = _lvi.Text;
_type = "T";
_sql = "INSERT INTO QueryBuilderTableViews(ObjectName,ObjectType) VALUES " +
" (@ObjectName, @ObjectType)";
cmd.CommandText = _sql;
cmd.Parameters.AddWithValue("@ObjectName", _name); //
error on this line.
cmd.Parameters.AddWithValue("@ObjectType", _type);
cmd.ExecuteNonQuery();
Thanks
Bill