Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
welcome.
I have a template file test.xlt existing in some dir other than excel templates dir. When the file is launched new workbook is created and i want to autosave it in a dir where the test.xlt file exists. Due to fact that instance of the file test.xlt does not longer exists i cant get source dir. I would be thankful for any hint. PS. i have used a tip that every single file launched makes its mark in a windows recent directory, so i found a link file (test.xlt.lnk) but a dont know how to retrieve target dir from it. Maybe this way ? |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Post the code. This is real easy to fix. You just need some minor
modification to your code. "Przemek" wrote: welcome. I have a template file test.xlt existing in some dir other than excel templates dir. When the file is launched new workbook is created and i want to autosave it in a dir where the test.xlt file exists. Due to fact that instance of the file test.xlt does not longer exists i cant get source dir. I would be thankful for any hint. PS. i have used a tip that every single file launched makes its mark in a windows recent directory, so i found a link file (test.xlt.lnk) but a dont know how to retrieve target dir from it. Maybe this way ? |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Post the code. This is real easy to fix. You just need some minor modification to your code. Just tell me where to use and what methode/property. I've tested the problem with empty test.xlt file with no code. |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I don't have enough info to give good reults. Give more details.
"Przemek" wrote: Post the code. This is real easy to fix. You just need some minor modification to your code. Just tell me where to use and what methode/property. I've tested the problem with empty test.xlt file with no code. |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() I don't have enough info to give good reults. Give more details. the template file test.xlt HAS NO CODE, i cant give U more details bcoz there are no details. after launching XLT file it creates a copy of itself named "test1.xls". Thats how template files works. Unfortunately this copy of xlt file isnt saved, and i need to save it into a directory where the source file "xlt" exists. But the problem is "how to obtain the source dir". PS. Just create an EMPTY *.xlt file. Close Excel. And double click on the created file. U will se what i'm talkin ab. |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Create a new workbook with a macro that copies the XLT file and saves it.
"Przemek" wrote: I don't have enough info to give good reults. Give more details. the template file test.xlt HAS NO CODE, i cant give U more details bcoz there are no details. after launching XLT file it creates a copy of itself named "test1.xls". Thats how template files works. Unfortunately this copy of xlt file isnt saved, and i need to save it into a directory where the source file "xlt" exists. But the problem is "how to obtain the source dir". PS. Just create an EMPTY *.xlt file. Close Excel. And double click on the created file. U will se what i'm talkin ab. |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Excel doesn't keep track of where the original template was located.
If you're creating the file based on that template in code, you could keep track of it yourself. If you're creating the file based on that template manually, you'll have to find another way--maybe add a name (and hide it) to the template file that specifies the path???? Przemek wrote: welcome. I have a template file test.xlt existing in some dir other than excel templates dir. When the file is launched new workbook is created and i want to autosave it in a dir where the test.xlt file exists. Due to fact that instance of the file test.xlt does not longer exists i cant get source dir. I would be thankful for any hint. PS. i have used a tip that every single file launched makes its mark in a windows recent directory, so i found a link file (test.xlt.lnk) but a dont know how to retrieve target dir from it. Maybe this way ? -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Link a Master Template Excel file to different excel source files | Excel Worksheet Functions | |||
If I accidently replace a saved file can I retrieve the old file? | Excel Discussion (Misc queries) | |||
Connect a Template with the data source. | Excel Programming | |||
How do I retrieve Chart Source (range) and PlotBy | Excel Programming | |||
Need template source path | Excel Programming |