msillano Posts: 7
04/12/2021
|
A CLSID is a universal unique identifier (UUID) used by Microsoft to identify a COM class object, and the CLSID known by Windows are stored in registry at [HKEY_CLASSES_ROOT\CLSID]. The 128 bit (16 byte) UUID implementation by Microsoft is called also GUID, and the GUID standard form is {4-2-2-2-6} byte HEX.
Using the CLSID you can access special virtual folders or virtual applets. In some cases, CLSID provides access to physical folders on the hard drive or even special operating system features such as "Minimize All Windows" or the Alt + Tab switcher. The CLSIDs give you the control over many Windows operations in fast mode, i.e. creating desktop shortcuts or new items in SyMenu and so bypassing the slow "Control Panel" or all the steps required by 'how-to' instructions.
The SyMenu user has so the power to destructure the native Windows logical organization, and to rebuild new control structures in SyMenu, more functional to their needs and preferences.
howto: test CLSIDs
1) Quick and dirty way to test a CLSID is using the Windows 'Run' dialog: Press Win+R keys on your keyboard, then copy and paste the command, using the CLSID under test: shell:::{CLSID}
Notes: - Using the shell, we can also use a 'shell command' as parameter: i.e. a mnemonic replacement (friendly name) defined for some CLSID:
shell:Fonts - In some cases shell:command works and shell:::{CLSID} not, or viceversa. Better to try both if possible.
2) At the command prompt (in cmd) it is necessary to add 'explorer' or 'explorer.exe' or '%SystemRoot%\explorer.exe', using this: explorer shell:::{CLSID} or this: explorer /e, ::{CLSID}
Notes: - Sometimes the CLSID will only work using one and not the other command above.
3) Windows PowerShell consists of command line shell and scripting language. Also using PowerShell you can use shell commands or CLSIDs. Examples:
Open printers folder: Start-Process shell:PrintersFolder or: &{explorer.exe 'shell:::{21ec2020-3aea-1069-a2dd-08002b30309d}\::{2227a280-3aea-1069-a2de-08002b30309d}'}
Open Devices and printers: &{explorer.exe 'shell:::{A8A91A66-3A7D-4424-8D24-04E180695C7A}'} or even so: cmd.exe --% /c Explorer shell:::{A8A91A66-3A7D-4424-8D24-04E180695C7A}
More PowerShell examples:
- This list all Special Folders names:
[Environment+SpecialFolder]::GetNames([Environment+SpecialFolder])
- This last example returns the real path of Desktop:
[Environment]::GetFolderPath([Environment+SpecialFolder]:esktop) howto: use CLSIDs in shortcuts
Making a shortcut to a special folder allows us to have a quick link from the desktop or from anywhere, to the required feature of Windows.
4) Create a new shortcut (on your desktop or wherever you like) in the usual way, but use for "Type the position of the Item": explorer.exe shell:::{CLSID} Add a meaningful name and create it. Re-edit the shortcut properties to change the icon however you like.
5) A different way to get same result: goto where you wont to create a shorcut, but create instead a directory, and give it the a name with the CLSID of the target as extension: yourFolderDisplayName.{CLSID} Note:
- with god mode (all Tasks) the displayName becomes empty. Known issue.
6) You can also use a file BAT as shortcut, the content can be: :: Sample Batch Script to open the Action Center via CLSID shell @echo off %SystemRoot%\explorer shell:::{BB64F8A7-BEE7-4E1A-AB8D-7D8273F7FDB6} exit Of course, you can use CLSIDs in any BAT file, to implement automation tasks involving Windows.
Note:
- Also in BAT you have 3 alternatives, try them all:
explorer shell:command explorer shell:::{CLSID} explorer /e, ::{CLSID}
7) If you are really lazy, you can use a nice, well documented program: Winaero Tweaker to build your own shortcuts. It allows you to test CLSID commands and to create Shortcut with just 2 clicks.
howto: use CLSIDs with SyMenu
8) If the CLSID points to a Directory, we can use 'Add link to folder' in configuration, and: - show the directory content as cascading submenus
- swow it in a new file explorer window (option 'Show as Link' = yes).
Note: - You can use here all the 'virtual folder' parametric path from the program 'Special FolderView' (in NirSoft suite). Example:
- This example is extracted from SyMenuItem.xml to avoid typos. The '<guid>' you see is used as a unique record key in the sqlite DB, used internally by SyMenu, nothing to do with Microsoft GUIDs.
9) Using 'Add Program' in configuration you get a new window. The Path is always the same:
%SystemRoot%\explorer.exe As parameter you can use: - directly a directory (parametric, real or virtual)
- or one of the usual alternatives, one that works:
shell:command shell:::{CLSID} /e, ::{CLSID} Examples:
howto: a more complex example The standard option 'My Computer' in SyMenu presents me some problems: . - 'Host programs', in WIN11, don't found the Microsoft 'apps' (Photos, Calculator etc.)
- 'Host programs' submenu is too long.
- 'Contol panel' can be replaced by 'God mode'
- The menu shows some removables drives (H:, K:) even if the drives are not in place.
- The full HD navigation via submenu to found executables is time consuming and too big on desktop.
- The SyMenu Link implementation finds only some fixed file type, miss empty dirs, and always forces you to traverse all the paths until a final file. It cannot be stopped at an intermediate dir (eg. Clicking on a dir in a submenu, to open an instance of file explorer on that dir).
I don't care: what I like about SyMenu is the flexibility! With CLSIDs I can create my own implementation of "This PC" to suit my needs and replace the standard "My Computer".
- Explore recents link opens the dir %APPDATA%\Microsoft\Windows\Recent. Any kind of files, so Link=true.
- Programs uses the CLSID {4234d49b-0245-4df3-b780-3893943456e1} (Applications).
This is the unique way I found in WIN11 to access installed applications (Start menu) AND Microsoft apps (like StickyNotes, Calculator, etc.). - God mode uses the CLSID {ED7BA470-8E54-465E-825C-99712043E01C} (all tasks)
- C: D: Z: they are links (links = true) that do not point to the root of the disks, but directly to the folders of interest.
- PROJECTS presents some useful items for quick access.
- Since I am now installing my new PC, the last 4 items are related to program management. WinUnistall uses the CLSID {7b81be6a-ce2b-4676-a29e-eb907a5126c5}
References - For a general start point I found interesting this article
- For more information about the CLSID key and the function of it's subkeys in the registry, see Microsoft 'CLSID Key (COM)'
- For Windows 11 CLSIDs and 'shell commands' click here
- For Windows 10 CLSIDs and 'shell commands' click here
- All CLSIDs on your computer can be fund using ShellExView program (NirSoft suite)
- All special folders on your computer can be fund using SpecialFolderView program (NirSoft suite)
- For your convenience a list of CLSIDs (WIN10) is added as atthach. Format as OpenOffice spreadsheet, so you can edit it.
edited by msillano on 04/12/2021
edited by msillano on 04/12/2021
edited by msillano on 05/12/2021
|