Because sometimes, it just has to run elevated…
< ?xml version="1.0" encoding="UTF-8" standalone="yes" ?> <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestversion="1.0"> <assemblyidentity version="1.0.0.0" processorArchitecture="X86" name="ASSEMBLY_NAME" type="win32"/> <trustinfo xmlns="urn:schemas-microsoft-com:asm.v3"> <security> <requestedprivileges> <requestedexecutionlevel level="requireAdministrator"/> </requestedprivileges> </security> </trustinfo> </assembly>
Embed the above file (after setting the correct assembly info, that is) as a Win32 resource, and you’re done! Bart De Smet wrote down how to do it. Visual Studio Orcas can do it OOB.