
无法将类型“string”隐式转换为“bool”
protectedvoidgv_RowDataBound(objectsender,GridViewRowEventArgse){if(e.Row.RowType==Da...
protected void gv_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
((LinkButton)e.Row.Cells[6].Controls[0]).Attributes["onclick"] = "if(!confim('确定要审核该信息吗?'))return false;";
}
e.Row.Cells[5].Text.Trim().ToString() = "0"?"未审核":"已审核";
}
protected void gv_SelectedIndexChanged(object sender, EventArgs e)
{
string _id = gv.SelectedRow.Cells[0].Text.ToString();
string sql = "update ...";
}
这里那里错了啊? 展开
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
((LinkButton)e.Row.Cells[6].Controls[0]).Attributes["onclick"] = "if(!confim('确定要审核该信息吗?'))return false;";
}
e.Row.Cells[5].Text.Trim().ToString() = "0"?"未审核":"已审核";
}
protected void gv_SelectedIndexChanged(object sender, EventArgs e)
{
string _id = gv.SelectedRow.Cells[0].Text.ToString();
string sql = "update ...";
}
这里那里错了啊? 展开
1个回答
展开全部
string居然能这样转bool??我还真是第一次听说
如果是string a = "aab3bc12c" 请问机器要转成true 还是false?????
转的话都是因为string a = "true"; 然后你判断if (a == “true”) bool b = true;
.......
如果是string a = "aab3bc12c" 请问机器要转成true 还是false?????
转的话都是因为string a = "true"; 然后你判断if (a == “true”) bool b = true;
.......
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询