View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
GS[_2_] GS[_2_] is offline
external usenet poster
 
Posts: 3,514
Default Recurring Items in Spreadsheets

One way is to make a price list on a separate sheet. Give this list
(items only) a dynamic defined name of global scope so it auto-adjusts
when you add/remove items. Now you can add Data Validation dropdowns in
the item column. In the price column you can use a formula to lookup
the price of the selected item.

Another way is to use a combobox control on the worksheet. There are
examples of how to do this out there, but I haven't seen anything
reliable and without issues. A better approach is to use the
BeforeRightClick event to open a dialog with a combobox so you can
cycle through items by the 1st character. This means if there's 5 items
that begin with "A" then press the "a" key continuously until the item
you want appears, click "Insert" and it fills in the cells with item
and price. (IOW, no need for formulas) The dialog can be programmed to
advance to the next row if desired, so it remains open until you close
it but still allows you to edit the worksheet while the dialog hovers.

--
Garry

Free usenet access at http://www.eternal-september.org
Classic VB Users Regroup!
comp.lang.basic.visual.misc
microsoft.public.vb.general.discussion