Solved

Need to S/D another app - can't find handle

Posted on 1999-01-11
6
171 Views
Last Modified: 2010-05-03
My VB app needs to send a WM_Quit message to a remote application but cant find window using FindWindow API call. The app is a toolbar and has no caption, but SPY++ says it's caption is "Conference Panel". FindWindow doesn't see this name. If i manually give it the hwnd it works. ????
0
Comment
Question by:rblackwell
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 8

Expert Comment

by:MikeP090797
ID: 1455385
You might have confuesed the window caption and the class name. The class name is the first param in FindWindow, the caption is the second. Anyway, every window has a class name, you can use FindWindow with that class name to look it up.

Tell me if it works
0
 
LVL 1

Accepted Solution

by:
Johnn earned 100 total points
ID: 1455386
MikeP is right.  Use the FindWindow API like this:

hWnd=FindWindow("Conference Panel",vbNullString)

The only problem you'll have with this is that if you have more than one instance of that class running the function will likely return the one most recently used or highest in the hirearchy.

John

0
 
LVL 8

Expert Comment

by:MikeP090797
ID: 1455387
John, that's called stealing answers
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 1

Expert Comment

by:Johnn
ID: 1455388
Mike, sorry I guess your's wasn't detailed enough?  It's my first time here...

John
0
 
LVL 8

Expert Comment

by:MikeP090797
ID: 1455389
Ok, I realize that.
0
 
LVL 13

Expert Comment

by:Mirkwood
ID: 1455390
Bought This Question.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses
Course of the Month10 days, 10 hours left to enroll

632 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question