English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I need to search for a cell based on two attributes. Column A contains titles of types of material and row 1 contains titles of size of material. Based on the type and size a weight is inputed. On a seperate worksheet, I need to be able to select a type (in a drop down box) and a size (again in a drop down box) and have excel tell me the weight based on the info entered. Can excel search the column based on the title then the row based on the title and pinpoint the correct cell? I appreciate any help.

2007-05-21 14:36:14 · 2 answers · asked by wiegs187 1 in Computers & Internet Programming & Design

2 answers

See this Excel worksheet without VBA code. It was created only with Excel basic functions and form drop downs.

http://www1.webng.com/nbittencourt/test/titles.xls


Nelson Bittencourt
See my web site:
http://www1.webng.com/nbittencourt/index_e.htm

2007-05-21 16:43:00 · answer #1 · answered by nbittencourt 3 · 0 0

Yes by using Visual Basic for Applications VBA, the built in scripting language. VBA is very similar to the older VB6.0.
Code may be written which responds to events like a worksheet opening or a button being clicked.

When a worksheet is activated an event is fired which can load tow list boxes with items from the top row and first column. The user can select an item from each list box and click a button placed onto the worksheet. The button click event is fired and code is executes which will get the index values of the selected items in the row and column list boxes. Using these values it is a simple matter to use the Cells.(rowIndex,colIndex) methos to extract the value in the lookup table and select a cell on another worksheet to write the value to.

2007-05-21 22:38:23 · answer #2 · answered by MarkG 7 · 0 0

fedest.com, questions and answers