Defining data source for a combobox in PPT

K

Ken

OK... I'm confused.

I am trying to add a combox control to a ppt slide via the contols toolbar.

I am able to add the combobox. But now I want to populate the list.

I can't figure out how to do this. I know how to do this in excel (data
validation) and in Access (bind a data source table to the control). FOr
the life of me I can;t figure out how to do this simple thing in PPT combox
control.

Thanks!

KEn

I know how to do this in Access (bin
 
B

Brian Reilly, MVP

Ken,
Yes, that is perplexing in PPT, isn't it?
Let me skip the Access comparison and just focus on the XL solution
and then let you figure it out for yourself (vbg)

The XL solution relies on a range either defined by cells or a range
name. We ain't got nuthin' like that in PPT. So whatcha gonna do?

The simplest hardcoded method (don't ever tell anyone I know the word
"hardcoded") is to just write the list in the VBE e.g.

Private Sub ComboBox1_DropButtonClick()
With ComboBox1
..AddItem "One"
..AddItem "two"
End With
End Sub

If you want it not hardcoded, I think you'd have to grab the values
from a list in XL (or elsewhere) and loop thru the list and use
something like .additem strMyVariable.

There could be other ways like storing a list off the screen and
calling that list within a userform.

Not sure exactly what you are doing but I probably would call the XL
list from within PPT.

Brian Reilly, MVP
 
K

Ken

Thanks!

I suppose I should say that I am VBS-ignorant.

Is there a way that you are aware of of doing this "through the GUI" like in
XL or Access?

Ken
 
B

Brian Reilly, MVP

Ken,
No, must be through VBA.
Brian Reilly, MVP

Thanks!

I suppose I should say that I am VBS-ignorant.

Is there a way that you are aware of of doing this "through the GUI" like in
XL or Access?

Ken
 

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

Top