Hi all

(no clue how too)

I have a master file called Nursery.xls. It is an invoice program. On the invoice at the bottom is a button "Process To Journal" this macro works well and the info is copied to the Sheet called "Sales Journal" in the same work book.

What i am try to do with the following code is save a copy of the invoice to a separate folder called "Finished Invoices" With the information from cell B8 this is the name of the company and cell F17 which is the invoice number.

[VBA]
'on process to journal save a file as customer name and invoice number
Dim FName As Variant

FName = Sheets("Sales").Range("B8").Text & Sheets("Sales").Range("F17").Text & ".xls"
If FName <> False Then
If FName <> ActiveWorkbook.Name Then
On Error GoTo Error_SaveAs
ActiveWorkbook.SaveAs Filename:=FName
Else
ActiveWorkbook.Save
End If
End If
Exit Sub

Error_SaveAs:
MsgBox "error executing SaveAs with filename = " & FName & vbCrLf & _
"no save done", vbCritical
[/VBA]

If i run this it renames my the Nursery.xls file which is my master document, and saves the document with the correct file name in MY DOCUMENTS.

What i would like is for it to just put a copy one sheet called "sales" into the "Finished Invoices" folder and save Nursery.xls with the new info that it has in the Sales Journal.

It must not copy all the sheets in the workbook only "Sales"

Nursery.xls contains 4 Worksheets called

Sales/Sales Journal/Customers/Database


The purpose of the Nursery.xls file is to create the invoice, process the info to the "Sales Journal" so i can keep track of who has been invoiced.

I hope i explained well enough

Kindest regards

Darren
South Africa