ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Declare Function issue with Vista (https://www.excelbanter.com/excel-programming/438124-declare-function-issue-vista.html)

Greg Lovern

Declare Function issue with Vista
 
I distribute a standard DLL with my Excel Add-In, install it to
<windir\System32, and reference it from the Add-In with Declare
Function. That works fine with Windows XP, but on Vista, if the user
doesn't right-click the setup file and choose Run As Administrator,
the DLL doesn't get copied.

I could copy it to the Add-In's folder instead, and then there would
be no problem copying the DLL to that folder, but since the user can
customize the install folder during setup, I can't hardcode the folder
in the Declare Function statement.

I could add the user's chosen install path to the system path, but if
my own is any indication, that isn't done much anymore, and I'm not
sure that it's a good idea.

Any suggestions on best practices for calling a custom standard DLL
from a Declare Function statement in Excel VBA?


Thanks,

Greg



All times are GMT +1. The time now is 02:07 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com