Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Sheets("sheet1").Copy
Sheets("sheet1").Copy
This line of code copies the sheet1 to a new workbook useing the default template. Is there a way to put into the code and tell excel which template to use. I want to avoid changing everyone default template. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Sheets("sheet1").Copy
What do you mean by default template??? That line of code copies the sheet
with tab name "sheet1" from the active workbook to a new workbook. -- HTH... Jim Thomlinson "Little Penny" wrote: Sheets("sheet1").Copy This line of code copies the sheet1 to a new workbook useing the default template. Is there a way to put into the code and tell excel which template to use. I want to avoid changing everyone default template. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Sheets("sheet1").Copy
I don't understand.
This'll copy that sheet1 to a new workbook--there's no template involved (no workbook template and no worksheet template). Little Penny wrote: Sheets("sheet1").Copy This line of code copies the sheet1 to a new workbook useing the default template. Is there a way to put into the code and tell excel which template to use. I want to avoid changing everyone default template. -- Dave Peterson |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Sheets("sheet1").Copy
Are you thinking of Word where there is a Normal.dot file. XL has nothing
similar... -- HTH... Jim Thomlinson "Jim Thomlinson" wrote: What do you mean by default template??? That line of code copies the sheet with tab name "sheet1" from the active workbook to a new workbook. -- HTH... Jim Thomlinson "Little Penny" wrote: Sheets("sheet1").Copy This line of code copies the sheet1 to a new workbook useing the default template. Is there a way to put into the code and tell excel which template to use. I want to avoid changing everyone default template. |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Sheets("sheet1").Copy
I ceated a excel tempalte the include serveral macro.
I want to be able use Sheets("sheet1").Copy But have excel use the template to open the new workbook On Mon, 17 Sep 2007 13:45:50 -0500, Dave Peterson wrote: I don't understand. This'll copy that sheet1 to a new workbook--there's no template involved (no workbook template and no worksheet template). Little Penny wrote: Sheets("sheet1").Copy This line of code copies the sheet1 to a new workbook useing the default template. Is there a way to put into the code and tell excel which template to use. I want to avoid changing everyone default template. |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Sheets("sheet1").Copy
Create a new workbook that uses that template.
Copy the worksheet into that workbook. Dim NewWkbk As Workbook Dim WksToCopy As Worksheet Set WksToCopy = ActiveWorkbook.Worksheets("Sheet1") Set NewWkbk = Workbooks.Add(template:="C:\folder\yourtemplatenam e.xlt") WksToCopy.Copy _ befo=NewWkbk.Worksheets(1) Little Penny wrote: I ceated a excel tempalte the include serveral macro. I want to be able use Sheets("sheet1").Copy But have excel use the template to open the new workbook On Mon, 17 Sep 2007 13:45:50 -0500, Dave Peterson wrote: I don't understand. This'll copy that sheet1 to a new workbook--there's no template involved (no workbook template and no worksheet template). Little Penny wrote: Sheets("sheet1").Copy This line of code copies the sheet1 to a new workbook useing the default template. Is there a way to put into the code and tell excel which template to use. I want to avoid changing everyone default template. -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Sheets("Sheet1").Cells.ClearContents | Excel Discussion (Misc queries) | |||
Sheets("Sheet1").Move After:=Sheets(2) | Excel Programming | |||
use variable in Workbooks("book1").Worksheets("sheet1").Range("a1" | Excel Programming | |||
Sheets("sheet1").Range command between workbooks | Excel Programming | |||
Sheet1 object not Worksheets("Sheet1") | Excel Programming |