Forum Discussion

Sergey's avatar
Sergey
Contributor III
3 years ago
Solved

List all CustomSubstVars from current dashboard ?

Dear Community, There is a possiblity to retrieve parameters currently available in a dashboard using for instance :      Dim str_myParam As String = args.SelectionChangedTaskInfo.CustomSubs...
  • JackLacava's avatar
    3 years ago

    CustomSubstVars is a VB.Net Dictionary, so you can play around with its keys.

    For Each key As String In args.SelectionChangedTaskInfo.CustomSubstVarsWithUserSelectedValues.Keys
        brapi.ErrorLog.LogMessage(si, $"{key} is present")
    Next
    
    Dim isPresent as Boolean = 
    args.SelectionChangedTaskInfo.CustomSubstVarsWithUserSelectedValues.Contains("myKey")
    
    ' ... etc etc