Hi guys,
I am trying to record a macro that will go thru a drop down list, copy the first line, paste into a different spread sheet and repeat until the list has been gone thru. Everything seems to work fine when recording - I go thru the drop down list, copy and paste special values and number formats and repeat. However, when I play the macro the only information that comes up in all of the rows is the same data that I have left on my screen that I copied from.![]()
Last edited by Vaibhav; 03-21-2012 at 07:06 AM.
It will be good if you attach the sample workbook & code that you have been working on, so we can troubleshoot better.
Cheers,
Arlette
If I helped, Don't forget to add to my reputation (click on the star below the post)
Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
Use code tags when posting your VBA code: [code] Your code here [/code]
Here is a spread sheet that uses the same type of information that i am working with. My problem is that when I go thru the drop down the macro doesnt seem to like this and will not feed the correct information from the Weekly totals tab to the Totals tab at the end.
This is the macro i have tried to run by coping only the first line of information from each drop down, week 11/4, and pasting to the totals page for the seperate individuals.
Keyboard Shortcut: Ctrl+p
'
Sheets("Weekly totals").Select
ActiveCell.Offset(3, -2).Range("A1:F1").Select
Selection.Copy
Sheets("Totals").Select
ActiveCell.Offset(0, 1).Range("A1").Select
Selection.PasteSpecial Paste:=xlPasteValuesAndNumberFormats, Operation:= _
xlNone, SkipBlanks:=False, Transpose:=False
Sheets("Weekly totals").Select
Application.CutCopyMode = False
ActiveCell.Range("A1:F1").Select
Selection.Copy
Sheets("Totals").Select
ActiveCell.Offset(1, 0).Range("A1").Select
Selection.PasteSpecial Paste:=xlPasteValuesAndNumberFormats, Operation:= _
xlNone, SkipBlanks:=False, Transpose:=False
Sheets("Weekly totals").Select
Application.CutCopyMode = False
ActiveCell.Range("A1:F1").Select
Selection.Copy
Sheets("Totals").Select
ActiveCell.Offset(1, 0).Range("A1").Select
Selection.PasteSpecial Paste:=xlPasteValuesAndNumberFormats, Operation:= _
xlNone, SkipBlanks:=False, Transpose:=False
Application.CutCopyMode = False
Sheets("Weekly totals").Select
End Sub
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks