I'm trying to loop through all values in a dropdown list, the source for which is in sheet "Comm O & S", range A31:L31.
I want to copy values from another sheet that result from the selection in the dropdown and paste these values in a column in a separate sheet (starting at column C). Then, I want to select the next value in the dropdown and copy-paste the values in the next column over, etc.
I am having trouble with the copy-paste within the dropdown loop.
Sheets("Scenario by Payer").Activate
For Each rngCell In wb.Worksheets("Comm O & S").Range("A31:L31")
' Set the value of dd_comm
ws.Range("D14").Value = rngCell.Value
Sheets("Detailed Outputs").Select
Range("T52:t60").Select
Application.CutCopyMode = False
Selection.Copy
Sheets("Comm O & S").Activate
For Each c In ActiveSheet.Range("C7:L7").Cells
c.Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Next rngCell
Next c