efarmer9538
New Member
- Joined
- Sep 13, 2014
- Messages
- 3
I am trying to move a worksheet from one workbook and save it to another. I keep getting an automation error and every change I make to that line I keep getting error messages of different kinds. I am so close to having this speadsheet the way I need it to be but this is stopping me.
Private Sub CommandButton1_Click()
Dim OrgWs As Worksheet
Dim NewWs As Worksheet
Set OrgWs = ActiveSheet
OrgWs.copy After:=Worksheets(Worksheets.Count)
Set NewWs = ActiveSheet
NewWs.Name = Format(Date, ("ddmmmyy"))
OrgWs.Move After:=Workbooks("Normand Flower POB 2014 09.xlsm").Worksheets(Worksheets.Count)
OrgWs.Name = Format(Date - 1, ("ddmmmyy"))
Windows("NF POB SEP 2014.xlsm").Activate
End Sub
Is there anyway I can make this sheet go to the workbook without having it open?
Thanks!
Private Sub CommandButton1_Click()
Dim OrgWs As Worksheet
Dim NewWs As Worksheet
Set OrgWs = ActiveSheet
OrgWs.copy After:=Worksheets(Worksheets.Count)
Set NewWs = ActiveSheet
NewWs.Name = Format(Date, ("ddmmmyy"))
OrgWs.Move After:=Workbooks("Normand Flower POB 2014 09.xlsm").Worksheets(Worksheets.Count)
OrgWs.Name = Format(Date - 1, ("ddmmmyy"))
Windows("NF POB SEP 2014.xlsm").Activate
End Sub
Is there anyway I can make this sheet go to the workbook without having it open?
Thanks!