Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have the following Macro that is a Journal Entry, when I run the macro it
opens a template and copies information from the active workbook to the template, what I need is to run in base of the current active workbook and not "2004 JE Worksheets NEW.xls").Activate, because this forces me to name the file always the same way. Let me know if i did not make myself clear Workbooks.Add Template:= _ "C:\Documents and Settings\mestrell.000\Application Data\Microsoft\Templates\JE BPCS upload.xlt" Windows("2004 JE Worksheets NEW.xls").Activate |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Are you looking for something like this?
Dim wSource as Workbook Set wSource = ActiveWorkbook Workbooks.Add Template:= _ "C:\Documents and Settings\mestrell.000\ApplicationData\Microsoft\Te mplates\JE BPCS upload.xlt" wSouce.Activate 'carry on from here Robin Hammond www.enhanceddatasystems.com "MESTRELLA29" wrote in message ... I have the following Macro that is a Journal Entry, when I run the macro it opens a template and copies information from the active workbook to the template, what I need is to run in base of the current active workbook and not "2004 JE Worksheets NEW.xls").Activate, because this forces me to name the file always the same way. Let me know if i did not make myself clear Workbooks.Add Template:= _ "C:\Documents and Settings\mestrell.000\Application Data\Microsoft\Templates\JE BPCS upload.xlt" Windows("2004 JE Worksheets NEW.xls").Activate |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
YES !!!!!!
That is IT.... THANKS FOR ALL YOUR HELP... "Robin Hammond" wrote: Are you looking for something like this? Dim wSource as Workbook Set wSource = ActiveWorkbook Workbooks.Add Template:= _ "C:\Documents and Settings\mestrell.000\ApplicationData\Microsoft\Te mplates\JE BPCS upload.xlt" wSouce.Activate 'carry on from here Robin Hammond www.enhanceddatasystems.com "MESTRELLA29" wrote in message ... I have the following Macro that is a Journal Entry, when I run the macro it opens a template and copies information from the active workbook to the template, what I need is to run in base of the current active workbook and not "2004 JE Worksheets NEW.xls").Activate, because this forces me to name the file always the same way. Let me know if i did not make myself clear Workbooks.Add Template:= _ "C:\Documents and Settings\mestrell.000\Application Data\Microsoft\Templates\JE BPCS upload.xlt" Windows("2004 JE Worksheets NEW.xls").Activate |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
saving macro from workbook to Personal Macro Workbook | Excel Discussion (Misc queries) | |||
Combine worksheets in multiple workbook in one workbook with a macro | Excel Discussion (Misc queries) | |||
Macro to copy an image (or picture) from one workbook to a new sheetin another workbook | Excel Worksheet Functions | |||
Need a macro to copy a range in one workbook and paste into another workbook | Excel Programming | |||
Excel Gurus = want a macro in 1 workbook to get info from another workbook = Read please | Excel Programming |