Quantcast
Channel: OSIsoft Users Community
Viewing all articles
Browse latest Browse all 1120

Newbee : VBA Data.TimedValues

$
0
0

Hello guys,

 

I am new to OSI SDK, i would like to get time value from PI Point but I get error 'Type mismatch'.

 

Dim PI_SRV As PISDK.Server
Dim PI_POINT As PISDK.piPoint
Dim PI_POINT_VALUE As PISDK.PIValue
 Dim dt As New PITimeFormat
 
Dim MyDate As Date
 
MyDate = DateSerial(14, 12, 1) + TimeSerial(9, 46, 0)
dt.InputString = CStr(MyDate)
Set PI_SRV = PISDK.Servers("XXXXXXX")
Set PI_POINT = PI_SRV.PIPoints("ZZZZZ")
Set PI_POINT_VALUE = PI_POINT.Data.TimedValues(CDbl(MyDate))
 
Do you have any information guys !

Viewing all articles
Browse latest Browse all 1120

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>