Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have created a drop down list using the data validation tool in
excel. When i chose one of the options from the drop down list, i have another drop down list that contains different values dependent of my choices in the first drop down list. My problem is that when i go back to the first drop down list an change the value there, the default value in the second drop down list don`t change. And i have to open the second drop down list to get access to the new values. Is there a way to get the second drop down list to change the defalult whenever the first drop down list i changed. I would be really thankfull for some help one this one. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
It sounds like you need to create Dependent Lists....
See Debra Dalgleish's website for instructions: http://www.contextures.com/xlDataVal02.html Is that something you can work with? *********** Regards, Ron XL2002, WinXP "Blaatann" wrote: I have created a drop down list using the data validation tool in excel. When i chose one of the options from the drop down list, i have another drop down list that contains different values dependent of my choices in the first drop down list. My problem is that when i go back to the first drop down list an change the value there, the default value in the second drop down list don`t change. And i have to open the second drop down list to get access to the new values. Is there a way to get the second drop down list to change the defalult whenever the first drop down list i changed. I would be really thankfull for some help one this one. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks for the reply but that´s unfortunately not the solution for my
problem. If you check out the sample file from the link you gave me, you will see my problem. If i choose fruit from the sample file:this list will appear: Apples Oranges Lemons Grapes And i can choose from the 4 different fruits. Lets say i choose Lemons. The value in the second drop down list will be Lemons. But if i go back and choose vegetables the value in the second drop down list will still be Lemons. My problem is that when i choose vegetables in the first drop down list. I want the default value in the second drop down list to change to the first value from the vegetable list. In this example Cabbage. I hope you could help me with this. Regards Blaatann |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Ahh..you're looking to change one DV cell and have another DV cell's value
automatically clear. Here's some sample worksheet-level code that you can amend to suit your needs: Assumptions: Parent List cells are in A1:A10 Dependent List cells are in B1:B10 '---------Start of Code-------- Private Sub Worksheet_Change(ByVal Target As Range) Dim rngAllParentCells As Range Dim rngDepCells As Range Dim rngCell As Range Set rngAllParentCells = Range("A1:A10") Set rngDepCells = Intersect(Target, rngAllParentCells) If Not rngDepCells Is Nothing Then For Each rngCell In rngDepCells.Cells 'Move 1 cell to the right and clear contents rngCell.Offset(RowOffset:=0, ColumnOffset:=1).ClearContents Next rngCell End If Set rngAllParentCells = Nothing Set rngDepCells = Nothing Set rngCell = Nothing End Sub '---------End of Code-------- Is that something you can work with? *********** Regards, Ron XL2002, WinXP "Blaatann" wrote: Thanks for the reply but that4s unfortunately not the solution for my problem. If you check out the sample file from the link you gave me, you will see my problem. If i choose fruit from the sample file:this list will appear: Apples Oranges Lemons Grapes And i can choose from the 4 different fruits. Lets say i choose Lemons. The value in the second drop down list will be Lemons. But if i go back and choose vegetables the value in the second drop down list will still be Lemons. My problem is that when i choose vegetables in the first drop down list. I want the default value in the second drop down list to change to the first value from the vegetable list. In this example Cabbage. I hope you could help me with this. Regards Blaatann |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I did`t get this to work. I`m a newbe in programming, you can download
the document from this link: http://tfweb.hit.no/2006/EK5_1_06/Do...ekksmenyer.xls If i choose "Klappluke" in A11 i want C11 to be "Ikke valgt" if i then go back and choose one of the other options in A11 i want C11 to be "Ingen". I hope you can help me. Regards Blaatann |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
drop down list based on other drop down list pick | Excel Discussion (Misc queries) | |||
Drop Down List choice selecting another drop down list | Excel Worksheet Functions | |||
How to Create a macro from drop down list (Validation List) in excel | Excel Programming | |||
My Excel drop-down list eliminates from list options chosen. Help | Excel Programming | |||
multiple select from the drop down list in excel. list in one sheet and drop down in | Excel Discussion (Misc queries) |