#1   Report Post  
Marlis
 
Posts: n/a
Default pivot table?

I have set up an invoice template. I want to save each invoice in two
seperate workbooks without having to hit "save as". I want one to go into a
folder where I can track payments with the invoice number, and the other to
save using name. How can I do this?


  #2   Report Post  
Excel_Geek
 
Posts: n/a
Default


Try this macro:

I've attached the Excel file I used to write this for your benefit,
too.

Sub Save_Twice_Under_Different_Names()
'
'************************************************* *********
'****************** Code by Excel_Geek ********************
'************************************************* *********
'
' This macro saves the active workbook twice in two different
locations
' with two different names -- the first name being the invoice number,
' and the second being the customer name.

' The "K:\" part of this line should be the complete directory string
' for the location you want to save the file with the Invoice Number
name.
' Range("INVOICE") refers to the cell with the invoice number in it,
which
' I've named "INVOICE".
ActiveWorkbook.SaveAs Filename:="K:\" & Range("INVOICE").Value &
".xls"

' The "K:\" part of this line should be the complete directory string
' for the location you want to save the file with the Customer Name
name.
' Range("INVOICE") refers to the cell with the customer name in it,
which
' I've named "CUSTOMERNAME".
ActiveWorkbook.SaveAs Filename:="K:\" & Range("CUSTOMERNAME").Value &
".xls"

End Sub


+-------------------------------------------------------------------+
|Filename: For_Marlis.zip |
|Download: http://www.excelforum.com/attachment.php?postid=3706 |
+-------------------------------------------------------------------+

--
Excel_Geek


------------------------------------------------------------------------
Excel_Geek's Profile: http://www.excelforum.com/member.php...o&userid=26423
View this thread: http://www.excelforum.com/showthread...hreadid=396977

  #3   Report Post  
Dave Peterson
 
Posts: n/a
Default

Maybe you could use a macro.

Take a look at savecopyas in vba's help.



Marlis wrote:

I have set up an invoice template. I want to save each invoice in two
seperate workbooks without having to hit "save as". I want one to go into a
folder where I can track payments with the invoice number, and the other to
save using name. How can I do this?


--

Dave Peterson
  #4   Report Post  
Marlis
 
Posts: n/a
Default

I know I said workbook. I'm sorry, but I meant seperate sheets within the
same workbook. Right now my worbook has 2 sheets. Order form (the invoice),
and customers. I have a dropdown list on the order form for the customers.
I would like to create two more sheets within the same workbook. One to
track using the invvoice numbers, and the the other to track using the
customers name. Any help woud be appreciated.

Thank you


"Excel_Geek" wrote:


Try this macro:

I've attached the Excel file I used to write this for your benefit,
too.

Sub Save_Twice_Under_Different_Names()
'
'************************************************* *********
'****************** Code by Excel_Geek ********************
'************************************************* *********
'
' This macro saves the active workbook twice in two different
locations
' with two different names -- the first name being the invoice number,
' and the second being the customer name.

' The "K:\" part of this line should be the complete directory string
' for the location you want to save the file with the Invoice Number
name.
' Range("INVOICE") refers to the cell with the invoice number in it,
which
' I've named "INVOICE".
ActiveWorkbook.SaveAs Filename:="K:\" & Range("INVOICE").Value &
".xls"

' The "K:\" part of this line should be the complete directory string
' for the location you want to save the file with the Customer Name
name.
' Range("INVOICE") refers to the cell with the customer name in it,
which
' I've named "CUSTOMERNAME".
ActiveWorkbook.SaveAs Filename:="K:\" & Range("CUSTOMERNAME").Value &
".xls"

End Sub


+-------------------------------------------------------------------+
|Filename: For_Marlis.zip |
|Download: http://www.excelforum.com/attachment.php?postid=3706 |
+-------------------------------------------------------------------+

--
Excel_Geek


------------------------------------------------------------------------
Excel_Geek's Profile: http://www.excelforum.com/member.php...o&userid=26423
View this thread: http://www.excelforum.com/showthread...hreadid=396977


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
updating pivot table to include additional rows Ellen Excel Discussion (Misc queries) 8 July 15th 08 01:33 PM
Change Data In Pivot Table John Calder New Users to Excel 1 July 7th 05 10:41 PM
Pivot Table - Multiple consolidation Range tengreen Excel Worksheet Functions 1 July 1st 05 07:18 PM
Pivot table, dynamic data formula Excel GuRu Excel Discussion (Misc queries) 3 May 3rd 05 10:45 PM
Pivot Table Problems Rachel Gonsior Excel Discussion (Misc queries) 3 March 21st 05 07:24 PM


All times are GMT +1. The time now is 09:49 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"