Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Shutting down the computer

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
Does anyone have some code in assembly that will shut down a computer? Im making my computer have a duel boot with dos 6.0 and windows xp. I have all the code done in QBASIC, except for the shutting down the comuter part. I also want it to restart the computer.

thanks.
 
Reboot in DOS is:

int 019h ;no parameters

AmkG will probably know win32 calls.

"People who have nothing to say, say it too loud and have little knowledge. It's the quiet ones you need to worry about!"
 
Well for win32... you need to call a particular API in a particular DLL, whose name I forgot. You might be able to do a search on win32asmboard.cjb.net (ask only if you can't find it via search...).

There was also a Windows utility on c|net which gave you several options on how to restart your computer... you could download a free version (all 9 megabytes of it) and pay $25 for the full version. 'Course you could always select Start|Shutdown but hey you had 8 shutdown options... come on pay $25 dollars to get more shutdown options... bleah....

As for Int19h... that's incomplete... there are other things that need to be done but unfortunately for me I don't remember them... I once had an example proggy with all possible DOS reboot flavors BUT the HDD it was on got trashed after 15-odd years of abuse.
"Information has a tendency to be free. Which means someone will always tell you something you don't want to know."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top