views:

157

answers:

1

And is is possible to do that from code?

A: 

Possible probably, but not by any prebuilt API that I know of. If you could sign code from code it would allow self modifying to stay signed. That would be a bit of a security issue.

Now VBA does allow for binary read/writes you could slap a monitor on your application and watch what happens when you sign code and replicate what it is doing. But I'd guess that would be pretty non-trivial.

You could of course kludge together using sendkeys... But don't.

Out of curiosity, what problem are you trying to solve?

Oorang
If the XLA is not signed you get a warning (or even a failure depending on some policy) when you start Excel with the add-in. We have a code signing certificate, but it is only available to the buildmaster on the build machine so I was wondering how to make a script that would sign the XLA on our build machine.
Arve
Honestly, it's probably more trouble than it's worth. Any solution you came up with would be so much worse than just doing it manually. Sorry to be the bearer of bad news.
Oorang