Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Saving a file(new) using the multiple cell contents as a file name
I think ijb meant:
ActiveWorkbook.SaveAs Filename:="C:\" & Sheet1.Cells(1, 1) _ & "_" & Sheet1.Cells(1, 2) (if the codename for the worksheet is named sheet1.) or ActiveWorkbook.SaveAs Filename:="C:\" & worksheets("sheet1").Cells(1, 1) _ & "_" & worksheets("sheet1").Cells(1, 2) if the name were sheet1 (yeah, they could match up!). ijb wrote: ActiveWorkbook.SaveAs Filename:="C:\" & Sheet1!Cells(1, 1) & "_" & Sheet1!Cells(1, 2) Should do the trick If I've mis-understood the question please tell me. -- HTH ijb Remove nospam from my e-mail address to talk direct Not MCSD, MVP, TLA, P&P, PCMCIA, etc just trying to help "Paul" wrote in message ... I want to save a file(under a new name)using the cell content of multiple cells as a new file name. For example, I stored the department number, 21-01, in a cell and the period number, 1, in another cell. I want to create the macro to save this worksheet after updating all datas under file name "21-01_1.xls" Can I do this? Please help! Thanks, Paul -- Dave Peterson |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Saving a file(new) using the multiple cell contents as a file name
Yep, you're right, sorry for the typos :-)
-- If I've mis-understood the question please tell me. HTH ijb Remove nospam from my e-mail address to talk direct Not MCSD, MVP, TLA, P&P, PCMCIA, etc just trying to help "Dave Peterson" wrote in message ... I think ijb meant: ActiveWorkbook.SaveAs Filename:="C:\" & Sheet1.Cells(1, 1) _ & "_" & Sheet1.Cells(1, 2) (if the codename for the worksheet is named sheet1.) or ActiveWorkbook.SaveAs Filename:="C:\" & worksheets("sheet1").Cells(1, 1) _ & "_" & worksheets("sheet1").Cells(1, 2) if the name were sheet1 (yeah, they could match up!). ijb wrote: ActiveWorkbook.SaveAs Filename:="C:\" & Sheet1!Cells(1, 1) & "_" & Sheet1!Cells(1, 2) Should do the trick If I've mis-understood the question please tell me. -- HTH ijb Remove nospam from my e-mail address to talk direct Not MCSD, MVP, TLA, P&P, PCMCIA, etc just trying to help "Paul" wrote in message ... I want to save a file(under a new name)using the cell content of multiple cells as a new file name. For example, I stored the department number, 21-01, in a cell and the period number, 1, in another cell. I want to create the macro to save this worksheet after updating all datas under file name "21-01_1.xls" Can I do this? Please help! Thanks, Paul -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
2007 Macro to Open File, Delete Contents, Save New File | Excel Discussion (Misc queries) | |||
Saving Excel 2007 file in 2003 creates very large file | Excel Discussion (Misc queries) | |||
Saving to a file multiple times | Excel Discussion (Misc queries) | |||
Saving worksheet in new file with date AND cell value as file name | Excel Discussion (Misc queries) | |||
How do I stop Excel 2000 from saving file history from file that . | Excel Discussion (Misc queries) |