Archived

This topic is now archived and is closed to further replies.

placing an icon on the desktop?

This topic is 5145 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

how would I place an icon on the desktop without going through any setup program. Just one exe that when run places an icon on the desktop. My guess is somehow getting the user directory and then going into the desktop folder. However this would also have to work on anything Win98 and up, not just 2000 and XP. Preferably some C/C++ code, VB6 fine too I guess, maybe Delphi if I don''t need install some runtime library. Tutorial? Thanks

Share this post


Link to post
Share on other sites
Place an "icon" on the desktop? You need to speak in more accurate terms, unless you want me to confuse you with the 40 year who has trouble with double click and wants help with the "icons on her screen going funny".

Do you mean a shortcut, a file, an icon file, a desktop extension (like how Internet Explorer and some other apps can appear as static icons). All of those can be done with a simple exe. The desktop directory is a common directory, which means you can access it with the SHGetSpecialFolderLocation function (use CSIDL_DESKTOP as the second parameter). Extensions and creating shortcuts is something harder (one requiring COM, the other requiring some registry surgery)

Share this post


Link to post
Share on other sites

lol, sorry I sounded so confusing.

Basically what I need is when an exe is run a shortcut will appear on the user desktop. Shortcut to an internet site most likely.

The shortcut will need a custom icon


So how would I do that?


Thanks

Share this post


Link to post
Share on other sites