|
I already know how to get the handle to the foreground window using the GetForegroundWindow() function inside user32.dll, but i also need something that will return a collection of the handles of all the open windows. If there is no function to do this, and you think there could be another way to do this, please let me know.
|
|
|
|
|
Hi,
user32.dll also holds EnumChildWindows and EnumWindows for you.
|
|
|
|
|
Thanks. I tried that, and for some reason i get 537 handles returned. Obviously, i don't have 537 windows open, so would you (or anyone else) happen to know why it enumerates that many times??? Also, to make myself more clear, i am making a virtual desktop program, so i only want to get the windows that are actually visible (excluding the explorer.exe process).
modified on Monday, July 7, 2008 12:13 AM
|
|
|
|
|
Every control is it's own window, visible or not. Even controls that you think are a single control, are really a combination of smaller controls working together.
|
|
|
|
|
Actually you do have 537 window handles open at one time. To see details on the windows (or for that matter actually believe you have 537 windows open), you can open Spy++ which is an application installed by Visual Studio for debugging aspects of programs and the OS. Spy++, which should be able to be found in the start menu and will list every window/sub-window currently displayed in windows.
Regards,
Thomas Stockwell
Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.
Visit my homepage Oracle Studios
Discounted or Free Software for Students:
DreamSpark - downloads.channel8.msdn.com
MSDN Academic Alliance - www.msdnaa.com
|
|
|
|
|
I managed to narrow it down to filter out everything but the open windows using the IsWindow() and IsWindowVisible() function inside user32.
|
|
|
|
|
helloI Have Question....
What write a Program that can the object or picture similar object1 object1[IMG]http://i30.tinypic.com/24q5r7n.jpg[/IMG]
with analyze object2 place in object or picture similar object2object2
[IMG]http://i25.tinypic.com/2a604nn.jpg[/IMG]
that can been minimize space of object2 .
?????????Do you known sample code or you can help about this program.????
pleas help .........
pleas help......
hi......
|
|
|
|
|
Wow - that's a lot of works for a question that makes no sense at all. I *think* you want to draw the boomerang over and over on the red shape. Create a texture brush for this, you can do this from a bitmap and you can specify a transparent color, so you can do an irregular shape.
Christian Graus
Please read this if you don't understand the answer I've given you. If you're still stuck, ask me for more information.
|
|
|
|
|
Hello,
I've been trying to drag & drop an image from a PictureBox to Explorer to create a .bmp file of said image, and I've had no success. I've looked and looked all over the 'Net, found a couple of hopeful looking solutions, but nothing has actually worked.
I've played around with drag & drop, and I can move a picture between two PictureBoxes okay. I was kind of thinking if there was a way to get a string of the path in which I am attempting to drop the image, I could just save it, but I don't know if that's the best way or if it's even possible.
Does anyone know how this could be done?
EDIT: I saw the article here[^], but it's in C#... I only know Visual Basic.
As I sit here, I contemplate the last words of Socrates: "I drank what?".
|
|
|
|
|
CodeMonkey85 wrote: it's in C#
No, it is in C++.
CodeMonkey85 wrote: Does anyone know how this could be done?
Try taking Mike's code, convert it to pseudocode, and then take that pseudocode and covert to vb.net. Sounds like a bit of work, but it does work okay for the most part.
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
I could try that, but I'm not exactly at expert level, and this article wasn't really geared toward PictureBox images... as a matter of fact, I don't think it covers dragging to Explorer to generate files at all.
Does anyone have any experience or knowledge about this specific problem?
As I sit here, I contemplate the last words of Socrates: "I drank what?".
|
|
|
|
|
You're not going to write a shell extension in VB, you need a real programming language for that (i.e. C++ )
Christian Graus
Please read this if you don't understand the answer I've given you. If you're still stuck, ask me for more information.
|
|
|
|
|
|
Dear Gents
I would like to write Microsoft certification exam in vb.net. But I dont have any idea about how to start.
Please let me know your comments how can i prepare(some websites providing materials) and how can i register for it, exam time schedule and more
Your reply will be high appreciable
Regards
Azeem
|
|
|
|
|
What kind of qualifications do you have for writing such exams? That could be of help in accessing what information you might need.
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
Actually I am working as a Application Support engineer and My basic Qualification is M.C.A(Master In Computer Application). So I have basic knowledge in vb.net. And wish to write Microsoft Certification exam in vb.net.
Pls help me to get proper guidelines.
Regards
Azeem
|
|
|
|
|
Ahamed Azeem wrote: My basic Qualification is M.C.A(Master In Computer Application). So I have basic knowledge in vb.net. And wish to write Microsoft Certification exam in vb.net.
That's nice and all, but you need more than an academic background. How about REAL industry experience? You cannot really write Microsoft Certification Exams without working with Microsoft. You could try but if you are not a Microsoft partner, I doubt people would want to take your test if it is not certified or okay'ed by Microsoft.
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
I thnk you mean you want to pass one ? That's easy, the web is full of guides. That's why those exams are worthless.
Christian Graus
Please read this if you don't understand the answer I've given you. If you're still stuck, ask me for more information.
|
|
|
|
|
Hi, How u r saying writing microsoft exams are worthless
Regards
Azeem
|
|
|
|
|
Quit the textspeak, like u and r. That is not appropriate.
Ahamed Azeem wrote: writing microsoft exams are worthless
No, why bother when the are multitudes of books written about it?
"The clue train passed his station without stopping." - John Simmons / outlaw programmer
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
helloI Have Question....
What write a Program that can the object or picture similar object1 object1
[IMG]http://i30.tinypic.com/24q5r7n.jpg[/IMG]
with analyze object2 place in object or picture similar object2
object2
[IMG]http://i25.tinypic.com/2a604nn.jpg[/IMG]
that can been minimize space of object2 .
?????????
Do you known sample code or you can help about this program.????
bye.
|
|
|
|
|
I see - you posted this three times. How rude...
Christian Graus
Please read this if you don't understand the answer I've given you. If you're still stuck, ask me for more information.
|
|
|
|
|
helloI Have Question....
What write a Program that can the object or picture similar object1 object1
[IMG]http://i30.tinypic.com/24q5r7n.jpg[/IMG]
with analyze object2 place in object or picture similar object2
object2
[IMG]http://i25.tinypic.com/2a604nn.jpg[/IMG]
that can been minimize space of object2 .
?????????
Do you known sample code or you can help about this program.????
bye.
|
|
|
|
|
Not much else to say. I need (well not need, but would like) to know how to set the sound level from a VB.NET application.
|
|
|
|
|