I use this command in autoit to turn off my laptop, if a timer runs out
Run(@SystemDir & "\shutdown.exe /f /s /t 10", "", @SW_MAXIMIZE)
It works fine most of the time, but occasionally I get the BlueScreen when turning the computer on, usually before the log on screen and after the Windows logo animation completes. Is this because of turning off the computer directly using the shutdown command, or can there be other issues? I should point out that when ever my autoit script shuts off the computer, usually there are multiple browsers with multiple tabs open, along with other applications running. So I want to know,
What is the difference between shutting off the computer through the start menu, by directly pressing the power button, and by issuing the shutdown command from the autoit script? Is abruptly shutting down the computer using the shutdown command while other user applications are running dangerous in any way?
My OS is Windows 7 and computer is a laptop
Event Viewer
and browse the System log there. The dump file is binary so it's no use trying to view it in a text editor, one could use a debugger to read it but I can't help you with that as I've never done it myself, either (although googling might give you some clues).