Dim file, rst2 as Object Dim i as Integer = 0 if Request.Form("delsignal") <> "" then for i = 0 to Request.Form.Count - 2 '---------------------------------------- rst2 = ExecSpf("exec AssignRow 'table,'id','" & Request.Form.Item(i) & "'")rst2 = Nothing file = Nothing deletex("table","id",Request.Form.Item(i)) '---------------------------------------- next end if AssignRow 是存储过程不用管,delsignal是将多选框塞在这里,最后的删除代码这样行吗? i = 0 to Request.Form.Count - 2 这句又是什么意思?
循环for i = 0 to Request.Form.Count - 2 //满足i在这个范围内,执行的代码 next
{
if(this.ListBox1.Items[i].Selected)
{
this.ListBox1.Items.RemoveAt(i);
}
}
for(int i=this.ListBox1.Items.Count-1;i>=0;i--)
{
if(this.ListBox1.Items[i].Selected)
{
this.ListBox1.Items.RemoveAt(i);
}
}
Dim i as Integer = 0
if Request.Form("delsignal") <> "" then
for i = 0 to Request.Form.Count - 2
'----------------------------------------
rst2 = ExecSpf("exec AssignRow 'table,'id','" & Request.Form.Item(i) & "'")rst2 = Nothing
file = Nothing
deletex("table","id",Request.Form.Item(i))
'----------------------------------------
next
end if
AssignRow 是存储过程不用管,delsignal是将多选框塞在这里,最后的删除代码这样行吗?
i = 0 to Request.Form.Count - 2 这句又是什么意思?
//满足i在这个范围内,执行的代码
next