V
Vinod
Hi All,
The macro which I designed functioning for some input files but not for all.
Here is my requirement, user will open an input file and clicks on run
button from menu options (custom menu from user defined add-in macro which is
already opend).
1. On click of run button an excel template (contains a procedure to update
output sheet calculations) opens from addin location.
2. Opened excel template is assinged to wbkTemplate object.
3. Addin macro copies current input sheet to template and saves the template
with input file name '_Output.xls' using SaveAs.
4. Then Addin macro will call 'Test' procedure in template/saved output.
I'm facing the problem at 4th step from above. To call output file procedure
from Addin I'm using Application.Run WbkTemplate.Name & "!Test". Which is
working fine when open some input files with clicking 'Run' from custom menu.
For some input files which is not allowing to call Application.Run
WbkTemplate.Name & "!Test".
I'm getting error number '1004' and description is 'saved file name'
_Output.xls!Test cannot be found.
Observations:
1. Saved output file name length is 58 characters without spaces.
2. Output file is created in specified path but not able to call a procedure
from it.
Please help me out in resolving the said issue by sharing your thoughts and
expertise in this area which can be appreciated.
Advanced Thanks,
~Vins
The macro which I designed functioning for some input files but not for all.
Here is my requirement, user will open an input file and clicks on run
button from menu options (custom menu from user defined add-in macro which is
already opend).
1. On click of run button an excel template (contains a procedure to update
output sheet calculations) opens from addin location.
2. Opened excel template is assinged to wbkTemplate object.
3. Addin macro copies current input sheet to template and saves the template
with input file name '_Output.xls' using SaveAs.
4. Then Addin macro will call 'Test' procedure in template/saved output.
I'm facing the problem at 4th step from above. To call output file procedure
from Addin I'm using Application.Run WbkTemplate.Name & "!Test". Which is
working fine when open some input files with clicking 'Run' from custom menu.
For some input files which is not allowing to call Application.Run
WbkTemplate.Name & "!Test".
I'm getting error number '1004' and description is 'saved file name'
_Output.xls!Test cannot be found.
Observations:
1. Saved output file name length is 58 characters without spaces.
2. Output file is created in specified path but not able to call a procedure
from it.
Please help me out in resolving the said issue by sharing your thoughts and
expertise in this area which can be appreciated.
Advanced Thanks,
~Vins