How to populate excel ribbon dropDown with sheets names?

Ticom

New Member
This is my around way to populate a dropDown on an Excel's ribbon: \[code\]Workbook_Open:x = 5y = 12For Each ws In WorksheetsSheet1.Cells(x, y).Value = http://stackoverflow.com/questions/12650847/ws.Namex = x + 1Next wsEnd SubSub iCount(control As IRibbonControl, ByRef returnedVal)With Sheet1.Range("L5:L50")Set r1 = Range(.Cells(1), .Offset(.Rows.Count).End(xlUp))ItemCount = r1.Rows.CountreturnedVal = ItemCountEnd WithEnd SubSub listItem(control As IRibbonControl, index As Integer, ByRef returnedVal)returnedVal = r1.Cells(index + 1).ValueEnd Sub\[/code\]So, I firstly create a cell range from sheet names, and then fill the dropDown with the cell contents.
Could someone help about creating a list (or array, or collection...) from sheet names, to use directly as the dropDown items, without creating the cell range. And - is it possible to find somewhere complete ribbon (xml), of a standard excel 2010 file?
 
Back
Top