Want to stop your installations being from an unknown publisher according to Window 7’s UAC?

Well, if you’ve got a code signing certificate, you’ll want to sign your MSI files. You can of course just sign your files manually using the signtool utility as follows:

signtool.exe sign /a “path to your msi

The location of signtool varies depending on which version of Visual Studio you have installed. You can do a search for it, or you can just run it via the “Visual Studio Command Prompt” shortcut in your start menu (under Microsoft Visual Studio/Visual Studio Tools)

Obviously that gets annoying pretty quickly if you’re compiling it in Visual Studio all the time, so instead just add the call to signtool as a Post Build script within your Setup project:

“C:\Program Files\Microsoft SDKs\Windows\v7.0A\bin\signtool.exe” sign /a /d “My Application” “$(BuiltOuputPath)”

Make sure the path to signtool is correct. Also, change “My Application” to the name of your application – this appears as the program name in the UAC prompt that appears. If you don’t set it to a value, the default will be the name if the MSI that Windows Installer assigns (which you can assume will be some ugly hex number)

You can also add a link to additional information about your product by using the /du parameter with signtool – but I’ll leave that to you to work out…

Have you ever logged in to Vista or Windows 7, and after entering your password all you end up with is a black screen with only the mouse pointer appearing? Don’t worry – your machine’s probably not screwed completely – to prove it, hit the Shift key five times and you should see some sign of life. You can even use that sign of life to get access to most things on your machine should you feel so inclined.

Well we’ve suffered it a few too many times on some of our machines, and after cursing, pulling our hair out, lots of research on the web, and even upgrading one machine from Vista to Windows 7, we finally came across what is a pretty simple fix which has worked every time.

Turns out for us it’s always been due to a problem with the event logs – and clearing them out fixes the issue.

So how do you clear out your event logs?  Just boot into Safe Mode (I’m assuming you know how to do that – that’s the “press the F8 key as your machine starts up” thingy), log in as normal, then go to the event viewer (from the start menu and right click on “Computer”, select Manage, then click on the Event Viewer option from System Tools)  Next expand the Event Viewer option, then expand both the Windows Logs and Applications and Services Logs options, then on each log (like Application, Security etc), right click on it and select Clear Log… I then select the Clear option (who wants to save the logs anyway?)  Now reboot again and voila – you should now have a working machine.

Well that works for us…let us know how you get along.

Oh, and Microsoft, can you go and fix your operating system – it shouldn’t die like this because of some simple corruption – how about an error message and a simple prompt to reset any log that’s got problems?

Now as to what is causing the problem – well it’s probably the antivirus software or something like that. I’d do some more investigation but…

© Copyright - Mosmar