Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can buttons be indexed in Excel?

Status
Not open for further replies.

MrMajik

IS-IT--Management
Apr 2, 2002
267
On my spreadsheet I have 50 buttons I created. The only thing unique to the procedure for each button is the active cell it points to. I know VisualBasic 6 allows you to make an array of objects and identify each object with an index value. Can something like this be done with Excel so I don't have to code the same thing 50 times?

Thank you,

MrMajik

There are 10 types of people in the world:
Those that understand binary and those that don't.
 
Have a look here:
faq707-4085

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
PHV,

Thank you for the extremely fast reply :)

The link you provided is for controls in a UserForm. My buttons are on a spreadsheet. Is a controlled array of indexed items possible for objects on a spreadsheet?

Thank you,

MrMajik

There are 10 types of people in the world:
Those that understand binary and those that don't.
 
Activex (MSForms) buttons are more or less the same as on userform. If you use buttons from the 'Forms' toolbar (excel buttons, you assign a macro to it) use Application.Caller to identify button's name. See thread707-1378314 for an example.

combo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top