ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   linking list box (https://www.excelbanter.com/excel-programming/328003-linking-list-box.html)

Jamesmor

linking list box
 
Here's what I need to do...I have some list boxes created, and I have them
linked together.

However, I need the item in list box 2 to change based on what list box 1 is.

For Example

In list box 1 I have 3 entries of inventory id's being "a","b", and "c"

In list box 2 I have 3 entries of what I have on hand being "1", "2", and "3"

now lets say that I have "3" of a

when I click list box 1 and set it to "a" I want list box 2 to automatically
select "3"

is there a way to do this with excel?

Thanks

Jamesmor

Bob Phillips[_6_]

linking list box
 
Of course. What sort of listbox?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Jamesmor" wrote in message
...
Here's what I need to do...I have some list boxes created, and I have them
linked together.

However, I need the item in list box 2 to change based on what list box 1

is.

For Example

In list box 1 I have 3 entries of inventory id's being "a","b", and "c"

In list box 2 I have 3 entries of what I have on hand being "1", "2", and

"3"

now lets say that I have "3" of a

when I click list box 1 and set it to "a" I want list box 2 to

automatically
select "3"

is there a way to do this with excel?

Thanks

Jamesmor




Jamesmor

linking list box
 
I'm just using the ones created by "data"- "validation"

"Bob Phillips" wrote:

Of course. What sort of listbox?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Jamesmor" wrote in message
...
Here's what I need to do...I have some list boxes created, and I have them
linked together.

However, I need the item in list box 2 to change based on what list box 1

is.

For Example

In list box 1 I have 3 entries of inventory id's being "a","b", and "c"

In list box 2 I have 3 entries of what I have on hand being "1", "2", and

"3"

now lets say that I have "3" of a

when I click list box 1 and set it to "a" I want list box 2 to

automatically
select "3"

is there a way to do this with excel?

Thanks

Jamesmor





Mykal

linking list box
 
I am just a regular user of excel, but have done something similar before
with combo boxes and the HLOOKUP function

for the first combo box, I had the ListFillRange listed in F5:F7 (example -
mine was a little more complicated), with the LINKEDCELL in G5
As the user Picked the appropriate option in the combo box, the value in G5
changes to the desired value
Lets say the three choices are
Option 1
Option 2
Option 3

I had the second combo box ListFill Range listed in H5:H7
I had a small table listed further J5:L8 over in the spreadsheet that had in
each column
Option 1 Option 2 Option 3
Bob Jane Mary
Mark Doug Deanna
Heather Katie Mike

In the cells H5 I had
=HLOOKUP(TRIM($G$5),$J$5:$L$8,2,FALSE)
in H6 I had
=HLOOKUP(TRIM($G$5),$J$5:$L$8,3,FALSE)
in H7 I had
=HLOOKUP(TRIM($G$5),$J$5:$L$8,4,FALSE)

The way it works is the first combo picks which column will populate the
data in H5:H7
The Horizontal Lookup fills the data
The data is then available for the second combo box

Like I said - I am just a average user, there are probably bette ways of
doing this





"Jamesmor" wrote:

I'm just using the ones created by "data"- "validation"

"Bob Phillips" wrote:

Of course. What sort of listbox?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Jamesmor" wrote in message
...
Here's what I need to do...I have some list boxes created, and I have them
linked together.

However, I need the item in list box 2 to change based on what list box 1

is.

For Example

In list box 1 I have 3 entries of inventory id's being "a","b", and "c"

In list box 2 I have 3 entries of what I have on hand being "1", "2", and

"3"

now lets say that I have "3" of a

when I click list box 1 and set it to "a" I want list box 2 to

automatically
select "3"

is there a way to do this with excel?

Thanks

Jamesmor





Jamesmor

linking list box
 
This has helped out a bunch, however, I'm still running into a problem, the
values for my list box are in another spreadsheet and it looks as if this
only works with everything being on a single sheet (I could be mistaken). Is
this the case?

"Mykal" wrote:

I am just a regular user of excel, but have done something similar before
with combo boxes and the HLOOKUP function

for the first combo box, I had the ListFillRange listed in F5:F7 (example -
mine was a little more complicated), with the LINKEDCELL in G5
As the user Picked the appropriate option in the combo box, the value in G5
changes to the desired value
Lets say the three choices are
Option 1
Option 2
Option 3

I had the second combo box ListFill Range listed in H5:H7
I had a small table listed further J5:L8 over in the spreadsheet that had in
each column
Option 1 Option 2 Option 3
Bob Jane Mary
Mark Doug Deanna
Heather Katie Mike

In the cells H5 I had
=HLOOKUP(TRIM($G$5),$J$5:$L$8,2,FALSE)
in H6 I had
=HLOOKUP(TRIM($G$5),$J$5:$L$8,3,FALSE)
in H7 I had
=HLOOKUP(TRIM($G$5),$J$5:$L$8,4,FALSE)

The way it works is the first combo picks which column will populate the
data in H5:H7
The Horizontal Lookup fills the data
The data is then available for the second combo box

Like I said - I am just a average user, there are probably bette ways of
doing this





"Jamesmor" wrote:

I'm just using the ones created by "data"- "validation"

"Bob Phillips" wrote:

Of course. What sort of listbox?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Jamesmor" wrote in message
...
Here's what I need to do...I have some list boxes created, and I have them
linked together.

However, I need the item in list box 2 to change based on what list box 1
is.

For Example

In list box 1 I have 3 entries of inventory id's being "a","b", and "c"

In list box 2 I have 3 entries of what I have on hand being "1", "2", and
"3"

now lets say that I have "3" of a

when I click list box 1 and set it to "a" I want list box 2 to
automatically
select "3"

is there a way to do this with excel?

Thanks

Jamesmor




Jamesmor

linking list box
 
Never Mind, I got it working, had to use Vlookup instead but it works fine.
Thanks!

"Mykal" wrote:

I am just a regular user of excel, but have done something similar before
with combo boxes and the HLOOKUP function

for the first combo box, I had the ListFillRange listed in F5:F7 (example -
mine was a little more complicated), with the LINKEDCELL in G5
As the user Picked the appropriate option in the combo box, the value in G5
changes to the desired value
Lets say the three choices are
Option 1
Option 2
Option 3

I had the second combo box ListFill Range listed in H5:H7
I had a small table listed further J5:L8 over in the spreadsheet that had in
each column
Option 1 Option 2 Option 3
Bob Jane Mary
Mark Doug Deanna
Heather Katie Mike

In the cells H5 I had
=HLOOKUP(TRIM($G$5),$J$5:$L$8,2,FALSE)
in H6 I had
=HLOOKUP(TRIM($G$5),$J$5:$L$8,3,FALSE)
in H7 I had
=HLOOKUP(TRIM($G$5),$J$5:$L$8,4,FALSE)

The way it works is the first combo picks which column will populate the
data in H5:H7
The Horizontal Lookup fills the data
The data is then available for the second combo box

Like I said - I am just a average user, there are probably bette ways of
doing this





"Jamesmor" wrote:

I'm just using the ones created by "data"- "validation"

"Bob Phillips" wrote:

Of course. What sort of listbox?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Jamesmor" wrote in message
...
Here's what I need to do...I have some list boxes created, and I have them
linked together.

However, I need the item in list box 2 to change based on what list box 1
is.

For Example

In list box 1 I have 3 entries of inventory id's being "a","b", and "c"

In list box 2 I have 3 entries of what I have on hand being "1", "2", and
"3"

now lets say that I have "3" of a

when I click list box 1 and set it to "a" I want list box 2 to
automatically
select "3"

is there a way to do this with excel?

Thanks

Jamesmor





All times are GMT +1. The time now is 11:39 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com