[求助]删除问题!
选中ListView中的行,右击并在数据库中删除此行,求教高手怎么写Private Sub 删除ToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles 删除ToolStripMenuItem.Click
conn.Open()
Dim cmd As New SqlCommand("delete from tablename where ??? ", conn)
cmd.ExecuteNonQuery()
conn.Close()
MsgBox("此项会从表中删除!", MsgBoxStyle.Information, "操作提示")
End Sub
不写WHERE删的是整个表,怎么写ListView的指针标识?或者其他方法?
[此贴子已经被作者于2006-6-2 10:16:27编辑过]