How to fetch the digital tags associated state name in programming VB.NET
myOpening = OSIsoft.AF.PI.PIStateSets(myOpening)
returns i ?
Thanks and appreciate
First of all, you appear to have a circular reference with how you have used myOpening. Secondly, the call to PIStateSets should be in context of an PIServer object. See Live Library Hlelp for PIStateSets. Note that an item from the StateSets is an AFEnumerationSet, that is there is no PIStateSet object, though if it helps you to think of it as such, you can name your variables accordingly. Likewise an AFEnumerationSet contains AFEnumerationValues (or to be accurate, it contains 1 or more).
There is a code example for AFEnumerationValues that you may find useful.
Retrieving data ...