ms access - EASY: vba: Looking through a listbox and selecting the contents -



ms access - EASY: vba: Looking through a listbox and selecting the contents -

i know simple , it's slipping mine right now. how loop though listbox , select contents?

here's code i've made right now:

dim allgrps integer dim integer allgrps = lstallgroups.listcount = 1 allgrps lstallgroups next

keep in mind listbox zero-indexed you've got subtract 1 off i:

for = 1 allgrps lstallgroups.selected(i - 1) = true next

also, create sure you've got selectsheetslist.multiselect = fmmultiselectmulti in order able select multiple items in list.

see the listbox documentation more info.

vba ms-access access-vba

Comments

Popular posts from this blog

formatting - SAS SQL Datepart function returning odd values -

c++ - Apple Mach-O Linker Error(Duplicate Symbols For Architecture armv7) -

php - Yii 2: Unable to find a class into the extension 'yii2-admin' -