initialization - Initializing userform vba -



initialization - Initializing userform vba -

i have 2 userforms (userform1 , userform9) same code initialize. first 1 starts fine sec doesn't apply values combobox.

'userform1 private sub userform_initialize()

dim cloc range dim ws worksheet sheets("member").select set ws = worksheets("s_all") each cloc in ws.range("a3:a39") me.cbplan .additem cloc.value end next cloc cbgenero.additem "man" cbgenero.additem "woman" end sub

'userform9

private sub userform_initialize() dim rinst range dim sizei integer dim ws worksheet sheets("class").select sizei = sheets("h_capt").range("o:41") set ws = worksheets("h_capt") cbsal.additem "1" cbsal.additem "2" cbsal.additem "3" each rinst in ws.range(cells(42, 14), cells(sizei, 14)) me.cbinstruct .additem rinst.value end next rinst end sub

when phone call userform9 keeps marking error on module calls it

public sub capt_asist() userform9.show end sub

i can prepare if alter private sub userform_initialize() private sub userform9_initialize(), of comboboxes show data

vba initialization userform

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' -