playing around with the IPIData2 interface I came to a ugly inconsistency in the SDK.
The NamedValue-Class has a property called Name and Value as it's in its natural.
But the Value-Property is a kind of list, what is surprising because his name is not "Values".
Second is, that this list has no Count property, so I can examine the amount of data only
with "Trial an Error". This ist also with NamedValues2 interface.Is there anything I missunderstood?
Hope I'am not to annoying with my questions.
Const STARTTIME As String = "26-jul-2011 10:00" Const ENDTIME6H As String = "26-jul-2011 16:00" Dim oIPIData2 As PISDK.IPIData2 Dim oNamedValues As PISDKCommon.NamedValues Dim oNamedValue As PISDKCommon.NamedValue Dim lngIndex As Long Dim strMsg As String Set oIPIData2 = Servers.DefaultServer.PIPoints("sinusoid").Data Set oNamedValues = oIPIData2.Summaries2(STARTTIME, ENDTIME6H, 3600, asAll, cbTimeWeighted) For Each oNamedValue In oNamedValues 'Missing a oNamedValue.Value(s).count property to iterate through the Value(s) strMsg = strMsg & "Name: " & oNamedValue.Name strMsg = strMsg & " - " strMsg = strMsg & "Value: " & oNamedValue(1).Value strMsg = strMsg & vbCrLf Next MsgBox strMsg