Thread: combo boxes
View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default combo boxes

Workbook_Open is a special procedure that executes when the workbook is
opened (unless the user disables macros or security settings disable
macros).

You can read about events he

http://www.cpearson.com/excel/events.htm
Chip Pearson's page on events. These events were introduced in xl97 and are
the preferred events. Prior to xl97, there were events such as Auto_Open,
Auto_Close and so forth. These are still supported. These older style
events go in regular or standard modules, while the newer events go in the
special modules ThisWorkbook (for workbook level events) or the related
Sheet module if sheet level events.

As for comboboxes, if you populate them with code (using additem as an
example), then the populated list lasts only as long as the workbook is
open. When closed, the items in the list are lost and must be repopulated.
This is why it was suggested you do this in the workbook_open or the older
equivalent Auto_open events.

--
Regards,
Tom Ogilvy

"sarah" wrote in message
...
hi,

I'm not sure I understand what you mean?? Sorry I haven't
used excel much!

What's the workbook's open event??

Thanks! :)
-----Original Message-----
The combobox has to know somehow that it has those list

items, so maybe
you could place the pice of code in the workbook's open

event, or
another way is to have the elements in a range and link

this range to
the combo-box

- Mangesh


---
Message posted from http://www.ExcelForum.com/

.