Custom program running level in Vista system

Source: Internet
Author: User

Hands-on Lab
Session 02-lab 01
Custom program running level in Vista system

 
Windows Vista

 

Content
Description 3
Goals and objectives 3
If you have previusly done this lab 3
Expected duration 3
Step 1-launching the report 3
Step 2-modifying the bug rates report 5
Step 3-deploying your report 7
SUMMARY 7
 
 

 

SSW Consulting has 16 years experience implementing best of breed solutions that improve your operating efficiency

And competitive advantage. We deliver scalable and extensible custom solutions on top of the latest Microsoft

Technologies. Our consultants are Microsoft certified already sionals, continually trained in best practices. We have

Been servicing: sysydney NSW, Melbourne Vic, Brisbane QLD, Canberra ACT and adelide SA. cities we have

Representatives in: Los Angeles (Ca, US), Portland (or, US), and San Francisco (Ca, US ).

Copyright SSW 1990-2008. All Rights Reserved
Session 02-lab 01
Custom application running level in Vista

Introduction
This experiment is intended to help you learn how to add your applications to the running level of Vista.

Purpose

This experiment allows you to customize the running level of any program.

If you have completed this experiment before
None

Expected completion time
45 minutes

Step 1-ensure that Vista UAC is enabled

1. Click the Start Menu of Vista, select the current user icon at the top of the Start menu, and click:
 
2. In the pop-up window, select turn User Account Control on or off:
 
3. In the dialog box, make sure that the use User Account Control (UAC) to help protect your computer check box is selected:
 
If this option is not selected, click Select option and then click OK to restart the computer.
 
Step 2-create a Windows form application

1. Open vs 2008, select File> New> project... :
 
 
2. In the displayed Project Creation wizard, select Visual C #-> Windows Forms Application:
 
3. Enter the project name vistalogodemo and click OK to create the project:
 
 
4. here our program is built here. We mainly experience the definition of the Vista running level. Here, click the debug button for debugging:
 
 

 
Step 3-add an embedded Custom Level for the program in vs2008 so that the program has the administrator privilege to run

1. Create a text file and name it "Executable File .exe. manifest". Here we write it as vistalogodemo.exe. manifest ".

Paste the surface content to the file:

<? 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 = "vistalogodemo" type = "Win32"/>
<Description> description of your application </description>
<! -- Identify the application security requirements. -->
<Trustinfo xmlns = "urn: Schemas-Microsoft-com: ASM. V3">
<Security>
<Requestedprivileges>
<Requestedexecutionlevel level = "requireadministrator" UIAccess = "false"/>
</Requestedprivileges>
</Security>
</Trustinfo>
</Assembly>
2. Store the file in the "bin/debug" directory of the project:
 
3. Return to the program solution, select the show all files button at the top of the VS solution browser, and click:
 
 
4. Open the vistalogodemo.exe file in the debugdirectory under the bindirectory:
 
5. After opening the file, the tree list of the EXE file will appear:
 
6. Right-click the list and choose Add Resource:
 
7. In the pop-up dialog box, select import:
 
8. In the pop-up file selection dialog box, select all files from the filter box:
 
9. Select the vistalogodemo.exe. manifest file we just created and click the OPEN button:
 
10. In the displayed dialog box, enter rt_manifest in resource type, and click OK:
 
 
11. After completion, go back to the tree list of the vistalogodemo.exe file and find the newly added resource rt_manifest:
 
12. Right-click a node with a value of 101 and select Properties to change its ID attribute to 1:
 
 
13. delete a node with a value of 1 [neutral:
 
 
14. Save the EXE file:
 
15. Run the application in the bin/DEBUG directory of the Project. By default, the program runs as administrator:
 

Summary
Through this experiment, we hope you can learn how to add a running level for your program.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.