Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello -
I have a document that should be distributed as a template document on individual machines which will go on C:\Documents and Settings\Administrator\Application Data\Microsoft\Templates\DocumentName.xlt. I don't want to have to manually put it on each machine. Is there a textbook example of how to do this in code? I could email them a document that has a button on it that will save the template when they click it, but then each time an instance of a template is loaded, the button will be there again. I know I am not thinking this through correctly, but it's getting late . . . Any help will be greatly appreciated! -- Sandy |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() you can make a Install file and copy DocumentName.xlt to Excel Templates path try, SourceFile = Application.TemplatesPath & "\DocumentName.xlt" DestinationFile = ThisWorkbook.Path & "\DocumentName.xlt" FileCopy SourceFile, DestinationFile -- 天行健,君*以自強不息 地勢坤,君*以厚德載物 http://www.vba.com.tw/plog/ "Sandy" wrote: Hello - I have a document that should be distributed as a template document on individual machines which will go on C:\Documents and Settings\Administrator\Application Data\Microsoft\Templates\DocumentName.xlt. I don't want to have to manually put it on each machine. Is there a textbook example of how to do this in code? I could email them a document that has a button on it that will save the template when they click it, but then each time an instance of a template is loaded, the button will be there again. I know I am not thinking this through correctly, but it's getting late . . . Any help will be greatly appreciated! -- Sandy |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Chijanzen:
Thanks for your response. What do you mean by "make an install file"? Can you be more specific? Thanks. -- Sandy "chijanzen" wrote: you can make a Install file and copy DocumentName.xlt to Excel Templates path try, SourceFile = Application.TemplatesPath & "\DocumentName.xlt" DestinationFile = ThisWorkbook.Path & "\DocumentName.xlt" FileCopy SourceFile, DestinationFile -- 天行健,君*以自強不息 地勢坤,君*以厚德載物 http://www.vba.com.tw/plog/ "Sandy" wrote: Hello - I have a document that should be distributed as a template document on individual machines which will go on C:\Documents and Settings\Administrator\Application Data\Microsoft\Templates\DocumentName.xlt. I don't want to have to manually put it on each machine. Is there a textbook example of how to do this in code? I could email them a document that has a button on it that will save the template when they click it, but then each time an instance of a template is loaded, the button will be there again. I know I am not thinking this through correctly, but it's getting late . . . Any help will be greatly appreciated! -- Sandy |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sandy,
If everyone is on the same network, you can ensure that their Office setting "Workgroup Templates" points to a common location, then these template will appear (along with local templates) when the select New.. Whilst Excel does not expose this setting (for some reason) other Office components do. So you can automate Word or make the necessary registry changes directly. NickHK "Sandy" wrote in message ... Hello - I have a document that should be distributed as a template document on individual machines which will go on C:\Documents and Settings\Administrator\Application Data\Microsoft\Templates\DocumentName.xlt. I don't want to have to manually put it on each machine. Is there a textbook example of how to do this in code? I could email them a document that has a button on it that will save the template when they click it, but then each time an instance of a template is loaded, the button will be there again. I know I am not thinking this through correctly, but it's getting late . . . Any help will be greatly appreciated! -- Sandy |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Nick -
Thanks for responding! That would still entail setting a path on each machine, wouldn't it? -- Sandy "NickHK" wrote: Sandy, If everyone is on the same network, you can ensure that their Office setting "Workgroup Templates" points to a common location, then these template will appear (along with local templates) when the select New.. Whilst Excel does not expose this setting (for some reason) other Office components do. So you can automate Word or make the necessary registry changes directly. NickHK "Sandy" wrote in message ... Hello - I have a document that should be distributed as a template document on individual machines which will go on C:\Documents and Settings\Administrator\Application Data\Microsoft\Templates\DocumentName.xlt. I don't want to have to manually put it on each machine. Is there a textbook example of how to do this in code? I could email them a document that has a button on it that will save the template when they click it, but then each time an instance of a template is loaded, the button will be there again. I know I am not thinking this through correctly, but it's getting late . . . Any help will be greatly appreciated! -- Sandy |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sandy,
Yes, but it's a one-off change. Whatever method you choose, you have to contact/edit/change something at least once. If you edit the registry: HKEY_CURRENT_USER\Software\Microsoft\Office\9.0\Co mmon\General\SharedTemplat es no user interaction is required. Then any update to the template just means you have to replace it at one location. NickHK "Sandy" wrote in message ... Hi Nick - Thanks for responding! That would still entail setting a path on each machine, wouldn't it? -- Sandy "NickHK" wrote: Sandy, If everyone is on the same network, you can ensure that their Office setting "Workgroup Templates" points to a common location, then these template will appear (along with local templates) when the select New.. Whilst Excel does not expose this setting (for some reason) other Office components do. So you can automate Word or make the necessary registry changes directly. NickHK "Sandy" wrote in message ... Hello - I have a document that should be distributed as a template document on individual machines which will go on C:\Documents and Settings\Administrator\Application Data\Microsoft\Templates\DocumentName.xlt. I don't want to have to manually put it on each machine. Is there a textbook example of how to do this in code? I could email them a document that has a button on it that will save the template when they click it, but then each time an instance of a template is loaded, the button will be there again. I know I am not thinking this through correctly, but it's getting late . . . Any help will be greatly appreciated! -- Sandy |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
how can i see all column sizes at once not individually? | Excel Discussion (Misc queries) | |||
How do I print comments individually? | Excel Worksheet Functions | |||
Reference & update destin. cells on 1st machine from source workbook on 2nd machine. | Excel Discussion (Misc queries) | |||
Listing consecutive days without inputting each one individually | Charts and Charting in Excel | |||
Sorting each row individually | Excel Programming |