Your software should never wrest control of a computer from the user. The computer belongs to the user, and we have to work under the assumption that they know what they're doing better than your software does. If the user decides to shut down their machine, it's bad form for your application to prevent that. If you can tell us what base problem you're trying to solve or why you believe your application has to prevent shutdown, maybe we can help you come up with a better solution so you can avoid this situation altogether.
Check out My Blog. Now updated to actually work! By default, an application shuts down when the Windows session ends, which occurs when a user logs off or shuts down. When this happens, Windows asks each open application to shut down. However, it is possible that an application may not be ready to shut down when this occurs.
For example, an application may have data that is in an inconsistent state, or in the middle of a long-running operation. In these situations, it may be desirable to prevent the session from ending, and may be more desirable to allow users the option to decide whether or not to let the session to end. You can detect when a session ends by handling the SessionEnding event. If an application needs to prevent the session from ending, the SessionEndingCancelEventArgs argument that is passed to the event handler exposes the Cancel that you set to true the default value is false.
In reply to DavidSanchez01's post on January 10, Well, it seems like it just randomly turns off. I've been playing games and it turns or even sometimes when I'm just watching youtube. I don't see my mouse cursor, it makes it so that there is no connection to the monitor even when I try unplugging the monitor and plugging it back in. It does not take a specific amount of time to turn off, it seems random. Windows security was not on, but I just now turned it on.
The computer is new and all the drivers are up to date. Hi, thanks for keeping in touch, we will continue to look for the cause of your incident. I would like to ask you, what the result was when entering safe mode, the screen continues to turn off? I want you to perform the following test, if possible when the incident occurs on your monitor, connect your device to another monitor or if possible on your TV, if the image is reproduced on your TV, it is possible that the fault comes from your monitor, if not, try changing the connection cable.
I also want you to uninstall the video driver and leave the generic Windows, just to rule out that the problem is a badly migrated video driver. Finally, I would like you to verify that the components are correctly connected to your motherboard. Let me know the results of the processes, if they have been useful and if you need more help from me, I hope we can solve your incident soon.
In reply to DavidSanchez01's post on January 12, In reply to X's post on January 12, Thank you for the additional information and for keeping in touch.
Tell me, what was the result after using the PC in safe mode? Thanks for testing, we can rule out failure of your monitor and connection cables. In that case, we can rule out failure of your monitor and connection cables. Let me know the result of the other processes I've shared with you.
In Windows there is no image file Name field. So to determine the name of the program you must find the preceding event To identify the program on Windows Server you can simply use the image name which is supplied in this event. Top 10 Windows Security Events to Monitor.
Free Tool for Windows Event Collection. Supercharger Free Edition Supercharger's built-in Xpath filters leave the noise behind. What's new New posts Unanswered threads Latest activity. Members Current visitors. Log in Sign up. Search titles only. Search Advanced search….
New posts. Search forums. Log in. Sign up. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations.
0コメント