Pc shutdown win XP / win98se

looks like your operating system is win 98 - ?

the code works with win 2000 and XP ONLY !!

best
cali wrote:

when i run this code i always get this exception:

Java.IOException CreateProcess : shutdown -s -f -t 20

what should i do???

when i run this code i always get this exception:

Java.IOException CreateProcess : shutdown -s -f -t 20m, but I am using windows 2000. what shall I do
please send me full code for shutdown.
thank you!

fasfaster,

Windows 2000 does not have shutdown.exe - it is part of the Windows 2000 Resource Kit. However, I am sure you can download it from somewhere.

Here is a modified version with more features such as logoff and hibernate support.

http://www.budja.com/shutdown/

Hope this helps.

Martyn

Hi friend(s)!
How can i shutdown & restart all the systems which are in network

hi ,
u can try out this code…
To shut down ur 9x windows…

Runtime.getRuntime().exec(“rundll32.exe user.exe,exitWindowsExec”);

hi ,
u can try out this code…
To shut down ur 9x windows…

hi
friends i am making project on network security devide in 3 modul
last modul is reboot pc of clinet by adminstrater useig RMI
i had make reboot program in c & by native funtion
connect c to java program

problem is that

it is working on win xp
so give suggetion how make reboot C language program for win 98.2000,xp

hi friends ,

How to get code to write a prgram that shut down with every Windows OS.
With abode code, then I only can shutdown with WindowsXP.
Who known, please help me . Thks

hey, i’m trying to figure out how to make someones life hell, what i am trying to do is using the code above. i would like to make it so you are asked a question, or a riddle, and if they get it correct, use the shutdown -a command to stop the shutdown.

any help?

hi friends i want to c and java code 4 system reboot plz help me

[quote=martyn]Zogan,

I’m not sure how to do a hibernate, but to reboot the machine you will have to add a “/R” into the command string.

There are many other switches which you can use for the shutdown.exe program. To see them, in a DOS prompt, type “shutdown /?”.

Hope this was helpful.

Martyn[/quote]

I just want to make a button that will shut down the computer when hit. should I just give the button the

{
Runtime.getRuntime().exec(“shutdown -s -f -t 20”);
}
catch (IOException e) {
System.err.println(e);
}

code?

(I’m a n00b) :expressionless: