禁止复制某列内容
假定希望禁止复制"单价"列的内容,可以在AfterSelRangeChange表事件中设置代码:
For
c As
Integer = e.NewRange.ColSel
To e.NewRange.ColEnd
If e.Table.Cols(c).name
= "单价"
Then
e.Table.DataTable.AllowClipBoard
= False
Return
End
If
Next
e.Table.DataTable.AllowClipBoard
= True