Skip to main content

Populate List Box based on Existing Values

Comments

5 comments

  • Permanently deleted user

    This is what I make it work.

    (1) Declare a variable with the type "IList<Object>" (say you call as 'listSelected'

    (2)  On the Runtime Modification Sequence, Assign 'listSelected' with the variable your Ouput Arguments of the ListBox (if you configured it as ' listBoxSelectedItem ' which should be with the type 'Object'

    (3) Use Assign Activity (Cast<T>): listSelected = listBoxSelectedItem

    (4) Use Assign Activity (Cast<T>):  form.Find(Of ListBoxFormItem)("ListBox1").SelectedValues = listSelected 

     

    0
  • Ryan Kelley

    Munwhan,

    Thanks for the reply. I am stuck now on #2 of your steps. I can't assign the object var (output of the ListBox) to the Casted iList<Object> variable in the RunTime mod. It won't let me. I am unsure why I am assigning a var to an output that doesn't exist yet??

    Do you have any examples or have time to create a SUPER simple one, just so I can see what the var's are and their types?

    thanks,

    Ryan

    0
  • Ryan Kelley

    Actually, I think I see what you are saying with #2. But #3 and #4... Is this a Cast or an Assign? I am a bit confused by what you are describing. I can't Cast those and the Assign doesn't make a difference.

    thanks again,

    Ryan

    0
  • Ryan Kelley

    Got it. Thanks for your insight Munwhan... it definitely pointed me in the right direction. I think I got stuck too because I was trying to highlight a record that was coming from the value from a coded value domain.

    Ryan

    0
  • Permanently deleted user
    Ryan,

     

    I know this thread is almost 3 years old, but I am trying to do exactly what you were asking here. I can't get it to work, but it looks like you did.

     

    If you have it available, would you be willing to post a snippet of the workflow, so I can see where I'm going wrong?

     

    Thanks,

     

    Mike
    0

Please sign in to leave a comment.