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

Manipulating symbols that are in a composite

$
0
0

Hello,

 

I am relatively new to Processbook.  Have a code where if a pump is "RUNNING" the symbol is visible.  My problem is that the pump symbol is part of a composite and I cannot use a multistate because the tag returns a string value, not 0 or 1.  I tried using this code:

 

  Dim pump1 As Composite
  Set pump1 = ThisDisplay.Symbols("Composite13").GroupedSymbols("Graphic5")
  Dim varValue As Variant, varDate As Variant, varStatus As Variant
 
  varValue = Value24.GetValue(varDate, varStatus)
  If varValue = "RUNNING" Then
    pump1.Visible = True
  Else
    pump1.Visible = False
  End If

 

 

I keep getting an error saying that "pump1 = nothing" and I think it is because I can't use "GroupedSymbols" for some reason.  Is there something special I have to do to use that collection?

 

Thank you,

David


Viewing all articles
Browse latest Browse all 1120

Trending Articles