c# 必须声明标量变量@ 可是已经声明了啊

sinat_24853299 sinat_24853299 墨衍会员 · AI 创作全网分发 墨衍智能分发 通过墨衍一键同步至各平台 可同步平台 CSDN微信公众号微博知乎掘金百家号博客园抖音小红书 你的文章也可以这样分发 墨衍会员 ¥399起/年,写一次发全网 我也要 + 加入社区
string sql = "insert into commodity values(@photo,@number, @name,@ pwd, @mail,@sex,@call, @college,@major)";
SqlCommand com = new SqlCommand(sql1, DBhelper.con);
// com.Parameters.Add("@photo", SqlDbType.Image).Value =file ;
com.Parameters.AddWithValue("@photo", file);
com.Parameters.AddWithValue("@number", number);
com.Parameters.AddWithValue("@name", name);
com.Parameters.AddWithValue("@pwd", pwd);
com.Parameters.AddWithValue("@mail", mail);
com.Parameters.AddWithValue("@sex", sex);
com.Parameters.AddWithValue("@call", call);
com.Parameters.AddWithValue("@college", college);
com.Parameters.AddWithValue("@major", major);
...全文
评论 7
收藏 已收藏
分享
返回顶部
sinat_24853299
C# 111,128 成员 642,537 内容