Hymie
New Member
- Joined
- Aug 18, 2005
- Messages
- 8
G'day,
I have the following data in a spreadsheet:
I have created a user form which has 2 list boxes. The first shows the names Tom, Jack & Harry, and the second list box shows the cities conditional on which name has been selected. That is, if I select Jack in the first list box then the cities Perth and Darwin are shown in the second list box. So far, so good.
What I want to do now (and don't know how to) is click on a city and if it has "no" associated with it from Column C then I want to display a Message Box saying "No Way" or whatever I put in it, but if it has "yes" next to it then I just want the city selected and I will then move it to another list.
I guess what I am looking for is an understanding of how to use data in a row when one of the columns from a row contains an entry that is used as an item in a list box.
I hope this makes sense.
BTW, I have already read many forum entries relating to cascading list boxes etc, but I couldn't find anything that answered my question. However, if this question has already been answered I would like to apologise in advance and ask that you please just point me in the right direction for enlightenment.
Cheers, Hymie
I have the following data in a spreadsheet:
Book1 | |||||||
---|---|---|---|---|---|---|---|
A | B | C | D | E | |||
1 | Tom | Sydney | yes | ||||
2 | Tom | Melbourne | yes | ||||
3 | Tom | Adelaide | no | ||||
4 | Jack | Perth | yes | ||||
5 | Jack | Darwin | no | ||||
6 | Harry | Brisbane | yes | ||||
7 | Harry | Hobart | no | ||||
8 | Harry | Canberra | yes | ||||
9 | |||||||
10 | |||||||
Sheet1 |
I have created a user form which has 2 list boxes. The first shows the names Tom, Jack & Harry, and the second list box shows the cities conditional on which name has been selected. That is, if I select Jack in the first list box then the cities Perth and Darwin are shown in the second list box. So far, so good.
What I want to do now (and don't know how to) is click on a city and if it has "no" associated with it from Column C then I want to display a Message Box saying "No Way" or whatever I put in it, but if it has "yes" next to it then I just want the city selected and I will then move it to another list.
I guess what I am looking for is an understanding of how to use data in a row when one of the columns from a row contains an entry that is used as an item in a list box.
I hope this makes sense.
BTW, I have already read many forum entries relating to cascading list boxes etc, but I couldn't find anything that answered my question. However, if this question has already been answered I would like to apologise in advance and ask that you please just point me in the right direction for enlightenment.
Cheers, Hymie