H
Hru48
I have a macro which changes the value of a listbox entry and then
copies its values from one excel sheet to another to be totalled up
later. I need this to be run at least 50 times automatically as I am
currently just hitting run every time.
Maco is below and I would really be gratful for any thoughts on this.
Cheers
Hayley
Sub tesIncrement2()
Range("D108:R108").Select
Selection.Copy
Windows("test").Activate
Range("B1").Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone,
SkipBlanks:= _
False, Transpose:=False
Application.CutCopyMode = False
Selection.Insert Shift:=xlDown
Windows("North_central_agent.xls").Activate
ActiveWindow.ScrollWorkbookTabs Position:=xlLast
Sheets("Reference").Select
Windows("test").Activate
Range("A1").Select
Selection.Delete Shift:=xlUp
Selection.Copy
Windows("North_central_agent.xls").Activate
Range("H103").Select
ActiveSheet.Paste
ActiveWindow.ScrollWorkbookTabs Position:=xlFirst
Sheets("Summary").Select
Windows("test").Activate
Range("B1").Select
Application.CutCopyMode = False
Windows("North_central_agent.xls").Activate
End Sub
copies its values from one excel sheet to another to be totalled up
later. I need this to be run at least 50 times automatically as I am
currently just hitting run every time.
Maco is below and I would really be gratful for any thoughts on this.
Cheers
Hayley
Sub tesIncrement2()
Range("D108:R108").Select
Selection.Copy
Windows("test").Activate
Range("B1").Select
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone,
SkipBlanks:= _
False, Transpose:=False
Application.CutCopyMode = False
Selection.Insert Shift:=xlDown
Windows("North_central_agent.xls").Activate
ActiveWindow.ScrollWorkbookTabs Position:=xlLast
Sheets("Reference").Select
Windows("test").Activate
Range("A1").Select
Selection.Delete Shift:=xlUp
Selection.Copy
Windows("North_central_agent.xls").Activate
Range("H103").Select
ActiveSheet.Paste
ActiveWindow.ScrollWorkbookTabs Position:=xlFirst
Sheets("Summary").Select
Windows("test").Activate
Range("B1").Select
Application.CutCopyMode = False
Windows("North_central_agent.xls").Activate
End Sub