Rabu, 02 Mei 2012

[MS_AccessPros] Re: Reading Registry For Trusted Location

 

My tip would be to replace the BAT with an NSIS Executable. The Executable will run quicker over the network than a BAT Copying a file byte-for-byte and it can check, set, and if necessary delete, the Trusted Locations settings from the registry.

You *can* replace the BAT with a Windows Script and it will be a question of personal taste and experience if the Windows Script or NSIS way is easier or more maintainable. (You will also find some IT/Network Admins who won't allow EXEs to be called over a network, or Windows Scripts to run on a Workstation, which may scupper your intentions but you can argue that BATs are not intrinsically safer.)

Yrs, Andrew

--- In MS_Access_Professionals@yahoogroups.com, "D" <embreydl@...> wrote:
>
> Greetings All,
>
> My company is upgrading from Windows XP and Office 2003 to Windows 7 and Office 2007. We have many Access applications that we need to add the location of the local database to the trusted locations in order for the vba code to run without receiving the security warning. I've found a program, AddPath.exe, that will allow us to add the trusted location to prevent the user from having to intervene and add the path to the trusted locations.
>
> My question is, how can I read the registry to see if the registry key for the trusted location already exists. Obviously, if it already exists it doesn't need to be added. Most of our applications have the users execute a .bat file that creates the folder for the database on the local machine and copies the latest version of the database from a network drive.
>
> Thanks in advance for your help.
>
>
> Darrell
>

__._,_.___
.

__,_._,___

Tidak ada komentar:

Posting Komentar