I've got a VB6 app that I've used for years to read data out of an Access databse and write it to PI. I decided that I would like to start setting the "Questionable" attribute on a subset of the data. I read the PI-SDK and it had a great example of how to do it (even in VB6) but I can't seem to get it to work. Here is the pertinent part of the code. Looping through the Access recordset:
Set oPiData = oPiPoint.Data 'ref the data oPiData.UpdateValue oRs!Value, varTimeStamp oRs.MoveNext
For j = 1 To oRs.RecordCount 'loop through the listbox
Set oNv = New NamedValues 'get ready to set "Q" attrib
Set oPiPoints = oServer.PIPoints 'all the server points
Set oPiPoint = oPiPoints.Item(oRs!TagName) 'get the one we need
oNv.Add "Questionable", True 'add
Set oPiData.RetrievalAttributes = oNv 'set the ref to the Q attrib
Set oPiData = oPiPoint.Data 'ref the data
oPiData.UpdateValue oRs!Value, varTimeStamp
I don't get any errors but Questionable never gets set.
Where have I gone a stray?????