Hotkey to sort images by Rating/Descending

Get help with using AutoHotkey and its commands and hotkeys
reverberation
Posts: 84
Joined: 13 Dec 2015, 20:48

Hotkey to sort images by Rating/Descending

25 Dec 2016, 00:03

Hi guys,

I just encountered a very annoying issue. By default, when we right click and Sort, I have to add "Rating" as the criteria for sorting, before I can proceed to sort by descending order for the folder. This applies to every new folder that I have to sort.

How can I program in AHK such that it auto-sorts by Rating (or Date Taken), descending order whenever there's a folder with predominantly (>80%) images (RAW, .ARW, .JPG, .PNG)?
ManualColdLock
Posts: 175
Joined: 15 Dec 2016, 04:27

Re: Hotkey to sort images by Rating/Descending

04 Feb 2017, 00:29

what program are you using?
Can you be more specific about pretty much everything?
User avatar
boiler
Posts: 2374
Joined: 21 Dec 2014, 02:44

Re: Hotkey to sort images by Rating/Descending

04 Feb 2017, 17:21

He's referring to the standard Windows File Explorer. Knowing that, his question is complete as stated.
User avatar
jeeswg
Posts: 5939
Joined: 19 Dec 2016, 01:58
Location: UK

Re: Hotkey to sort images by Rating/Descending

04 Feb 2017, 20:28

method 1 (e.g. Windows 7) change folder settings, hotkey to sort each time:
- set which columns appear in a folder
'alt, View, Customize this folder...', to get the folder's type,
(i.e. General Items/Documents/Pictures/Music/Videos)
Add in the columns you want manually.
'alt, Tools, Folder options..., View tab, Apply to Folders'
Now all folders of the same type will have the additional column(s).
- invoke sort by column every time you need it

Code: Select all

q:: ;sort files by column
ControlGet, hCtl, Hwnd,, DirectUIHWND3, A
oAcc := Acc_Get("Object", "4.1", 0, "ahk_id " hCtl)
for _, oChild in Acc_Children(oAcc)
	if (oChild.accName(0) = "Name")
	{
		oChild.accDoDefaultAction(0)
			break
	}
return
method 2 create a custom folder window GUI (easier than it sounds):
- create a listview in a GUI, list the files
(for completeness, find a script to invoke a file's right-click context menu)
ListView (GUI)
https://autohotkey.com/docs/commands/Li ... m#Examples
- get the special properties of a file (e.g. see JEE_FileGetAttrib)
jeeswg's script snippets - AutoHotkey Community
https://autohotkey.com/boards/viewtopic ... 39#p130039

There was a lot to check over, which is why it took me a while.
Hope that helps.
Last edited by jeeswg on 04 Oct 2018, 14:08, edited 1 time in total.
homepage | tutorials | wish list | fun threads | donate
WARNING: copy your posts/messages before hitting Submit as you may lose them due to CAPTCHA
ManualColdLock
Posts: 175
Joined: 15 Dec 2016, 04:27

Re: Hotkey to sort images by Rating/Descending

05 Feb 2017, 16:12

This is very interesting, my context menu does not require it at all. I Just get sort by and can choose all the normal sorting options. so either I'm not understanding the situation or I've already fixed the problem?
Attachments
sort menu.jpg
sort menu.jpg (24.6 KiB) Viewed 984 times
4GForce
Posts: 553
Joined: 25 Jan 2017, 03:18
GitHub: 4GForce

Re: Hotkey to sort images by Rating/Descending

05 Feb 2017, 22:42

ManualColdLock wrote:This is very interesting, my context menu does not require it at all. I Just get sort by and can choose all the normal sorting options. so either I'm not understanding the situation or I've already fixed the problem?
Try adding an extra column within Sort by > More > ...
Then open a new explorer and see if that column is there ?

If you don't save the settings new instances of explorer won't display it.
F10 > Tools > Folder options... > View > Apply to Folders

Edit : Win7 as far as Im concerned
ManualColdLock
Posts: 175
Joined: 15 Dec 2016, 04:27

Re: Hotkey to sort images by Rating/Descending

06 Feb 2017, 04:36

Try adding an extra column within Sort by > More > ...
Then open a new explorer and see if that column is there ?

If you don't save the settings new instances of explorer won't display it.
F10 > Tools > Folder options... > View > Apply to Folders
I did this sucessfully, with no problems.
Win 7 64-bit.

I have several windows features turned off.
Notably "windows indexing" is turned off, that may be responsible for the difference?

Return to “Ask For Help”

Who is online

Users browsing this forum: Albireo, Bing [Bot], electrified, electrone77, euras, Google [Bot], MannyKSoSo, sinkfaze and 66 guests