以文本方式查看主题 - Foxtable(狐表) (http://foxtable.net/bbs/index.asp) -- 专家坐堂 (http://foxtable.net/bbs/list.asp?boardid=2) ---- For Each MessageBox (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=97659) |
|
-- 作者:jncoser -- 发布时间:2017/3/16 12:17:00 -- For Each MessageBox Dim rs As List(of Row) = Tables("设置").GetCheckedRows() For Each r As Row In rs
Dim Result As DialogResult
Result = MessageBox.Show("1", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question)
If Result = DialogResult.Yes Then
r.Delete
End If Next 删一行一个提示,可以就全部一个提示吗?
|
|
-- 作者:yinyb36 -- 发布时间:2017/3/16 12:48:00 --
|
|
-- 作者:jiskin -- 发布时间:2017/3/16 12:52:00 -- 以下是引用jncoser在2017/3/16 12:17:00的发言:
Dim rs As List(of Row) = Tables("设置").GetCheckedRows()
For Each r As Row In rs
Dim Result As DialogResult
Result = MessageBox.Show("1", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question)
If Result = DialogResult.Yes Then
r.Delete
End If
Next
删一行一个提示,可以就全部一个提示吗?
Dim rs As List(of Row) = Tables("设置").GetCheckedRows()
if rs.count > 0 then
Dim Result As DialogResult = MessageBox.Show("1", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question)
If Result = DialogResult.Yes Then For Each r As Row In rs
r.Delete
Next
end if
end if
试试 不知道对不对
[此贴子已经被作者于2017/3/16 12:55:56编辑过]
|
|
-- 作者:有点色 -- 发布时间:2017/3/16 13:08:00 -- Dim rs As List(of Row) = Tables("设置").GetCheckedRows() Dim Result As DialogResult Result = MessageBox.Show("1", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question) If Result = DialogResult.Yes Then For Each r As Row In rs r.Delete Next End If |