发表于:2005-03-01 15:21:00
楼主
我在ifix中的一个画面要读取ifix数据库的值,有必要谢完整的过程么----我是指关于DataItem.Add操作?(我在其他的画面中有了相关的语句)比如:星号中的部分
'Create the Data System OCX
Dim FDS As Object
Dim Y as single
Set FDS = CreateObject("FixDataSystems.Intellution FD Data _
System Control")
FDS.Groups.Add ("DataGroup1")
'Add a group to the Groups collection
*************************************************************
FDS.Groups.Item("DataGroup1").DataItems.Add("Fix32.thisnode._
tag.f_cv") 'Add the item to the group
*************************************************************
FDS.Groups.Item("DataGroup1").Read
'Read all the items in the group
Y = FDS.Groups.Item("DataGroup1").DataItems.Item(1).Value
'Get the value which was cached in the read
FDS.Groups.Item("DataGroup1").DataItems.Item(1).Value = 3.0
'Change the cache
FDS.Groups.Item("DataGroup1").Write
'Write out all the caches in the group (only write those
'items which have changed)