Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Interaction between worksheets
The Combo is in the Summary Worksheet,
and the other sheets:DC,Time,Sheet3 should react when user clicks, clearly there is something missing in my code, thanks in advance Public Sub ComboBox1_Click() Call filt End Sub Public Sub filt() If Worksheets("Summary").ComboBox1.Value = "Qual" Then Worksheets("DC").Range("Letters").ShowAllData Worksheets("DC").Range("Letters").AutoFilter Field:=2, Criteria1:="Qual" Range("a3").EntireRow.Hidden = True Worksheets("Time").Range("A1:B50").Clear Worksheets("Sheet3").Range("a1:b17").Copy Destination:=Worksheets("Time").Range("a2") Else If Worksheets("Summary").ComboBox1.Value = "Quant" Then Worksheets("DC").Range("Letters").ShowAllData Worksheets("DC").Range("Letters").AutoFilter Field:=1, Criteria1:="Quant" Range("a3").EntireRow.Hidden = True Else If Worksheets("Summary").ComboBox1.Value = "Both" Then Worksheets("DC").Range("Letters").ShowAllData Range("a3").EntireRow.Hidden = True Worksheets("Time").Range("A1:B50").Clear Worksheets("Sheet3").Range("a1:b31").Copy Destination:=Worksheets("Time").Range("a2") End If End If End If End Sub |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Interaction between worksheets
Hi Teresa
What is the code supposed to do? What does it do?? If an error is generated, what is it and which line does it occur on??? Since you have not said what your If you can provide that info, then people have some chance of dealing with your "clearly" bit! regards Paul By the way, have you tried fully qualifying your range references? What sheet is Range("a3") on for example? teresa wrote in message ... The Combo is in the Summary Worksheet, and the other sheets:DC,Time,Sheet3 should react when user clicks, clearly there is something missing in my code, thanks in advance Public Sub ComboBox1_Click() Call filt End Sub Public Sub filt() If Worksheets("Summary").ComboBox1.Value = "Qual" Then Worksheets("DC").Range("Letters").ShowAllData Worksheets("DC").Range("Letters").AutoFilter Field:=2, Criteria1:="Qual" Range("a3").EntireRow.Hidden = True Worksheets("Time").Range("A1:B50").Clear Worksheets("Sheet3").Range("a1:b17").Copy Destination:=Worksheets("Time").Range("a2") Else If Worksheets("Summary").ComboBox1.Value = "Quant" Then Worksheets("DC").Range("Letters").ShowAllData Worksheets("DC").Range("Letters").AutoFilter Field:=1, Criteria1:="Quant" Range("a3").EntireRow.Hidden = True Else If Worksheets("Summary").ComboBox1.Value = "Both" Then Worksheets("DC").Range("Letters").ShowAllData Range("a3").EntireRow.Hidden = True Worksheets("Time").Range("A1:B50").Clear Worksheets("Sheet3").Range("a1:b31").Copy Destination:=Worksheets("Time").Range("a2") End If End If End If End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Curious interaction W/Win Exp. | Excel Discussion (Misc queries) | |||
ASP Excel interaction | Excel Discussion (Misc queries) | |||
... interaction with Word ... | Excel Discussion (Misc queries) | |||
Web interaction | Excel Programming | |||
excel/asp interaction - HELP! | Excel Programming |