ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Saving 500 sheets as .tpl extension, seperately! (https://www.excelbanter.com/excel-programming/408720-saving-500-sheets-tpl-extension-seperately.html)

Nick Smith[_2_]

Saving 500 sheets as .tpl extension, seperately!
 
Folks,

I need to generate 473 .tpl files with the same single line content. This
line is in cell A1 on a sheet labelled 'content'. The list of file names is
in a sheet labelled 'names' in column A.

I am using the following to generate the first 3 files for testing purposes
which saves them nicely as .xls. I just need them as .tpl files for my
website though!

Sub SaveAs()

For i = 1 To 3
Name = ThisWorkbook.Sheets("names").Range("A" & i)
ThisWorkbook.Sheets(Array("content")).Copy
ActiveWorkbook.SaveAs (Name)
ActiveWorkbook.Close
Next i
End Sub

Any help greatly appreciated.

Thanks,

Nick

Nick Smith[_2_]

Saving 500 sheets as .tpl extension, seperately!
 
Resolved.


"Nick Smith" wrote:

Folks,

I need to generate 473 .tpl files with the same single line content. This
line is in cell A1 on a sheet labelled 'content'. The list of file names is
in a sheet labelled 'names' in column A.

I am using the following to generate the first 3 files for testing purposes
which saves them nicely as .xls. I just need them as .tpl files for my
website though!

Sub SaveAs()

For i = 1 To 3
Name = ThisWorkbook.Sheets("names").Range("A" & i)
ThisWorkbook.Sheets(Array("content")).Copy
ActiveWorkbook.SaveAs (Name)
ActiveWorkbook.Close
Next i
End Sub

Any help greatly appreciated.

Thanks,

Nick


Air_Cooled_Nut[_2_]

Saving 500 sheets as .tpl extension, seperately!
 
Well, show us how you fixed it!
--

Toby Erkson
http://excel.icbm.org/


"Nick Smith" wrote:

Resolved.


"Nick Smith" wrote:

Folks,

I need to generate 473 .tpl files with the same single line content. This
line is in cell A1 on a sheet labelled 'content'. The list of file names is
in a sheet labelled 'names' in column A.

I am using the following to generate the first 3 files for testing purposes
which saves them nicely as .xls. I just need them as .tpl files for my
website though!

Sub SaveAs()

For i = 1 To 3
Name = ThisWorkbook.Sheets("names").Range("A" & i)
ThisWorkbook.Sheets(Array("content")).Copy
ActiveWorkbook.SaveAs (Name)
ActiveWorkbook.Close
Next i
End Sub

Any help greatly appreciated.

Thanks,

Nick



All times are GMT +1. The time now is 11:39 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com