Skip to content
TheChatArchiveThe Chat Archive
Coherecommand-a-03-2025· CohereHugging Face LMArena Human Preference 140K

Hey, I want to use the windows bluetooth icon for a directory. Where does windows store…

From a Chatbot Arena battleThe same person sent this prompt to two anonymous models at once. Compare it with Claudeclaude-opus-4-20250514’s answer.
  1. User

    Hey, I want to use the windows bluetooth icon for a directory. Where does windows store the bluetooth icon?

  2. Cohere Assistant

    The Bluetooth icon in Windows is typically stored as a system resource within system files, and it's not directly accessible as a standalone image file (like .png or .ico) in a specific folder. However, you can extract or reference it using the following methods:

    1. Using the Shell Icon Overlay Identifiers

    • Windows uses a system of icon overlay handlers to display icons like Bluetooth. The Bluetooth icon is associated with specific files or devices via these handlers.
    • You can't directly copy the icon, but you can use it programmatically or via tools that understand these system resources.

    2. Extracting the Icon from System Files

    • The Bluetooth icon is often embedded in system DLLs or executables like imageres.dll, shell32.dll, or bluetooth.dll.
    • You can extract icons from these files using tools like:
    • Steps:
      1. Open the tool and load the DLL (e.g., C:\Windows\System32\imageres.dll).
      2. Look for the Bluetooth icon (you may need to check multiple DLLs).
      3. Extract it as an .ico file.

    3. Using PowerShell or Command Line

    • You can extract icons using PowerShell scripts or tools like ExtractIconEx in C#.
    • Example PowerShell script (requires admin rights):
      $iconIndex = 0  # Change this if needed
      $dllPath = "$env:SystemRoot\System32\imageres.dll"
      $savePath = "C:\BluetoothIcon.ico"
      [System.Drawing.Icon]::ExtractAssociatedIcon($dllPath, $iconIndex).ToBitmap().Save($savePath)
      

    4. Using the Windows Icon Cache

    • Windows caches icons in files like imageres.dll.mun or shell32.dll.mun in the C:\Windows\System32 folder, but these are binary and not directly usable.

    5. Download from Icon Packs

    • If extraction is too complex, you can find the Windows Bluetooth icon in icon packs or online repositories that mimic Windows system icons.

    Example Location (if found in a DLL):

    C:\Windows\System32\imageres.dll
    

    Let me know if you need help with extraction tools or scripts!

  3. User

    imageres does not seem to be the correct one. What other dll should I look at?

  4. Cohere Assistant

    You're right, imageres.dll might not contain the Bluetooth icon in all Windows versions. Here are other system DLLs and files where the Bluetooth icon could be located:

    1. Shell32.dll

    • Location: C:\Windows\System32\shell32.dll
    • This DLL contains many system icons, including some related to devices and connectivity.

    2. Bluetooth.dll

    • Location: C:\Windows\System32\bluetooth.dll
    • This DLL is specifically related to Bluetooth functionality and is a likely candidate for the Bluetooth icon.

    3. Morphing.dll

    • Location: C:\Windows\System32\morphing.dll
    • Contains icons for various system features, including some device-related icons.

    4. Pifmgr.dll

    • Location: C:\Windows\System32\pifmgr.dll
    • Contains icons for older system features but might still be worth checking.

    5. Sysdm.cpl

    • Location: C:\Windows\System32\sysdm.cpl
    • Contains icons related to system properties and devices.

    6. Wlanapi.dll or Wlanui.dll

    • Location: C:\Windows\System32\wlanapi.dll or C:\Windows\System32\wlanui.dll
    • While primarily for Wi-Fi, these might contain related connectivity icons.

    7. Windows Icon Cache Files

    • Location: C:\Users\[YourUsername]\AppData\Local\IconCache.db
    • These files cache icons, but extracting them requires specialized tools.

    Steps to Find the Icon:

    1. Use a tool like Resource Hacker, IcoFX, or PE Explorer to open these DLLs.
    2. Look for the Bluetooth icon in the icon groups (usually under the "Icon" section).
    3. Extract the icon as an .ico file.

    Example for bluetooth.dll:

    1. Open bluetooth.dll in Resource Hacker.
    2. Navigate to the "Icon" group.
    3. Look for the Bluetooth icon (it might be labeled or have a distinct appearance).
    4. Right-click and extract it.

    If you're still unable to find it, let me know, and I can suggest alternative methods or tools!

  5. User

    Can I check for a given library which Icon is in use currently?

  6. Cohere Assistant

    Yes, you can determine which icon is currently in use from a specific library (DLL or executable) by examining the system's icon resources and their associations. Here’s how you can do it:


    Methods to Identify the Icon in Use

    1. Use Resource Viewer Tools

    Tools like Resource Hacker, PE Explorer, or IcoFX allow you to inspect the icon resources embedded in a DLL or EXE file. Here’s how:

    • Open the DLL (e.g., bluetooth.dll, shell32.dll) in the tool.
    • Navigate to the Icon section.
    • Compare the icons visually or by their index to identify the one in use.

    2. Check System Icon Indices

    Windows uses icon indices to reference icons in system DLLs. You can use tools or scripts to map these indices to specific icons.

    • PowerShell Script to List Icons in a DLL:

      Add-Type -AssemblyName System.Drawing
      $dllPath = "C:\Windows\System32\bluetooth.dll"
      $icons = [System.Enum]::GetValues([System.IntPtr]) | ForEach-Object { [System.Drawing.Icon]::ExtractAssociatedIcon($dllPath, $_) }
      $icons | ForEach-Object { $_.ToBitmap() }
      

      This script extracts all icons from the DLL and displays them as bitmaps.

    • Command-Line Tool: iconview.exe

      • Download IconViewer from NirSoft.
      • Run it with the DLL path to view all icons:
        iconview.exe "C:\Windows\System32\bluetooth.dll"
        

    3. Monitor Icon Usage with Debugging Tools

    Use tools like Process Monitor (from Sysinternals) or API Monitor to track when and how icons are loaded by the system.

    • Filter for processes like explorer.exe and monitor calls to LoadIcon or LoadImage.
    • Look for references to the DLL and icon index being used.

    4. Check the Windows Registry

    Some icon associations are stored in the registry. For Bluetooth, check:

    HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Shell Icons
    

    Look for entries related to Bluetooth devices or connectivity.

    5. Use the Windows Icon Cache

    Windows caches icons in files like IconCache.db in the user profile directory. You can decode this file using tools like IconCacheRebuilder to see which icons are in use.

    6. Extract the Bluetooth Icon Directly

    If you’re specifically looking for the Bluetooth icon, try these DLLs first:

    • bluetooth.dll
    • shell32.dll
    • imageres.dll

    Use a tool like Resource Hacker to extract the icon by its index or visual appearance.


    Example Workflow

    1. Open bluetooth.dll in Resource Hacker.
    2. Go to the Icon group.
    3. Look for the Bluetooth icon (usually a distinct blue or white symbol).
    4. Note the icon index (e.g., 0, 1, 2, etc.).
    5. Extract the icon as an .ico file.

    Alternative: Use System Files Directly

    If you’re using the icon for a directory, you can directly reference the DLL and icon index in the folder’s properties:

    1. Right-click the folder > Properties.
    2. Click Customize > Change Icon.
    3. Browse to the DLL (e.g., C:\Windows\System32\bluetooth.dll).
    4. Select the Bluetooth icon and apply it.

    Let me know if you need further assistance!

  7. User

    No I do not care for the bluetooth related one. I have created a custom Bibliothek and gave that an Icon - no I want to know the location of the icon since I cannot remember

  8. Cohere Assistant

    Got it! If you’ve created a custom library (e.g., a DLL or executable) and assigned it an icon, the icon is typically embedded within that file itself. Here’s how you can locate and extract it:


    Steps to Find and Extract Your Custom Icon

    1. Identify the File Containing the Icon

    • Locate the custom DLL, EXE, or library file you created. For example, if your custom library is named MyCustomLibrary.dll, this is the file you need to inspect.

    2. Use Resource Viewer Tools

    3. Extract the Icon

    • Here’s how to do it with Resource Hacker:
      1. Open Resource Hacker.
      2. Click File > Open and select your custom library file (e.g., MyCustomLibrary.dll).
      3. In the left pane, expand the tree and look for the Icon group.
      4. Select the icon you want to extract (it’s usually the only one or labeled clearly).
      5. Right-click the icon and choose Save Resource.
      6. Save it as an .ico file to your desired location.

    4. Alternative: Use PowerShell or .NET

    • If you’re comfortable with scripting, you can extract the icon programmatically using PowerShell or C#. Here’s a PowerShell example:
      Add-Type -AssemblyName System.Drawing
      $dllPath = "C:\Path\To\MyCustomLibrary.dll"
      $iconIndex = 0  # Change if necessary
      $icon = [System.Drawing.Icon]::ExtractAssociatedIcon($dllPath, $iconIndex)
      $icon.ToBitmap().Save("C:\Path\To\ExtractedIcon.ico")
      

    5. Check the Project Files

    • If you still have the project files for your custom library, look for the icon file in your project directory. It’s often included as an external resource (e.g., .ico, .png, or .bmp file).

    6. Use File Explorers with Icon Preview

    • Some file explorers (like Everything or XYplorer) allow you to preview icons embedded in files. Browse to your custom library file and check if the icon is displayed.

    Example Scenario

    If your custom library is MyCustomLibrary.dll and you used an icon named MyIcon.ico during development:

    1. Open MyCustomLibrary.dll in Resource Hacker.
    2. Look for the MyIcon.ico resource under the Icon group.
    3. Extract it to a new location.

    If you’re still unable to locate the icon, provide more details about the custom library (e.g., programming language, development environment), and I can offer more specific guidance!

  9. User

    If I open the name.library-ms file with text editor I get:

  10. Cohere Assistant

    The library-ms file you’re viewing is an XML-based file that defines a Windows Library. It doesn’t directly store the icon itself but references it via the <iconStream>DefaultIcon1</iconStream> tag. Here’s how to interpret and locate the icon:


    Understanding the Icon Reference

    • The <iconStream>DefaultIcon1</iconStream> tag indicates that the library is using a default icon or an icon specified by the system or the library's configuration.
    • The icon is not embedded in the library-ms file. Instead, it’s either:
      1. A system-provided icon (e.g., from a DLL like imageres.dll or shell32.dll).
      2. A custom icon specified when the library was created or modified.

    How to Find the Icon

    1. Check System DLLs for Default Icons

    If the icon is a default system icon, it’s likely stored in one of these DLLs:

    • imageres.dll
    • shell32.dll
    • bluetooth.dll
    • morphing.dll

    Use a resource viewer tool (e.g., Resource Hacker, IcoFX) to inspect these DLLs and find the icon.

    2. Check the Library’s Folder for Custom Icons

    If you used a custom icon when creating the library, it might be stored in the same folder as the library-ms file or in a subfolder. Look for .ico files in the directory.

    3. Use the Library’s Properties

    1. Open File Explorer.
    2. Right-click the library (e.g., in the Navigation Pane).
    3. Select Properties.
    4. Go to the Customize tab.
    5. Click Change Icon.
    6. Note the icon file path or DLL and icon index being used.

    4. Use PowerShell to Inspect the Library

    You can use PowerShell to inspect the library’s icon:

    $libraryPath = "C:\Path\To\YourLibrary.library-ms"
    $library = New-Object -ComObject Shell.Application
    $libraryItem = $library.NameSpace($libraryPath).Self
    $iconPath = $libraryItem.ExtendedProperty("DefaultIcon1")  # Adjust the property name if needed
    Write-Output "Icon Path: $iconPath"
    

    5. Check the Registry (Advanced)

    Some library icon settings are stored in the registry. Look under:

    HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Libraries
    

    or

    HKLM\Software\Microsoft\Windows\CurrentVersion\Explorer\Libraries
    

    If the Icon Is Custom

    If you used a custom icon when creating the library:

    1. Open the folder where the library-ms file is located.
    2. Look for .ico files in the same directory or subfolders.
    3. If the icon is embedded in a DLL or EXE, use a resource viewer tool to extract it.

    Example: System Icon

    If the icon is a system icon (e.g., from imageres.dll), follow these steps:

    1. Open Resource Hacker and load C:\Windows\System32\imageres.dll.
    2. Navigate to the Icon group.
    3. Look for the icon matching your library.
    4. Extract it as an .ico file.

    If you still can’t find the icon, let me know more details (e.g., how you created the library, if you used a custom icon), and I’ll help further!

Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.