Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MessageBox in c#

Tags:

c#

messagebox

I want to show messagebox to the user, such that the user cannot refuse to confirm the message box. User should not be allowed to do anything else in the screen until he confirms the messagebox.

This is a windows based c# application.

The main thing is, even if i use windows message box. Some times it is hiding behind some screen. But for my case, i want message box to be on top most whenever it appears.

I am using some other third party applications, which over rides my message box. I want to overcome this.

How to do this...

like image 876
Anuya Avatar asked Sep 08 '09 04:09

Anuya


1 Answers

You will have to create your own form, make it modal, change the z-order to make it always on top, and capture all keystrokes and mouse clicks.

Always on top: http://www.codeguru.com/cpp/w-d/dislog/article.php/c1857

like image 88
Tangurena Avatar answered Sep 22 '22 16:09

Tangurena