Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have an Excel spreadsheet which uses the solver add-in. I've developed it on a Windows 7 64 bit machine. The spreadsheet relies on some VBA code to set up the solver so I need a reference to solver.

The problem I run into, is that since I've developed it on 64 bit Windows 7, the reference points to the solver in C:\Program Files (x86)\Microsoft Office\Office12\Library\SOLVER. When some of my users try running the spreadsheet on their machines, the VBA throws some strange errors because the references are wrong. (Strangely they don't show up as Missing).

I've tried adding some code to remove the reference and then add it back in, but it's a mess because then you have to worry about how the security settings for Excel are set up on the machine. (i.e. my code requires that the "Trust access to the VBA object model" be set). That isn't that much of an issue, as I have complete control of the machines in the enterprise, but I'm not sure how to automate setting that flag on all of the machines.

Does anyone know how to set the "Developer Macro Settings": "Trust access to the VBA object model" via GPO or registry? Otherwise, what can I do, either by modifying the spreadsheet or by performing some action automatically on each machine, to deploy that spreadsheet?

Any experience in using Excel with Solver on both 32 and 64 bit OSes would be appreciated.

share|improve this question

closed as off topic by Zoredache, Tom O'Connor, Mark Wagner, Ward, Iain Dec 3 '11 at 17:47

Questions on Server Fault are expected to relate to professional server, networking, or related infrastructure administration within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

1 Answer 1

I can't speak to your first point, but the second one I can.

To do this, you will need to do two things:

  1. Import the Office 2007/2010 Administrative Template into a Group Policy.
  2. Set the value under User Configuration / Administrative Templates / Microsoft Office Excel [2007/2010] / Excel Options / Security / Trust Center

It can also be set via the Office Customization Tool, but the GPO will apply to everyone even if the OCT wasn't used for their install.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.