PDA

View Full Version : Solved: listbox



murto
08-20-2006, 06:02 PM
I wish to use a use list box as the reference to initiate a lookup. I have tried using the drop down menus provided in excel. Also I have no experience using macros but willing give it a go. Thank you for reading this and for any suggestions to solve this problem. The sample "DATAVALCOUNTRYCITY' nearly has what I am looking for. I have a recipe sheet that has a list of ingredients that can be changed to achieve the same results. I currently have four ingredients in my worksheet, two of which I use a time, the unused ingredients I put a zero value so that there is no input from them. I would like to select via a drop down list the ingredients I wish use to initiate the lookup function to retrieve the required information such as price, denisities and availabilities.

I sent this before I edited the spelling, so there may be another copy about, sorry.

Sincerely
Murdo Crombie

malik641
08-20-2006, 06:53 PM
Hey Murdo, and welcome to VBAX :hi:

Is there a way you could post a sample workbook? If your data is sensitive, then just post a dummy workbook of what you have and then what you want the outcome to be :thumb

Bob Phillips
08-21-2006, 02:02 AM
I wish to use a use list box as the reference to initiate a lookup. I have tried using the drop down menus provided in excel. Also I have no experience using macros but willing give it a go. Thank you for reading this and for any suggestions to solve this problem. The sample "DATAVALCOUNTRYCITY' nearly has what I am looking for. I have a recipe sheet that has a list of ingredients that can be changed to achieve the same results. I currently have four ingredients in my worksheet, two of which I use a time, the unused ingredients I put a zero value so that there is no input from them. I would like to select via a drop down list the ingredients I wish use to initiate the lookup function to retrieve the required information such as price, denisities and availabilities.

I sent this before I edited the spelling, so there may be another copy about, sorry.

Sincerely
Murdo Crombie

Sounds like Data Validation. See http://www.contextures.com/xlDataVal01.html

Zack Barresse
08-21-2006, 07:57 AM
Posted on Murdo's behalf:

I would like like to use two lines for grains but retain the use of the five grains. A list box containing the grains for each line i feel is the best way. I would like the list box to act as a reference cell in a lookup function to show relevant information.

Murdo Crombie

murto
08-26-2006, 04:10 AM
Thank you for your help. I was only able to use the information tonight. It is what I asked for and is of great help. When I went to use it, the lookup only seems to recognize the first three lines of the list of 5.


Many thanks for your help,

Yours sincerely

Murdo Crombie:beerchug:

26/August/2006

lucas
08-26-2006, 09:20 AM
Am I missing something here?

lucas
08-29-2006, 02:10 PM
Hi Murdo,
attached is a workbook with a sample of what your trying to accomplish(I think).....

Aussiebear
08-29-2006, 03:00 PM
Steve, in talking to Murdo, he indicated to me that he had some interest in a listbox so that not just a grain type could be selected but also the spec's that go with it.

Graintype, Dry matter, Protien, MJ/Ton, MJ/KG (Range B6:F9 in your sheet)

lucas
08-30-2006, 10:30 AM
Murdo & Ted,
FYI I started looking at this using a listbox but something has come up. My Mother who has been ill for a while has in the last 24 hours gotten much worse and we lost her in the early hours this morning.

Will gladly take another look at this for you but it will be a few days.

lucas
08-30-2006, 11:31 AM
Thought I should add what I have so far.....not sure if its what your really looking for but we can go from here. This one uses comboboxes.

This can be simplified to one combobox that shows all stats for a given grain(if they are static) and you can select it that way but I wasn't sure if you wished to make individual selections on the stats(thats how this one is set up). Remember its a work in progress so let us know.

Aussiebear
08-30-2006, 11:55 AM
Sorry to hear that Steve. Take as long as you like. There's no need to get back to it, until you are feeling up to it.

murto
08-31-2006, 01:46 AM
Steve,
My condolences, I received your post tonight and lookat it in the near future. This is a personal project that I am using to stimulate the brain, so no rush to find a solution.

Yours Sincerly

Murdo Crombie

murto
09-11-2006, 03:15 AM
Steve
I have been thinking about your combobox to pull information initiated by using a list box, it is what I am after. In an attempt to clarify the spreadsheet the 1st cell will contain the ingredient, 2nd cell will either be an input by myself or a solver run as a percentage of the total ration, some cells will use the second cell with ingredient specific information,(for example the total amount MeJ will be worked out as a (% *1000kg *MeJ/Kg (from spec. sheet))). There are up to 15 columns of specific information per ingredient to be worked with.

My orginal idea was to use an extended array in the lookup function to pull the necessary information. There can be in excess of 50 ingredients to choose from. Their use is determined by season availablity or price, hence the the use of the dropdown list box.

No need to rush I am just forwarding my thoughts on the matter.

Many thanks for your assistance, my thoughts are with you.

Murdo

Aussiebear
09-12-2006, 02:44 AM
Murdo, Please post your workbook. The initial post of yours is confusing and not very well constructed. Could you also more clearly define just exactly what you are chasing?

Ted

murto
09-18-2006, 12:56 AM
Ted,
Thank you for your interest. With better planning I was able to simpify the worksheet and acheive good results. My orginal idea would have proved cumbersome.
Regards
Murdo