Announcement

Collapse
No announcement yet.

Why do I have to reset the ePairStatusControl after creating a dropdown?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Why do I have to reset the ePairStatusControl after creating a dropdown?

    I'm working on a plugin and how come if I create a Status Pair as a dropdown (render = Enums.CAPIControlType.Single_Text_from_List), does it reset the ePairStatusControl to ePairStatusControl.Control instead of Both?

    I am trying to write a more general solution for adding devices for my plugin, and this kind of kills it because there is no way for me to tell if the status control was set correctly.

    Code:
    VSVGPairs.VSPair statusPair = new VSVGPairs.VSPair(ePairStatusControl.Both)
    {
           PairType = VSVGPairs.VSVGPairType.SingleValue,
           Value = activity.id,
           Status = activity.label,
           Render_Location = {
                  Row = 1,
                  Column = 1
           },
           Render = Enums.CAPIControlType.Single_Text_from_List,
           StringListAdd = activity.label,
           IncludeValues = true
    }
    The above results in statusPair.ControlStatus being 'Control" instead of Both. In order to fix it, I have to use DeviceVSP_ChangePair(reference, statusPair, ePairStatusControl.Both).

    #2
    I just ran into this exact issue creating a new plugin, definitely seems to be a bug...

    Comment

    Working...
    X