Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private sub populateList( items as List(of UserChoices))
- dim choices as UserChoices
- dim defaultChoice as UserChoices
- for each choice in items
- cboList.items.add(choice)
- '-- you could do user specific check or base it on some other
- '---- setting to find the default choice here
- if choice.state = _user.State or choice.state = _settings.defaultState then
- defaultChoice = choice
- end if
- next
- '-- you chould select the first one
- if cboList.items.count > 0 then
- cboList.SelectedItem = cboList.item(0)
- end if
- '-- continuation of hte default choice
- cboList.SelectedItem = defaultChoice
- end sub
Add Comment
Please, Sign In to add comment