473,398 Members | 2,427 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

EnumWindows

Hi there,

I'm using the EnumWindows method in VB.NET to acquire the HDC of all
open windows. Unfortunately I get lots of unwanted window handles, I would
*ideally* like just the windows that are displayed along the taskbar, any
ideas on how I would seperate these? Thanks loads in advance.

--
Nick Pateman

---------------------------------------------------------------
Please do not reply directly to me, but the entire newsgroup.
Any views expressed above are my own
Without predjudice
Nov 21 '05 #1
3 3293
"Nick" <no****@nospam.com> schrieb:
I'm using the EnumWindows method in VB.NET to acquire the HDC of all
open windows. Unfortunately I get lots of unwanted window handles, I
would *ideally* like just the windows that are displayed along the
taskbar, any ideas on how I would seperate these?


You could use 'GetWindowLong' to check if the 'WS_VISIBLE' style bit is set
and 'WS_CHILD' is not set.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #2
Hi Herfied,

Excellent, thanks for your help :-)

Nick.

"Herfried K. Wagner [MVP]" <hi***************@gmx.at> wrote in message
news:%2****************@TK2MSFTNGP14.phx.gbl...
"Nick" <no****@nospam.com> schrieb:
I'm using the EnumWindows method in VB.NET to acquire the HDC of all
open windows. Unfortunately I get lots of unwanted window handles, I
would *ideally* like just the windows that are displayed along the
taskbar, any ideas on how I would seperate these?


You could use 'GetWindowLong' to check if the 'WS_VISIBLE' style bit is
set and 'WS_CHILD' is not set.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #3
Nick,

Any chance in seeing this code you mentioned here?

Kevin
"Nick" <no****@nospam.com> wrote in message
news:er**************@TK2MSFTNGP09.phx.gbl...
Hi there,

I'm using the EnumWindows method in VB.NET to acquire the HDC of all
open windows. Unfortunately I get lots of unwanted window handles, I
would *ideally* like just the windows that are displayed along the
taskbar, any ideas on how I would seperate these? Thanks loads in
advance.

--
Nick Pateman

---------------------------------------------------------------
Please do not reply directly to me, but the entire newsgroup.
Any views expressed above are my own
Without predjudice

Nov 21 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Sean Dudley | last post by:
I am currently enumerating windows via the EnumWindows API. I noticed that for some reason the very first time I call my enumwindows routine (inside or outside of a thread) it seems to be very...
3
by: Tim Chase | last post by:
I have found that EnumWindows works very quickly. In DotNet (I use C#), I can enumerate the windows, narrow them down to just the windows which are the main windows (i.e., windows which you can...
11
by: Wayne | last post by:
I have some code written in delphi that uses EnumWindows, I would like to begin to translate this code to C#. Is there a built in EnumWindows call in Csharp? or do I have to import the API and use...
0
by: Paul Steele | last post by:
I've written a callback function for use with EnumWindow that is intended to return the URL of all open IE windows. The code seems to do almost exactly what I want, but fails at the final step when...
1
by: Frederic_BD | last post by:
Hello! I am trying to get a list of all the process running on WinCE. I first developed my code on NT (which is working fine) and now I am porting it to WinCE 4.20. I am using embedded Visual...
4
by: Geoff | last post by:
I need to reproduce functionality from a VB6 application in VB .Net. In the VB6 app, I use FindWindow, EnumWindows and other related functions. Is there a .Net NameSpace that replaces these...
1
by: Geoff | last post by:
Tom, I am trying to find out if a specific app is already running. And, in some cases, I will need to be able to "click a button" in that other app if it IS running. Using VS.Net 2003 and .Net...
10
by: SQACPP | last post by:
Hi, I try to figure out how to use Callback procedure in a C++ form project The following code *work* perfectly on a console project #include "Windows.h" BOOL CALLBACK...
1
by: =?Utf-8?B?VHJlY2l1cw==?= | last post by:
Hello, Newsgroupians: I've a question regarding the Win32 function EnumWindows. First, the prototype for EnumWindows is as follows... BOOL EnumWindows(WNDENUMPROC lpEnumFunc, LPARAM lParam) ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.