Laman

Rabu, 09 Februari 2011

Shutdown and Restart computer in C# ( C Sharp )

Actualy the program to shutdown or restrart on a computer using C# there are two ways, namely using the help command prompt and the second pure script of the language itself dotNet. For this post will be explained and also give examples of haow making project for shutdown or do restart on a computer using the help command promt, so that programers are required to at least know the basic function from  command promt itselt.
 Before you learn more abaout the program that will be made to perform on a computer shutdown or restrart please read the firs article to run the command prompt in C#. This will graetly help in understanding this materi. Because the concept is almost similar to way programs run command prompt such a change. Now beginning its work on the project . As usual for the fitst step please prepare an empty project an empty project please click on the file after the new project dialog box appears please use the project name project name in box, there are no specific rules in writing the name of the project. For the next step please follow the intstruction below
Step 1 : Add two buttons on form1 in the project has been provided previously, organize and structure such that it looks loke in the picture below 


langlah 2 : Add the following code in C# libraries.
using System.Diagnostics;

langkah 3: Double click on button (labeled shutdown) for raising the event click on the button, add the following source code
 Process.Start("shutdown.exe", "/s /t 00 /f");

langkah 4 : Double click on button2(labeled restart) for raising the event click on the button, add the following source code 
 Process.Start("shutdown.exe", "/r /t 00 /f");

langkah 5 : Done. The program finished create.
If the above steps are followed and done correctly the program when run will be show labeled button shutdown and restart. If the user clicks on the shutdown button, the the computer will be shutdown by program whereas if the user presses the button then the computer will restart in restart by the program 

to more understand this materi please download the example program here. And also download the project of here



Clue download : click the link download above, after which it will apear adf.ly pages, wait several second until the top right corner it show "skip ad", click the button, after which it will appear ziddu page, please click on the download button which appears on page ziddu
NB : All of program in this tutorial write using the IDE Visual Studio 2010. with the target framework 3.5

14 komentar:

  1. Addons I blocked Ip , I want to try your software.
    can show the other link download ?
    thanks,....

    BalasHapus
  2. you can download here
    http://www.ziddu.com/download/15395684/ShutDownKomputer.rar.html

    or here
    http://www.4shared.com/file/2Bp_5FY0/ShutDownKomputer.html

    BalasHapus
  3. Since taking over as global CEO of MBT in November 2008, the former exec Timberland has immersed in christian louboutin shoes the wellness movement. After Pucker, he has handed over the challenge of transformation MBT on a concept and a company. "It means mbt shoes to be a reliable and competent partner," Pucker said to increase the recognition of the need services, including supply chain management to christian louboutin outlet improve and shorten lead times.
    Eight MBT employees take the company message on the road. "We want [retail] make employees understand the fitflop sandals product" field per Amy Manson.Added Spears said: "It is the front line for us." While connecting to the trade represents MBT in mizuno wave prophecy 3 the foreground, the company has aggressive plan to target consumers with a new advertising campaign. Put this month in the Style section mbt shoes outlet of the New York fitflop sale Times at the start, it will be followed by a national campaign next spring. "The separated us from the pack," Heidegger said of the first display, the MBT as the original identified wellness footwear. "It is to build a stronger body. We Mizuno Wave Prophecy 2 are Swiss innovation combined with Italian style. Our [technology] is concerned with the whole body, not just the toning aspect."
    FitFlop joins mbt outlet the breast cancer awareness movement with its pink on the feet campaign throughout October runs. Under the initiative, proceeds from the sale christian louboutin sale of its Super Sneaker Mid in hot-pink suede on Fitflop.com will go to the Breast Cancer Research Foundation. A minimum of $ fitflop shoes 100 per pair (the style retailed for $ 165) donated. The company also plans 10 percent of the purchase price of each mizuno wave shoes pair of FitFlop shoes on its website in the colors pink punch to donate framboise and sold hibiscus.

    BalasHapus
  4. Is Under Armour, a brand built on hardcore training and in-the-gym apparel, ready for the lifestyle look? There’s no question that the brand has been on the receiving end of the surge in the fitness lifestyle, and the emergence of Steph Curry has only Nike Zoom Kobe Icon further legitimized UA as a contender in footwear within and beyond the basketball category. Today, Under Armour unveils their Modern Sport Collection for women, a rich selection of sport-inspired lifestyle silhouettes built with LeBron Soldier 10 rich tonal leathers in black and rose pink as well as a third line with an energetic black/white static-y mesh. One of the standouts is the Charged Pivot lifestyle shoe, a clear off-shoot kobe basketball shoes of the super popular Curry One (for the Ayeshas, not the Stephs). Right now the black leather options as well as the Charged All Around are available on the UA site, with prices kyrie shoes ranging from $100-140. The rose colorways will drop on November 15th.
    The Nike LeBron 13 Elite is getting a new EXT treatment for the end of summer with this premium monochromatic “Linen” offering Kyrie irving shoes arriving at retailers on September 9th. You can already find the pair in select sizes on eBay, but if you’re in need of another look before you seal the deal and make a Kyrie 1 purchase then we have more detailed photos for you below.The LeBron 13 Elite has only received a handful of colorways which is why we’re so surprised to see this luxurious leather tooling all KD shoes of a sudden. All the aspects of the playoff-ready LeBron 13 Elite are here including that oversized carbon fiber shank, underlying Dynamic Flywire support system, and that strange but enticing padded ankle construction. LeBron soldier 9 The premium leather upper ditches any trace of that new Kurim rubberized textile while a soft Linen shade hits throughout to further camouflage the embossed Swoosh branding. What do you think of the LeBron 11 latest Nike LeBron 13 Elite EXT? Check out more photos below and head over to our release dates page for more updates.
    How many Kobe 11 Mambacurial versions are we going to get Kobe 7 this year? Nike Basketball has already planned on releasing an eclectic “What The Mambacurial” and another premium Flyknit rendition based on Kobe’s love of FC Barcelona. Today we get a look at another Kobe high tops

    BalasHapus