Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Open Workbooks Return
How do I programmically return the currently open workbooks so as to load a
ComboBox? -- Trent Argante [DC.J(192)] |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Open Workbooks Return
Here is how to get the workbooks...
Sub ListBooks() Dim wbk As Workbook For Each wbk In Workbooks MsgBox wbk.Name Next wbk End Sub Load the combo box where the message box currently lives. This will only look at one instance of Excel. If the user were to open two copies of Excel you would only get the workbooks from this one instance. Dealing with two instances of Excel is distinctly difficult. HTH "Trent Argante" wrote: How do I programmically return the currently open workbooks so as to load a ComboBox? -- Trent Argante [DC.J(192)] |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Open Workbooks Return
Jim,
Thanks a bunch! I totally had my thinking cap off. Thanks for rattling the brain for me. Trent "Jim Thomlinson" wrote: Here is how to get the workbooks... Sub ListBooks() Dim wbk As Workbook For Each wbk In Workbooks MsgBox wbk.Name Next wbk End Sub Load the combo box where the message box currently lives. This will only look at one instance of Excel. If the user were to open two copies of Excel you would only get the workbooks from this one instance. Dealing with two instances of Excel is distinctly difficult. HTH "Trent Argante" wrote: How do I programmically return the currently open workbooks so as to load a ComboBox? -- Trent Argante [DC.J(192)] |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Open Workbooks Return
Don't feel bad. My brain rattles at the best of times... Just ask my wife. :)
Glad to help... "Trent Argante" wrote: Jim, Thanks a bunch! I totally had my thinking cap off. Thanks for rattling the brain for me. Trent "Jim Thomlinson" wrote: Here is how to get the workbooks... Sub ListBooks() Dim wbk As Workbook For Each wbk In Workbooks MsgBox wbk.Name Next wbk End Sub Load the combo box where the message box currently lives. This will only look at one instance of Excel. If the user were to open two copies of Excel you would only get the workbooks from this one instance. Dealing with two instances of Excel is distinctly difficult. HTH "Trent Argante" wrote: How do I programmically return the currently open workbooks so as to load a ComboBox? -- Trent Argante [DC.J(192)] |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Open Dialog Box to return Selected File Path and Not Open it. | Excel Programming | |||
When I open Excel, workbooks open automatically. How can I stop t | Excel Discussion (Misc queries) | |||
Excel 2003 Workbooks.Open with CorruptLoad=xlRepairFile fails on Excel 5.0/95 file due to Chart, with Error 1004 Method 'Open' of object 'Workbooks' failed | Excel Programming | |||
Workbooks.Open closes other workbooks | Excel Programming | |||
Workbooks.Open / .Open Text - How do you stop the .xls addition? | Excel Programming |