Determining a combo box by code

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a pivot table that can move the location of a combo box depending on
how many rows it returns. Is there any way to determine which cell the combo
box is in.
Something like:
For x = to beginRange to EndRange
if range("C:6") is Combo then ....

Thanks
 
It might be easier to look at the combobox and find out where it is.

If the combobox is from the control toolbox toolbar:
msgbox worksheets("sheet2").oleobjects("combobox1").topleftcell.address

If the combobox (AKA DropDown) is from the Forms toolbar:
msgbox worksheets("sheet2").dropdowns("drop down 1").topleftcell.address
 
Thanks Dave,

My problem is that this combo box is on a pivot table. I'm not sure if I can
refer to the pivot table cell and get the cell address. There are a bunch of
comb boxes (which are dimension filters) to choose from.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top