|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Difficult TaskHi all! I have a very difficult task for me and i can't so it. My task:
I have created an application. But how to determine that it is not responding??? You can see it when windows add "Not Responding" to application title, but how to catch it from application? I hope you'll help... Hello Laserson,
Heh. Lets examine what you are asking... You want your application, which has stopped responding, to itsself generate a response detailing it's non-responsiveness. That's like shooting a guy in the head and then asking to the corpse to call the morgue and arrange it's own funeral. Neat trick if it were possible.. but no possible with our current technology. Only thing you can do is duplicate the Task Manager functionality.. monitor your process from another application. -Boo Show quoteHide quote > Hi all! I have a very difficult task for me and i can't so it. My > task: > > I have created an application. But how to determine that it is not > responding??? You can see it when windows add "Not Responding" to > application title, but how to catch it from application? > > I hope you'll help... > Boo
nice answer, Cor Show quoteHide quote "GhostInAK" <ghosti***@gmail.com> schreef in bericht news:be1391bf13b798c88e8b95db9020@news.microsoft.com... > Hello Laserson, > > Heh. Lets examine what you are asking... > You want your application, which has stopped responding, to itsself > generate a response detailing it's non-responsiveness. That's like > shooting a guy in the head and then asking to the corpse to call the > morgue and arrange it's own funeral. Neat trick if it were possible.. but > no possible with our current technology. > > Only thing you can do is duplicate the Task Manager functionality.. > monitor your process from another application. > > -Boo > >> Hi all! I have a very difficult task for me and i can't so it. My >> task: >> >> I have created an application. But how to determine that it is not >> responding??? You can see it when windows add "Not Responding" to >> application title, but how to catch it from application? >> >> I hope you'll help... >> > > It is possible, and simple - so you don't have to shoot yourself in the
hand. "Not responding" means that the main thread is not responding to messages - it does not mean that the application is hanging. You can try to use a backgroundthread, wich checks the program using GetProcessesByName. Sample: Public Class Form1 Private WithEvents bgt As New System.ComponentModel.BackgroundWorker Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load 'Show the form Me.Show() Me.Refresh() 'Start the background worker bgt.RunWorkerAsync() Do 'and hang the app Loop End Sub Private Sub bgt_DoWork(ByVal sender As Object, ByVal e As System.ComponentModel.DoWorkEventArgs) Handles bgt.DoWork Dim myprocess As Process = Process.GetCurrentProcess() Do Threading.Thread.Sleep(1000) If myprocess.Responding Then Debug.Print("Responding") Else Debug.Print("Not responding") End If Loop End Sub End Class Cor Ligthert [MVP] wrote: Show quoteHide quote > Boo > > nice answer, > > Cor > > "GhostInAK" <ghosti***@gmail.com> schreef in bericht > news:be1391bf13b798c88e8b95db9020@news.microsoft.com... >> Hello Laserson, >> >> Heh. Lets examine what you are asking... >> You want your application, which has stopped responding, to itsself >> generate a response detailing it's non-responsiveness. That's like >> shooting a guy in the head and then asking to the corpse to call the >> morgue and arrange it's own funeral. Neat trick if it were possible.. but >> no possible with our current technology. >> >> Only thing you can do is duplicate the Task Manager functionality.. >> monitor your process from another application. >> >> -Boo >> >>> Hi all! I have a very difficult task for me and i can't so it. My >>> task: >>> >>> I have created an application. But how to determine that it is not >>> responding??? You can see it when windows add "Not Responding" to >>> application title, but how to catch it from application? >>> >>> I hope you'll help... >>> >> > > Laserson,
The same as "Can God lift a stone that he has made himself not liftable" Cor Show quoteHide quote "Laserson" <laser***@yandex.ru> schreef in bericht news:eehVySJwGHA.1772@TK2MSFTNGP06.phx.gbl... > Hi all! I have a very difficult task for me and i can't so it. My task: > > I have created an application. But how to determine that it is not > responding??? You can see it when windows add "Not Responding" to > application title, but how to catch it from application? > > I hope you'll help...
Update DataSet
Using OLEDB with Excel IndexOf string method VB.Net Appliction stops working when version is updated CurrentUser Ctype vb 2005 express > querry table in access and put contents into array How to read large text file ? brain death Accessing shared member - need understanding - pretty please :-) |
|||||||||||||||||||||||