vba - Programatically assign a macro to a combobox in excel -


i've written macro obtain table combobox beside it. when user changes value of combobox value should populated in table cell

the macro i've written:

sub proc1()     cells(2, 1).value = "mat10"     cells(2, 2).value = "material id (mid)"     cells(2, 3).value = "bulk modulus(b)"     cells(2, 4).value = "average density (rho)"     cells(2, 5).value = "speed of sound (c)"     activesheet.listobjects.add(xlsrcrange, range("$a$2:$e$2"), , xlyes).name = "tab2"         'no go in 2003     activesheet.listobjects("tab2").tablestyle = "tablestylelight2"     range("b3:b3")     set comb = activesheet.dropdowns.add(.left, .top, .width, .height)      end     comb      .additem "75000000"      .additem "75000001"      .additem "75000002"      .additem "75000003"      .additem "75000004"     end end sub 

now when user changes value of combobox, new value should appear in table in column named "mat10". how can that?

i know can assign macro right clicking combobox want programmatically


Comments

Popular posts from this blog

java - Oracle EBS .ClassNotFoundException: oracle.apps.fnd.formsClient.FormsLauncher.class ERROR -

c# - how to use buttonedit in devexpress gridcontrol -

nvd3.js - angularjs-nvd3-directives setting color in legend as well as in chart elements -