views:

103

answers:

2

Hi, I have a Windows Installer project built for my VSTO add-in. However, I have to run one of my DLLs through an obfuscator at the end, but if I try to build the setup project with the modified DLL, it just rebuilds my original DLL and overwrites the modified one. Is there a way I can build the setup project and use my modified DLL?

Thanks.

+1  A: 

Can you simply add the DLL to your installer project the way you'd add a static file? Treat it as 'content'.

Charlie Salts
This is working a bit. I've got to do more checking to make sure though.
Max
+1  A: 

You should be able to run the obfuscator in your post-build event:

if $(ConfigurationName) == Release <obfuscatorprogram> $(OutDir)$(TargetFileName)

Post-build events are in your project properties, under Build Events.

if you're already doing this, I'm not sure what's wrong.

HiredMind
Hi HiredMind. For some reason I still can't get that to work. What I did was build my program's DLL (this is still in Debug release mode), and then have a pre build event that compies the obfuscated DLL to the build folder before build (I also did a post build event). For some reason the assembly being packaged is still not obfuscated. Any other ideas?
Max