首先,我没有多少编程的基础,所以问题问的不够高明,还忘各位见谅。
Range("B2").Value = CStr(ItemValues(1))
Range("C2").Value = Hex(Qualities(1))
Range("D2").Value = CStr(TimeStamps(1))
上面的付值要使在VB中是付给一个TEXT吗?
Private Sub worksheet_change(ByVal Selection As Range)
'----------- Only if cell "B3" changes, write this value
If Selection <> Range("B3") Then Exit Sub
Values(1) = Selection.Cells.Value
'----------- Write the new value in synchronous mode
MyOPCGroup.SyncWrite 1, ServerHandles, Values, Errors
End Sub
上面是用worksheet_change来监视EXCEL中是否值发生变化,在VB中怎么实现监视值的变化。
谢谢各位,给点提示。