![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | Manifest not working Hi, I have a small program named MyProg.exe that requires administrative rights to run. I want that when the user run it, he gets the concent prompt to run it as administrator. I tried to create a manifest file named MyProg.exe.manifest in the same folder but it does not work at all. I'm not able to get the concent prompt. But, as I read on the internet, it should work. I tried with several version of the manifest file with no success at all. Is somebody could tell me what's wrong with manifest ? Is it should work or not ? Is somebody has a manifest file model that work ? Thanks for any help. -- G. Plante |
My System Specs![]() |
| | #2 (permalink) |
| | RE: Manifest not working > I have a small program named MyProg.exe that requires administrative rights > to run. I want that when the user run it, he gets the concent prompt to run > it as administrator. I tried to create a manifest file named > MyProg.exe.manifest in the same folder but it does not work at all. I'm not > able to get the concent prompt. But, as I read on the internet, it should > work. I tried with several version of the manifest file with no success at > all. I think my first attempt at answering was lost. I'm not expert on manifests (try someone in the programming newsgroups) but very likely the program has a manifest attached by the linker and I am pretty sure you can't have a file system manifest if there is an attached manifest. The easiest way to resolve the problem would probably be to embed the manifest with the linker. If you can't do that, why don't you try to extract the existing manifest and modify it. I used these steps to modify the manifest on Notepad.exe. 1. Open an SDK command prompt. It does not need to be an admin 2. Run mt.exe -nologo -inputresource:notepad.exe;#1 -out:extracted.manifest 3. Modify the extracted.manifest to change the requiredExecutionLevel to requireAdministrator 4. Re-embed the manifest using mt.exe -outputresource:notepad-test.exe;#1 -manifest extracted.manifest Obviously you'll need to replace notepad.exe and notepad-test.exe before you use these commands. The output resource must also exist already. |
My System Specs![]() |
| | #3 (permalink) |
| | Re: Manifest not working Thank you for this information. However, I do not have the MT.EXE utility. Whar I can find this utility ? Is this utility is included with some Microsoft products ? G. Plante. "Jesper" <Jesper@discussions.microsoft.com> wrote in message news:0733C1A5-6442-4E48-8925-6CB142EC35F1@microsoft.com... >> I have a small program named MyProg.exe that requires administrative >> rights >> to run. I want that when the user run it, he gets the concent prompt to >> run >> it as administrator. I tried to create a manifest file named >> MyProg.exe.manifest in the same folder but it does not work at all. I'm >> not >> able to get the concent prompt. But, as I read on the internet, it should >> work. I tried with several version of the manifest file with no success >> at >> all. > > I think my first attempt at answering was lost. > > I'm not expert on manifests (try someone in the programming newsgroups) > but > very likely the program has a manifest attached by the linker and I am > pretty > sure you can't have a file system manifest if there is an attached > manifest. > The easiest way to resolve the problem would probably be to embed the > manifest with the linker. If you can't do that, why don't you try to > extract > the existing manifest and modify it. I used these steps to modify the > manifest on Notepad.exe. > > 1. Open an SDK command prompt. It does not need to be an admin > 2. Run > mt.exe -nologo -inputresource:notepad.exe;#1 -out:extracted.manifest > 3. Modify the extracted.manifest to change the requiredExecutionLevel to > requireAdministrator > 4. Re-embed the manifest using > mt.exe -outputresource:notepad-test.exe;#1 -manifest extracted.manifest > > Obviously you'll need to replace notepad.exe and notepad-test.exe before > you > use these commands. The output resource must also exist already. > |
My System Specs![]() |
| | #4 (permalink) |
| | Re: Manifest not working > Thank you for this information. However, I do not have the MT.EXE utility. > Whar I can find this utility ? Is this utility is included with some > Microsoft products ? mt.exe is part of the Windows SDK. You can download it at: http://www.microsoft.com/downloads/d...displaylang=en |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| MANIFEST | Vista General | |||
| Creating Assembly Manifest.. Need help | .NET General | |||
| .EXE.manifest | Vista installation & setup | |||
| Trouble embedding a manifest into a .exe | Vista security | |||
| UAC Manifest for VB6 Apps | Vista security | |||