J
JS.
hi, all,
I created an add-in for PowerPoint 2007 using VSTO 3.0. In the add-in, I
created a customtaskpane, which has a button. When I click the button, the
add-in will call a function in a unmanaged DLL, and load a exteranl file for
computation.
The add-in runs OK if I debug it directly from the Visual Studio.
However, when I tried to run PowerPoint directly (not from Visual Studio via
the Debug menu), the add-in is loaded correctly, but it does not run as
expected. The external file used by the unmanged DLL for computation is not
loaded correctly.
I use ProcessMon to monitor the running of PowerPoint and the add-in. It
is found that when PowerPoint (and the add-in) is run by choosing "Debug" in
Visual Studio, the add-in will try to load the file needed from the
"bin\debug" folder. However, when I run PowerPoint directly (with the add-in
enabled), it will try to load the external file from my profile folder, i.e.
"C:\Documents and Settings\<my_user_account>". It cannot run correctly
because there is no such file under the profile folder.
Is it possible to change the search folder that add-in is searching for
needed file when it is loaded by running PowerPoint directly?
Thanks for your advice.
Regards,
JS.
I created an add-in for PowerPoint 2007 using VSTO 3.0. In the add-in, I
created a customtaskpane, which has a button. When I click the button, the
add-in will call a function in a unmanaged DLL, and load a exteranl file for
computation.
The add-in runs OK if I debug it directly from the Visual Studio.
However, when I tried to run PowerPoint directly (not from Visual Studio via
the Debug menu), the add-in is loaded correctly, but it does not run as
expected. The external file used by the unmanged DLL for computation is not
loaded correctly.
I use ProcessMon to monitor the running of PowerPoint and the add-in. It
is found that when PowerPoint (and the add-in) is run by choosing "Debug" in
Visual Studio, the add-in will try to load the file needed from the
"bin\debug" folder. However, when I run PowerPoint directly (with the add-in
enabled), it will try to load the external file from my profile folder, i.e.
"C:\Documents and Settings\<my_user_account>". It cannot run correctly
because there is no such file under the profile folder.
Is it possible to change the search folder that add-in is searching for
needed file when it is loaded by running PowerPoint directly?
Thanks for your advice.
Regards,
JS.