这就是我想要做的.我正在使用autoback创建一个动态检查,点击后,将转到我的子程序并执行某些操作.我试图传递的两个参数是checkox所在的表和复选框id的名称.但是我收到了错误
AddressOf必须是没有括号或方法的方法的名称
方法没有与sender作为对象兼容的签名,e system.eventArgs".这是我的代码如下.
chkSel = New CheckBox
chkSel.ID = "check_" & CStr(a)
chkSel.AutoPostBack = True
'This is where I get the error
AddHandler chkSel.CheckedChanged, AddressOf change_operating_items(tableName, "check_" & CStr(a))
tblcell.Controls.Add(chkSel)
tblrow.Cells.Add(tblcell)
Run Code Online (Sandbox Code Playgroud) vb.net ×1