Much less me...
It is currently January 27th, 2021, 1:19 am
Recycle Bin context menu
-
- Rainmeter Sage
- Posts: 12112
- Joined: October 11th, 2010, 6:27 pm
- Location: Gheorgheni, Romania
-
- Posts: 908
- Joined: December 30th, 2015, 9:47 am
Re: Recycle Bin context menu
Hi Yincognito and balala
I just thank you for taking time to talk with me, even if my aim wasn't achieved so far.
BTW, as the FileView plugin has [!CommandMeasure SomeMeasure ContextMenu] command (and even Properties!), I assume that the plugin uses some API that calls context menu for file path. If so, RecycleManager measure also can use such API for the integrated RecycleBin and implement similar measure command? ... just my thought, but expect.
I just thank you for taking time to talk with me, even if my aim wasn't achieved so far.

BTW, as the FileView plugin has [!CommandMeasure SomeMeasure ContextMenu] command (and even Properties!), I assume that the plugin uses some API that calls context menu for file path. If so, RecycleManager measure also can use such API for the integrated RecycleBin and implement similar measure command? ... just my thought, but expect.
-
- Posts: 2980
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Recycle Bin context menu
But isn't the context menu of the Recycle Bin desktop icon entirely different from the context menu of a $Recycle.Bin folder?mak_kawa wrote: ↑October 15th, 2020, 10:00 pm Hi Yincognito and balala
I just thank you for taking time to talk with me, even if my aim wasn't achieved so far.
BTW, as the FileView plugin has [!CommandMeasure SomeMeasure ContextMenu] command (and even Properties!), I assume that the plugin uses some API that calls context menu for file path. If so, RecycleManager measure also can use such API for the integrated RecycleBin and implement similar measure command? ... just my thought, but expect.

-
- Posts: 2980
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Recycle Bin context menu
I think I may have the answer for you, mak_kawa - you know my motto, nothing is impossible.


P.S. It won't open the context menu of Recycle Bin or its properties, but it will do pretty much everything available in the properties window.
EDIT:
I'll be a bit busy tomorrow, so I'll just show you how to do it:
- use either: mountvol /L (in either CMD or PowerShell), WMIC or a PowerShell command like:
Code: Select all
gwmi -class Win32_Volume -filter "NOT DriveLetter like ''" | select DriveLetter,DeviceID | sort DriveLetter | format-list
- once you get the GUID, the registry path of the Recycle Bin settings for your drive will be:
Code: Select all
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\BitBucket\Volume\{GUID}
- to be able to modify those settings, use a PowerShell code like (this sets the maximum storage size of Recycle Bin for C: drive to 5000 MB):
Code: Select all
$Size=5000
$Volume=mountvol C:\ /L
$Guid=[regex]::Matches($Volume,'{([-0-9A-F].*?)}')
$RegKey="HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\BitBucket\Volume\"+$Guid.value
New-ItemProperty -Path $RegKey -Name MaxCapacity -Value $Size -PropertyType "dword" -Force
All in all, if there is a "complicated" part, it's extracting the GUID(s) from the mountvol or gwmi output, but even that isn't that hard if carefully designing the regex. Naturally, you can even replicate the Recycle Bin Properties window in a small skin, if you like - some InputTexts and buttons should do the job, considering that you can already get the current values of those settings using some Registry measures, and the set part is clear.
If you want to implement this and encounter difficulties and such, feel free to use your constitutional right to reply on this forum, LOL. Oh, and yeah, now you can say thanks. The approach is not exactly as easy as envisioned with just a simple CLSID in a bang, but it isn't a whole lot complicated either, and it should work. Obviously, you should first make sure everything goes smooth by running whatever is needed to test this from CMD or PowerShell, and make a backup of the registry before attempting to modify it, just to be on the safe side.
-
- Moderator
- Posts: 629
- Joined: February 16th, 2012, 3:32 am
Re: Recycle Bin context menu
System.Shell.RecycleBin.showRecycleSettings 
--------
Also, is there a way to run a clsid with a "property"? or check them out and try launching in some way:
----------
Apart from the window class which is called#32770 I haven't found anything else :/
--------
Also, is there a way to run a clsid with a "property"? or check them out and try launching in some way:
Code: Select all
HKCR\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\ControlPanel
Code: Select all
HKCU\Software\Classes\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\shellex\PropertySheetHandlers
Code: Select all
HKCR\CLSID\{645FF040-5081-101B-9F08-00AA002F954E}\{28636AA6-953D-11D2-B5D6-00C04FD918D0} 6
Apart from the window class which is called#32770 I haven't found anything else :/
-
- Posts: 233
- Joined: September 7th, 2020, 2:24 pm
Re: Recycle Bin context menu
There are only three options in the recycle bin menu, really: open, empty, and pin to taskbar - unless you have some other programs linked to it like CCleaner.
There is a lot of stuff about running batch files for each separate option, but not the native menu.
Perhaps creating a context menu that runs individual batch files for each option, named in kind just through rainmeter context menu...
There is a lot of stuff about running batch files for each separate option, but not the native menu.
Perhaps creating a context menu that runs individual batch files for each option, named in kind just through rainmeter context menu...
Can't fix it if it ain't broke - unless it is in code.
-
- Posts: 2980
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Recycle Bin context menu
Something like that, yeah. As far as I am aware of, one of the few ways of accessing the options from the Recycle Bin properties (i.e. the ones setting the size of the bin and such) is to build a skin simulating that properties window, and then modify those options by changing the registry keys I talked about earlier. Of course, one can do that through the skin's context menu as well.CodeCode wrote: ↑October 21st, 2020, 8:47 am There are only three options in the recycle bin menu, really: open, empty, and pin to taskbar - unless you have some other programs linked to it like CCleaner.
There is a lot of stuff about running batch files for each separate option, but not the native menu.
Perhaps creating a context menu that runs individual batch files for each option, named in kind just through rainmeter context menu...
-
- Posts: 233
- Joined: September 7th, 2020, 2:24 pm
Re: Recycle Bin context menu
Of course... Properties. I didnt include that one. Sorry. Looking around though and I did not see any reference to that in the batch file perspective so back to Yincognito's idea then.Yincognito wrote: ↑October 21st, 2020, 12:15 pm Something like that, yeah. As far as I am aware of, one of the few ways of accessing the options from the Recycle Bin properties (i.e. the ones setting the size of the bin and such) is to build a skin simulating that properties window, and then modify those options by changing the registry keys I talked about earlier. Of course, one can do that through the skin's context menu as well.
Can't fix it if it ain't broke - unless it is in code.