Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Code Modification
ComboBox5.RowSource = "OFFSET(" & Worksheets(8).Name & "!
Y4,,,COUNTA(" & Worksheets(8).Name & "!Y:Y))" The above code populates Combobox5 with values from a specific column starting with cell 4. Currently Combobox5 is being populated with data from Column Y starting in Row4. However the column it pulls data from will not always be Column Y, so I need for this code to be dynamic. I will need Combobox5 to reference a cell(cell W4) that contains the actual column to populate data from. The starting cell will still be and always be 4. For example lets say the value in cell W4 is AL. This means the combobox needs to populate data from this Column. How do I do this? Thank you Todd Huttenstine |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Code Modification
ComboBox5.RowSource = "OFFSET(" & Worksheets(8).Name & "!" _
& Range("W4").Value & ",,,COUNTA(" & Worksheets(8).Name & "!" _ & Range("W4").Value & ":" & Range("W4").Value & "))" -- Regards, Tom Ogilvy "Todd Huttenstine" wrote in message ... ComboBox5.RowSource = "OFFSET(" & Worksheets(8).Name & "! Y4,,,COUNTA(" & Worksheets(8).Name & "!Y:Y))" The above code populates Combobox5 with values from a specific column starting with cell 4. Currently Combobox5 is being populated with data from Column Y starting in Row4. However the column it pulls data from will not always be Column Y, so I need for this code to be dynamic. I will need Combobox5 to reference a cell(cell W4) that contains the actual column to populate data from. The starting cell will still be and always be 4. For example lets say the value in cell W4 is AL. This means the combobox needs to populate data from this Column. How do I do this? Thank you Todd Huttenstine |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
modification to this code | Excel Discussion (Misc queries) | |||
Code modification help | Excel Worksheet Functions | |||
Help in Modification of existing code | Excel Programming | |||
Sort Code Modification | Excel Programming | |||
Modification to code | Excel Programming |