Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > Pro VB 6
|
Pro VB 6 For advanced Visual Basic coders working in version 6 (not .NET). Beginning-level questions will be redirected to other forums, including Beginning VB 6.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro VB 6 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 13th, 2006, 10:55 PM
Authorized User
 
Join Date: Nov 2003
Posts: 18
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to check whether a program is running or hung

hi,

I am writing a small program A to check whether program B is running or hung. I am using the SendMessageTimeout to get reply from the program B to check for it, as the follow:
nret = SendMessageTimeout(mlngFTPhWnd, WM_GETTEXTLENGTH, 0&, ByVal 0&, SMTO_BLOCK, 5000, lpdwResult)

But I found a problem with this, supppose program B is running and doing some heavy processing so program B may return unsuccessful value to program A and program A will defined program B is hung, but actually it is not. :(

How am I going to resolve this? any other solution beside using SendMessageTimeout?

Advanced thanks for those who able to help.







Similar Threads
Thread Thread Starter Forum Replies Last Post
Running a program off the network? myurick Visual Basic 2008 Essentials 4 April 3rd, 2008 02:22 PM
Exception in running a program furqanms Java Basics 2 June 21st, 2006 10:39 PM
running another .exe from my program salhabb C++ Programming 1 January 18th, 2006 06:21 AM
How to check if a windows program is running in c beardje2000 C++ Programming 0 December 17th, 2003 01:49 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.