Click to See Complete Forum and Search --> : [RESOLVED] Destroy a window automatically - P/invoke...window handle??


tiago.teixeira
April 10th, 2007, 06:28 AM
Hello,

I'm using a 3rd part DLL via Add reference i my C# project and sometimes the DLL generate a messagebox with an error and an OK button.

I would like to know if its possible to automatically and programatically do the "OK Click" or how to destroy this window.
This windows is not a separeated proccess so i cannot kill it using System.Diagnostics.Process any idea?? I heard about windows handle and maybe with p/invoke but i can see how can i do it.

Thanks in advance,
Teixeira

tiago.teixeira
April 10th, 2007, 12:45 PM
I found the solution at codeproject.

here's the link if someone else need:
http://www.codeproject.com/cs/miscctrl/CsMsgBoxTimeOut.asp?df=100&forumid=90151&exp=0&select=947436

Best regards,
Tiago Teixeira