🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #5810

Re: Retriving Default Icons.

#5810
From: qyte
Date: Mon, 04 Jul 2005 11:54
33 lines
1998 bytes
Remy Lebeau (TeamB) wrote:
> "qyte" <gyte@vivodinet.gr> wrote in message
> news:42c895fd$1@newsgroups.borland.com...
> 
> 
>>Is there a way to find out what is the default icon
>>for Hard Disks But especially for CDROM drives?
> 
> 
> SHGetFileInfo(), specifying the specific drive that you are interested in.
> 
>     SHFILEINFO sfi = {0};
>     HIMAGELIST hSystemImageList = (HIMAGELIST) SHGetFileInfo(TEXT("D:\\"),
> DWORD dwFileAttributes, &sfi, sizeof(sfi), SHGFI_ICON |
> SHGFI_SHELLICONSIZE);
>     if( hSystemImageList != NULL )
>     {
>         // use sfi.hIcon as needed...
>         DestroyIcon(sfi.hIcon);
>     }
> 
> 
> Gambit
> 
> 


the problem is that i want the icon for in order to
display a disk not inside my computer but let's say someone
else's inside a file sharing program. I therefore want to find which
is the default icon for Hard Disks and CD-ROMs. just like using
FILE_ATTRIBUTE_NORMAL with SHGFI_USEFILEATTRIBUTES.
But this does not work.
Technical Details
Message-ID: <42c92369$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news4.google.com!news.glorb.com!news-out.nntp.be!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail
References: <42c895fd$1@newsgroups.borland.com> <42c8afe4@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,499570fe4a26e674
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
Date: Mon, 04 Jul 2005 14:54:14 +0300
From: qyte <gyte@vivodinet.gr>
User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317)
X-Accept-Language: en-us, en
MIME-Version: 1.0
Newsgroups: borland.public.cppbuilder.nativeapi
Subject: Re: Retriving Default Icons.
References: <42c895fd$1@newsgroups.borland.com> <42c8afe4@newsgroups.borland.com>
In-Reply-To: <42c8afe4@newsgroups.borland.com>
Content-Type: text/plain; charset=windows-1253; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 83.171.210.195
Message-ID: <42c92369$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1120478057 83.171.210.195 (4 Jul 2005 04:54:17 -0700)
Lines: 33
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news4.google.com!news.glorb.com!news-out.nntp.be!propagator2-sterling.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail