473,574 Members | 2,921 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Get list of clickable objects on the desktop

I need to get a list of clickable objects on the desktop and their
positions.
I have written a small program in C# and by using the Win32 function:
WindowFromPoint -function I get a handle to the desktop but now I'm
stuck.

For those who need to see the code -look below
IntPtr hWnd = Win32.WindowFro mPoint(Cursor.P osition);

With the handle I can get alot of cool information such as: Caption,
Class and Rect but that's not what I need...!

Now what?

Regards Henrik

Feb 13 '06 #1
3 4747
Henrik,
Its not entirely clear what you need to get from the Desktop items. Have you
tried simply iterating through the shortcuts in the SpecialFolders Desktop
folder? The lines in each shortcut file tell a lot about what and where.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"Henrik" wrote:
I need to get a list of clickable objects on the desktop and their
positions.
I have written a small program in C# and by using the Win32 function:
WindowFromPoint -function I get a handle to the desktop but now I'm
stuck.

For those who need to see the code -look below
IntPtr hWnd = Win32.WindowFro mPoint(Cursor.P osition);

With the handle I can get alot of cool information such as: Caption,
Class and Rect but that's not what I need...!

Now what?

Regards Henrik

Feb 13 '06 #2
Thanks for the quick reply.
What I'm looking for is the place Windows registers shortcuts and
buttons that's why I think I need the handle. If Windows knows that
the object under the mouse is clickable I want to know if the object is
clickable as well. That's why I want a list or so with all available
information of the specific window.

For a start the shortcuts on the Desktop is ok. Could you please give
an example of using the SpecialFolder function? -The documentation of
the function isn't really good...
Peter Bromberg [C# MVP] skrev:
Henrik,
Its not entirely clear what you need to get from the Desktop items. Have you
tried simply iterating through the shortcuts in the SpecialFolders Desktop
folder? The lines in each shortcut file tell a lot about what and where.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"Henrik" wrote:
I need to get a list of clickable objects on the desktop and their
positions.
I have written a small program in C# and by using the Win32 function:
WindowFromPoint -function I get a handle to the desktop but now I'm
stuck.

For those who need to see the code -look below
IntPtr hWnd = Win32.WindowFro mPoint(Cursor.P osition);

With the handle I can get alot of cool information such as: Caption,
Class and Rect but that's not what I need...!

Now what?

Regards Henrik


Feb 13 '06 #3
"F1" is your friend:
http://msdn.microsoft.com/library/de...rpathtopic.asp

Cheers,
Peter
--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"Henrik" wrote:
Thanks for the quick reply.
What I'm looking for is the place Windows registers shortcuts and
buttons that's why I think I need the handle. If Windows knows that
the object under the mouse is clickable I want to know if the object is
clickable as well. That's why I want a list or so with all available
information of the specific window.

For a start the shortcuts on the Desktop is ok. Could you please give
an example of using the SpecialFolder function? -The documentation of
the function isn't really good...
Peter Bromberg [C# MVP] skrev:
Henrik,
Its not entirely clear what you need to get from the Desktop items. Have you
tried simply iterating through the shortcuts in the SpecialFolders Desktop
folder? The lines in each shortcut file tell a lot about what and where.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"Henrik" wrote:
I need to get a list of clickable objects on the desktop and their
positions.
I have written a small program in C# and by using the Win32 function:
WindowFromPoint -function I get a handle to the desktop but now I'm
stuck.

For those who need to see the code -look below
IntPtr hWnd = Win32.WindowFro mPoint(Cursor.P osition);

With the handle I can get alot of cool information such as: Caption,
Class and Rect but that's not what I need...!

Now what?

Regards Henrik


Feb 13 '06 #4

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

Similar topics

5
2321
by: bob_smith_17280 | last post by:
How many items can be stored in a Python list? I have close to 70,000 items... is this within a lists limits?
53
4928
by: Kerberos | last post by:
I followed Dan Cederholm's image replacement tutorial, to replace a header tag by a logo. The h1 is clickable if no CSS is applied but it I replace it by the logo, the area isn't clickable anymore when I pass the mouse over the logo. Is there a way to replace a link by an image that will still be clickable? Thanks, -- Kerberos.
3
372
by: RCCNH | last post by:
I am creating a Windows application using C# in .NET. In one of the windows, I have to show a scrollable list of user objects. Those user objects contain various controls themselves (textbox, buttons, etc) and are all of the same type of user object - just showing different data. In this case, each one is a "question" being presented that...
3
2896
by: mallyonline | last post by:
Thank you for your previous help. I posted regarding listing the names of files held in a folder on the server and making the list appear clickable. This has now been accomplished. The files are listed - The files are clickable -
19
4235
by: Ross A. Finlayson | last post by:
Hi, I hope you can help me understand the varargs facility. Say I am programming in ISO C including stdarg.h and I declare a function as so: void log_printf(const char* logfilename, const char* formatter, ...); Then, I want to call it as so:
16
13554
by: Brian D | last post by:
I have a multiple select list that is created dynamically based on a previous selection on an asp page. The first thing I do is to clear the curent option list by document.form1.itemcross.length = 0; The only problem is that it leaves the optgroups. How do I also get rid of the optgroups? Thanks
15
4127
by: desktop | last post by:
If I have a sorted std::list with 1.000.000 elements it takes 1.000.000 operations to find element with value = 1.000.000 (need to iterator through the whole list). In comparison, if I have a std::set with 1.000.000 element it will only take approx lg 1.000.000 = 20 operations! Can it really be true that the difference is a factor of...
3
5552
by: crazychrisy54 | last post by:
Hi there I just wondered if there is any way using GD to insert a clickable button or some clickable text into a image? It is possible to create images for buttons but what if you want a clickable button *inside* another image. I don't know if this is along the right lines but the following code puts a image inside another image. Perhaps...
0
30193
AmberJain
by: AmberJain | last post by:
Windows Autorun FAQs: List of autostart locations Linked from the Original article- "Windows Autorun FAQs: Description". Que: Can you list all the autostart locations for windows? Ans: Here is a comprehensive list of all autostart locations for Windows OSes: NOTE : These are some abbreviations used in this list. Please note them...
0
7835
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
8095
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7847
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
8132
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6500
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
5332
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3769
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3787
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1365
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.