Use the power of Everything in Explorer and File dialogs

General discussion related to "Everything".
Post Reply
NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Use the power of Everything in Explorer and File dialogs

Post by NotNull » Fri Feb 16, 2018 2:56 pm

EDIT: Reworked version can be found here





There was a (good, imho) suggestion on these forums to extend the Save/Open dialog boxes with Everything-powers (see viewtopic.php?t=6406 ).

That idea stuck in my mind and it looked like a good candidate to use to learn myself some Autohotkey programming.
This is the first draft (proof of concept) and has only a few of the intended options "programmed".
This is how version 0.0.2 works:


[*] When in a File Open / File Save / ... file dialog (Microsoft calls those Common File Dialog (Winversion < Vista) or Common Item Dialog (from Vista on)), click on the scrollwheel of the mouse somewhere in the "big red frame"
2018-02-16 14_43_19-Open.png
This will open a new Everything window on the exact same spot where the FileOpen dialog was before, with the Folder-filter enabled. Notice that it has no title bar, nor menu bar.
2018-02-16 14_44_48-_ever - Everything.png
[*] Now search for the name of the folder like you always do
[*] Select the folder that you want to use, so that it is highlighted (in my example: C:\2INSTALL\Everything).
[*] Press <Enter>

Now you are back in the original FileOpen dialog, but with an important difference:
The folder you selected in Everything, is filled-in in the File name box (this one also accepts foldernames)
2018-02-16 14_45_16-Open.png
[*] Press <Enter> or click on the Open button to open in your selected folder.

So there you are, in the folder you wanted, without browsing through the complete foldertree.


As said, this is just a proof of concept. A lot of functionality has not been build yet; a lot of security measures to be taken.
Let's put it this way: if you want to cross the street, you watch left, right; if you're smart you also listen for sirens and if you are really suspicious, you also look out for cows falling from the sky ...
This scriptversion (v0.0.2) crosses the street blindfolded (but gets there alive surprisingly often!)



If you are adventurous and want to try it, follow these steps:

[*] Download Autohotkey.zip (https://autohotkey.com/download/ahk.zip)
[*] Extract this to some folder
[*] Download attached ExtendFileDialogV0.0.2.ahk.zip
[*] Extract this the same folder
[*] Change the path to Everything.exe to match your situation (currently set to "C:\Program Files\Everything\Everything.exe"). It's under SETTINGS. You can open the AHK file in notepad.

[*] Drag ExtendFileDialogV0.0.2.ahk to AutoHotkeyU64.exe (or AutoHotkeyU32.exe; depending on the "bitness" of your Windows)

The programs runs from the System Tray (aka Notification Area). It's a green icon with an "H". It might be hidden at first.

[*] To stop the program: right-click on the systray icon and choose Exit.

Good luck!

Suggestions (the intended concept is described in the AHK file itself) and code improvements (this is my very first Autohotkey script, so probably a lot of rookie mistakes) are welcome.

P.S. I wanted to post this message in the Development sub-forum, but adding pictures isn't allowed there. This is "plan B".
You do not have the required permissions to view the files attached to this post.
Last edited by NotNull on Fri Mar 30, 2018 1:34 pm, edited 5 times in total.

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Extend File Open dialogs with Everything-powers!

Post by NotNull » Fri Feb 16, 2018 2:58 pm

It seems there is a max of 3 attached files per message.
See attachment for the code.

Current version: 0.0.3
You do not have the required permissions to view the files attached to this post.
Last edited by NotNull on Sun Feb 18, 2018 7:46 pm, edited 1 time in total.

mdsy
Posts: 2
Joined: Sun Sep 14, 2014 1:46 am

Re: Use the power of Everything in File dialogs

Post by mdsy » Sat Feb 17, 2018 4:38 pm

thanks for the great idea.
it didn't work for me, because i have QTTabBar installed and it is 'stealing' the ENTER keypress !

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in File dialogs

Post by NotNull » Sun Feb 18, 2018 7:45 pm

mdsy wrote:thanks for the great idea.
it didn't work for me, because i have QTTabBar installed and it is 'stealing' the ENTER keypress !
Thanks for testing, mdsy! Really appreciated!!

I knew about possible issues with the way this script was stealing <Enter> (it's in the remarks in the .AHK file : "; This Enter-handling routine definitely needs improvement! ..." ).

It was needed because some AHK routine didn't function as advertised. I still have to contact the good folks from the AHK forum to ask what's going on, but in the meantime I've found a (way!) better workaround. This one should keep his fingers of of non-Everything windows.


Further improvements (hopefully :-)) in version 0.0.3:

- Changed the detection of Enter (less brute force)
- Changed detection of the Everything-window (independent of the name in the title bar).
- Go to selected folder directly (without extra <Enter>)

I replaced version 0.0.2 with 0.0.3 (don't throw away your copy of version 0.0.2; it will probably be a collector's item a few years from now :D ;)

And again: thanks for taking the effort to test this!

void
Site Admin
Posts: 4851
Joined: Fri Oct 16, 2009 11:31 pm

Re: Use the power of Everything in File dialogs

Post by void » Tue Feb 20, 2018 7:04 am

Thanks for the script and ideas.

I've always wanted to add something like this to Everything and it is often requested.

Maybe typing in es: into the save/open filename edit could show an Everything dropdown list of results matching the term after es:?
This could be extended to any edit box..

I'm not a fan of hooking into all windows to catch the open/save dialog, unless there is some other way to do this..

I'll explore some ideas for the Everything 1.5 release..

Stamimail
Posts: 698
Joined: Sat Aug 31, 2013 9:05 pm

Re: Use the power of Everything in File dialogs

Post by Stamimail » Tue Feb 20, 2018 11:03 am

The real problem will be with this kind of dialog-box:
Image
Need to find a way how to send the PATH to every program.

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in File dialogs

Post by NotNull » Tue Feb 20, 2018 10:39 pm

Stamimail wrote:The real problem will be with this kind of dialog-box:
[..]
Need to find a way how to send the PATH to every program.
Thanks for bringing that up!
I actually did research that (shortly). It *is* very hard to interact with that. Turns out, this is actually not a foldertree, but a menu with (sub,sub)submenu's
AHK can't handle that out of the box, but someone wrote a library (routine?/?) for that. hundreds of lines of code; way above my current skill-set.
Luckily, this type of dialog boxes is deprecated. Since Vista they should look like this (first hit on Google):
Image

or this:
2018-02-21 00_56_13-Browse For Folder.png

I don't expect a lot of the older type (Notepad++ still uses them btw), so I don't think it is worth the effort (luckily :D )
You do not have the required permissions to view the files attached to this post.
Last edited by NotNull on Tue Feb 20, 2018 11:58 pm, edited 2 times in total.

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in File dialogs

Post by NotNull » Tue Feb 20, 2018 11:07 pm

void wrote:Thanks for the script and ideas.

I've always wanted to add something like this to Everything and it is often requested.
Although it was/is mainly an excuse to learn myself som AHK, it turns out that it is very useful (IMO, of course). I Actually miss it when the program is not running.
In the current version (not posted yet), you can also search for filenames. Quite often I don't know exactly what the folder was called, but do know a flename inside this folder. Now I can search for "ext:sh reboot" (because I know there is a Linux shell script in that folder, which name I only half remember). Press <Enter> and I'm in that folder. That's the best feature so far. If you decide to implement "File dialog add-on", please concider this. too.
Maybe typing in es: into the save/open filename edit could show an Everything dropdown list of results matching the term after es:?
This could be extended to any edit box..
I have no experience with the es: protocol, but I assume it isn't "search as you type"? Nevertheless, that is a nice way to do it. At least it is fully integrated (my way isn't)
I'm not a fan of hooking into all windows to catch the open/save dialog, unless there is some other way to do this..
Neither am I (mainly based on intuition). I tried other options first, but this was the most feasible (with my skillset)
I did read about hooking. Microsoft suggests to keep the hooks as shortly as possible alive. The AHK folks say it isn't a problem, as long as you handle the detection itself in a short time (and pass the "hook" to the next application).

Upon further reading, this hooking is more subtle than I thought it was. It is all done in userspace (no driver/DLL hacking) and it requires the application to "subsribe" to certain events (built-in Windows mechanism).
What helps (I think) is that it is in dialog boxes. If there ever is a moment where your system is close to idle, it must be in dialog boxes ..
I'll explore some ideas for the Everything 1.5 release..
[/quote]
Nice! Looking forward to that! If you need a sparring partner for ideas ...

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in File dialogs

Post by NotNull » Wed Mar 28, 2018 1:30 am

Stamimail wrote:The real problem will be with this kind of dialog-box:
Image
Need to find a way how to send the PATH to every program.
NotNull wrote:Luckily, this type of dialog boxes is deprecated. Since Vista they should look like ...
I was rewriting the script, because of:
void wrote:I'm not a fan of hooking into all windows to catch the open/save dialog, unless there is some other way to do this..
(and I agree ..)
Turns out that it is possible without this hooking stuff. Works nicely and now also supports folder-switching in File Explorer (new script will be posted after some more optimizing and testing)

When testing I stumbled upon this Windows 10 dialog box (for creating a shortcut):
2018-03-28 03_04_05-Project2.png
Apparently Microsoft has some trouble keeping up with their own standards (from 10 years ago :-))
You do not have the required permissions to view the files attached to this post.

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in File dialogs

Post by NotNull » Fri Mar 30, 2018 12:54 pm

void wrote: I'm not a fan of hooking into all windows to catch the open/save dialog, unless there is some other way to do this..
I thought so too and came up with this alternative:
  • In File Explorer or in OPen/Save dialog boxes: Right-click on an empty part of the file/folder list.
    It's a little hard to describe where exactly (The little space left from the file/folder icons is always OK to use), but you should end up with a context menu entry "Jump to Folder" with the familiar Everything logo:
    2018-03-30 00_54_41-Movies & TV.png
  • After choosing that option, you will see an Everything window where you can select the folder to jump to:
    2018-03-30 00_55_28-TEST.png
  • Press <Enter> on the right folder (or <Escape> to do nothing and go back)
  • Now you are in the choosen folder in the Explorer / file dialog window:
    2018-03-30 00_55_49-etc.png
  • That's it.
Next post: installation (there seems to be a max number of attachments ...)
You do not have the required permissions to view the files attached to this post.

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in File dialogs

Post by NotNull » Fri Mar 30, 2018 1:19 pm

Installation
  1. Download Autohotkey.zip (https://autohotkey.com/download/ahk.zip)
  2. Extract this to some folder
  3. Delete all files, except AutoHotkeyU64.exe /AutoHotkeyU32.exe
    Which one depends on the bit-ness of your Windows. If you don't know what that means, then leave both of them in place. Or better: wait for a next, more streamlined version of this.
  4. Download attached JumpToFolderV0.0.5.zip
  5. Extract this zip to the same folder
  6. Change the settings in JumpToFolder.ini to match your situation:

    Code: Select all

    [JumpToFolder]
    
    ;   Where is Everything installed?
    	EverythingEXE=C:\Program Files\Everything\Everything.exe
    ;	EverythingEXE=C:\Tools\Everything\Everything.exe
    
    ;   Extra Parameters for Everything (like instance). Not yet implemented.
    ;	EverythingParms=
    	
    ;   Icon to use in the context menu
    	Icon=C:\Program Files\Everything\Everything.exe
    ;	Icon=C:\Tools\Everything\Everything.exe
    
    ;   Text to use in the context menu
    	MenuText=Jump to Folder ...
    
    
  7. Run JumpToFolderContextmenu.cmd. You will get this:
    2018-03-30 15_16_25-C__WINDOWS_system32_cmd.exe.png
  8. Press <i> to install the context menu (and do some other stuff).
  9. Done.
You do not have the required permissions to view the files attached to this post.

Stamimail
Posts: 698
Joined: Sat Aug 31, 2013 9:05 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by Stamimail » Sun Apr 01, 2018 11:53 am

At step 8, I got:

Code: Select all

Enter your choice : I
The system cannot find the file JumpToFolder.ini.
The operation completed successfully.
The operation completed successfully.
The operation completed successfully.

Press any key to continue . . .

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Sun Apr 01, 2018 2:20 pm

Stamimail wrote:At step 8, I got:

Code: Select all

The system cannot find the file JumpToFolder.ini.
.. and that leads to a non-functioning context-menu, I guess.

Probably the script is started from a different folder than the one where JumpToFolder's INI and CMD are.



Try it with this CMD:
(difference is the extra pushd "%~dp0" (3rd line), that will make the script go to the folder where the script is)

Code: Select all

@echo off
setlocal
pushd "%~dp0"
color 1b
echo.
echo.
echo.	[I] Install JumpToFolder context menu
echo.	[R] Remove JumpToFolder context menu
echo.	[Q] Quit
echo.

choice /c IRQ /N /M "Enter your choice : "
call :Option%ERRORLEVEL%

echo.
pause
goto :EOF



:Option1
::	32 or 64 bit? (rough check is enough ..)
	set BITNESS=64
	if not exist "%windir%\SysWOW64\" set BITNESS=32
::	Read settings from INI
	for /f "delims=" %%x in (JumpToFolder.ini) DO set %%x 2>nul >nul

::	Add contextmenu to registry

::	Add contextmenu entry
	REG ADD HKCU\Software\Classes\Directory\Background\Shell\JumpToFolder /v MuiVerb /d "%MenuText%" -f

::	Add icon to conetxmenu
	REG ADD HKCU\Software\Classes\Directory\Background\Shell\JumpToFolder /v Icon /d "\"%Icon%\"" -f

::	Add command
	REG ADD HKCU\Software\Classes\Directory\Background\Shell\JumpToFolder\Command /ve /d "\"%CD%\AutoHotkeyU%BITNESS%.exe\" \"%CD%\JumpToFolder.ahk\"" -f
goto :EOF

:Option2
::	Remove context menu
	REG DELETE HKCU\Software\Classes\Directory\Background\Shell\JumpToFolder /f
goto :EOF


:Option3
::	Quit
goto :EOF

Stamimail
Posts: 698
Joined: Sat Aug 31, 2013 9:05 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by Stamimail » Sun Apr 01, 2018 3:45 pm

Now "The operation completed successfully."
Probably the script is started from a different folder than the one where JumpToFolder's INI and CMD are.
I don't think so.
Here is my structure:

Code: Select all

C:\Everything\NN\Everything-1.4.1.896.x64
C:\Everything\NN\AutoHotkeyU64.exe
C:\Everything\NN\JumpToFolder.ahk
C:\Everything\NN\JumpToFolder.ini
C:\Everything\NN\JumpToFolderContextmenu.cmd
C:\Everything\NN\JumpToFolderContextmenu2.cmd
C:\Everything\NN\Everything-1.4.1.896.x64\Everything.db
C:\Everything\NN\Everything-1.4.1.896.x64\Everything.exe
C:\Everything\NN\Everything-1.4.1.896.x64\Everything.ini
C:\Everything\NN\Everything-1.4.1.896.x64\Run History.csv
(Edit: it's probably RunAsAdmin effect, which set the current directory to C:\Windows\System32. https://ss64.com/nt/pushd.html)

Results:

I tryed with Firefox open dialog-box (Ctrl+O).
Everything showed up.
2 problems:
1. <Enter> in SearchBox should jump to Results Pane (MaxValueRunHistory). That's the way it works in Everything.
2. <Enter> in Results pane didn't make the expected behaviour.
Instead, I could notice it took affect on my current webpage, Google.
It typed in "2018-04-01" in Google search bar.
https://snag.gy/jauDSI.jpg
Last edited by Stamimail on Sun Apr 01, 2018 6:00 pm, edited 1 time in total.

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Sun Apr 01, 2018 5:58 pm

Stamimail wrote:
Probably the script is started from a different folder than the one where JumpToFolder's INI and CMD are.
I don't think so.
If you want to be sure, create a TEST.cmd in the folder where umpToFolderContextmenu.cmd is:

Code: Select all

pause
It should show you the current working directory when started (the same way you started the other .cmd).


1. <Enter> in SearchBox should jump to Results Pane (MaxValueRunHistory). That's the way it works in Everything.
<Enter> is reserved for passing through the selected folder to the Open/Save dialogbox. Use <Tab> to go to the resultlist.

2. <Enter> in Results pane didn't make the expected behaviour.
Instead, I could notice it took affect on my current webpage, Google.
It typed in "2018-04-01" in Google search bar.
Can't reproduce that. Will look into it. What might be a factor: the AHK assumes the first column of the result-list contains the filename and the second one the path. Do you have this configured any other way?


BTW: thank you very much for testing!! Good feedback!

Stamimail
Posts: 698
Joined: Sat Aug 31, 2013 9:05 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by Stamimail » Sun Apr 01, 2018 6:10 pm

Just added an edit I hope you see it.
Last edited by Stamimail on Sun Apr 01, 2018 6:14 pm, edited 1 time in total.

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Sun Apr 01, 2018 6:11 pm

[quote="Stamimail"
(Edit: it's probably RunAsAdmin effect, which set the current directory to C:\Windows\System32. https://ss64.com/nt/pushd.html)
[/quote]

No need, all settings are for current user. You can run the CMD and the AHK as a restricted user.

Stamimail
Posts: 698
Joined: Sat Aug 31, 2013 9:05 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by Stamimail » Sun Apr 01, 2018 7:04 pm

It should show you the current working directory when started (the same way you started the other .cmd).
Oh, current working directory...
In past I set the .cmd extension in my system, to be opened by Notepad.
So I needed at the beginning to open CMD manually, and dragged the .cmd to CMD window and run it...
What might be a factor: the AHK assumes the first column of the result-list contains the filename and the second one the path. Do you have this configured any other way?
https://snag.gy/H8J7iq.jpg

ovg
Posts: 162
Joined: Thu Oct 27, 2016 7:19 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by ovg » Sun Apr 01, 2018 7:23 pm

Hi, NotNull!

Thanks for sharing!
It works for me.
But I didn't like EV window without menu and title, sorry. :oops:

BTW, many thanks for efforts! :D

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Sun Apr 01, 2018 8:22 pm

ovg wrote: It works for me.
But I didn't like EV window without menu and title, sorry. :oops:
No problem :) That's a matter of personal taste.
You can get the menu and/or title back by commenting out lines 132 and 135, like this:

Code: Select all

;   Remove title bar of this Everything window (WS_CAPTION)
;   WinSet, Style, -0xC00000, ahk_id %@EverythingID%

;   Remove menu bar of this Everything window
;   DllCall("SetMenu", "uint", @EverythingID, "uint", 0)
EDIT: replaced # with ; (mixed things up)

But you probably knew that already (didn't you write an AHK script for @Stamimail for files that are/are not already downloaded? )

Thanks for feedback! Glad it works for at least 1 person beside myself :mrgreen:
Last edited by NotNull on Mon Apr 02, 2018 8:40 pm, edited 1 time in total.

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Sun Apr 01, 2018 8:27 pm

Stamimail wrote:
What might be a factor: the AHK assumes the first column of the result-list contains the filename and the second one the path. Do you have this configured any other way?
https://snag.gy/H8J7iq.jpg
Hmmm, then I have to think really hard what's going on here :(

Do you see this behaviour only in Firefox or also in File Explorer / Notepad's Open dialog box? MAybe some add-on that gets in the way (thinking out loud here ..)
Oh, current working directory...
In past I set the .cmd extension in my system, to be opened by Notepad.
So I needed at the beginning to open CMD manually, and dragged the .cmd to CMD window and run it...
Or right-click the CMD > Open

ovg
Posts: 162
Joined: Thu Oct 27, 2016 7:19 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by ovg » Sun Apr 01, 2018 8:51 pm

NotNull wrote: You can get the menu and/or title back by commenting out lines 132 and 135, like this:
Already done :-)
Program is very well commented!

Stamimail
Posts: 698
Joined: Sat Aug 31, 2013 9:05 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by Stamimail » Sun Apr 01, 2018 9:00 pm

@ovg
Hi ovg, I'm glad it works for you.
btw, ToDownload was/is great. thank you very much for that. :D

@NotNull
I tryed in Notepad (haven't it in context menu), and Chrome+Everything (failed, with inserting "2018-04-01").
Anyway, thanks, it's not critical.
Currently I'm using Direct Folders. It has a feature that makes the Dialog navigation more easy:
ClickSwitch

This feature will make a file dialog instantly jump to the folder already opened in Explorer, Total Commander or Directory Opus. Just switch to the window you need.
but still, I think the kind of dialog I've mentioned above, is the main problem here.

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Sun Apr 01, 2018 9:03 pm

ovg wrote:
NotNull wrote: You can get the menu and/or title back by commenting out lines 132 and 135, like this:
Already done :-)
Program is very well commented!
Thanks!
The reason why I removed those is that I wanted it to look different from the regular Everything, to avoid confusion. And to make it less easy to drag the windows around, showing the underlying window. But if you know what you're doing, this should be no problem.

ovg
Posts: 162
Joined: Thu Oct 27, 2016 7:19 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by ovg » Sun Apr 01, 2018 9:25 pm

NotNull wrote: The reason why I removed those is that I wanted it to look different from the regular Everything, to avoid confusion. And to make it less easy to drag the windows around, showing the underlying window.
I suspected this :-)

Stamimail
Posts: 698
Joined: Sat Aug 31, 2013 9:05 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by Stamimail » Sun Apr 01, 2018 9:55 pm

maybe we have a beginning of an answer...
I thought about the string "2018-04-01".
I have a hotkey app (HotkeyP), which Alt+Shift+D is configured to paste the current date, with YYYY-MM-DD pattern.
And I suspected that HotkeyP gets what JumpToFolder is sending.
And indeed, I can see the icon of HotkeyP in system tray is flashing after I <Enter> in Result Pane. It means HotkeyP launch a hotkey.
Another thing I can see, that now, the date was changed to 2018-04-02.

One more thing,
I could see this line in the AHK

Code: Select all

Activate Address bar (Alt-D)
I did some tests in my system.
It appears that there is no one rule for focusing the Address bar in my system.
For some dialogs the key is Alt+D
For some dialogs the key is Alt+C
The Keyboard langauge input (Alt+Shift) and CapsLock, are also affect this key.

ovg
Posts: 162
Joined: Thu Oct 27, 2016 7:19 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by ovg » Mon Apr 02, 2018 4:40 am

2Stamimail
Welcome, was glad to help :-)

ovg
Posts: 162
Joined: Thu Oct 27, 2016 7:19 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by ovg » Mon Apr 02, 2018 5:04 am

2NotNull
2Stamimail

I forgot to mention that line #185

Code: Select all

SendInput !D
for some reason doesn't work for me, should have been replaced with:

Code: Select all

Send !D
May be feature of my system? :lol:

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Mon Apr 02, 2018 8:29 pm

ovg wrote: I forgot to mention that line #185

Code: Select all

SendInput !D
for some reason doesn't work for me, should have been replaced with:

Code: Select all

Send !D
May be feature of my system? :lol:
That surprises me. You can send input with Send, SendInput or SendEvent. I tested all 3 on different machines. All worked (minus some timing isues)
If SendInput doesn't work (for some technical reason), it falls back to ... Send :? Beats me why it doesn't work in your case. Are you running this with an older version of AHK? (just guessing ...)

Stamimail wrote: I could see this line in the AHK

Code: Select all

Activate Address bar (Alt-D)
I did some tests in my system.
It appears that there is no one rule for focusing the Address bar in my system.
For some dialogs the key is Alt+D
For some dialogs the key is Alt+C
The Keyboard langauge input (Alt+Shift) and CapsLock, are also affect this key.
EDIT:
What happens if you replace SendInput !D with: SendInput {Alt Down}{d}{Alt Up} ?

That would be a real pity, if that doesn't work (I needed that for my file manager - Q-Dir - that has multiple address bars for multiple tabs. It is hard/impossible to figure out which address bar belongs to the active tab otherwise).

Originally code like this took care of the "Alt-D" routine:

Code: Select all

;       Put _FolderPath in Edit1 control of the Open dialog (where the filename is put; it also accepts folders)
        Control, EditPaste, %@FolderPath%, Edit1, ahk_id %@WinID%
I think it's better when I switch back to the old method ... Too bad, as the Alt-D is quite universal in Windows (so is <F4>, btw).


Which programd do have the <Alt-C> for the address bar? Is the "Jump to Folder" context menu active in those?
BTW: If you try to run "Jump to Folder" in a not supported application, you get a dialog box that says This program is not (yet) supported .. Routines for that program can be added later (the script is prepared for that). Your "Alt-C" program could be added that way.
Last edited by NotNull on Mon Apr 02, 2018 8:58 pm, edited 1 time in total.

ovg
Posts: 162
Joined: Thu Oct 27, 2016 7:19 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by ovg » Mon Apr 02, 2018 8:57 pm

NotNull wrote:Are you running this with an older version of AHK? (just guessing ...)
No, I use 1.1.28.01.
I have a script which notify me about new version of AHK:

Code: Select all

whr := ComObjCreate("WinHttp.WinHttpRequest.5.1")
whr.Open("GET", "https://autohotkey.com/download/1.1/version.txt", true)
whr.Send()
;Using 'true' above and the call below allows the script to remain responsive.
whr.WaitForResponse()
version := whr.ResponseText
If (version != A_AhkVersion)
{
   MsgBox, 4160,  New Version Of AHK Is Available, Version %version% of AutoHotKey Is Available!
   RunWait, wget64 -On:\Downloads\AutoHotkey_%version%.zip https://autohotkey.com/download/ahk.zip --no-check-certificate
}
From Autohotkey.com

Stamimail
Posts: 698
Joined: Sat Aug 31, 2013 9:05 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by Stamimail » Mon Apr 02, 2018 9:04 pm

Which programd do have the <Alt-C> for the address bar?
I could find this in Firefox and Notepad Open Dialogs (Ctrl+O). Only when Keyboard Input is Hebrew. When Keyboard input is English, neither Alt+C or alt+D works.
Is the "Jump to Folder" context menu active in those?
Firefox yes. Noetpad - it's not found in the context menu.
BTW: If you try to run "Jump to Folder" in a not supported application, you get a dialog box that says This program is not (yet) supported ..
I encountered this, when I was trying Word2003 dialog.

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Mon Apr 02, 2018 9:20 pm

Stamimail wrote:
Which programd do have the <Alt-C> for the address bar?
I could find this in Firefox and Notepad Open Dialogs (Ctrl+O). Only when Keyboard Input is Hebrew.
Aha, now I get it! That will probably mean that other languages use even different shotcut keys.
That convinces me to go back to the old style. Thanks! I'm glad this comes up so soon in the process...

Strange you don't get the Jump .. context menu in Notepad. That was my primary test-case.
Anyone else here seeing that same issue?

ovg
Posts: 162
Joined: Thu Oct 27, 2016 7:19 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by ovg » Mon Apr 02, 2018 9:53 pm

I've noticed that "Jump to folder" appears only if there is a "free space" in Open/Save dialog.
1.png
2.png
You do not have the required permissions to view the files attached to this post.

ovg
Posts: 162
Joined: Thu Oct 27, 2016 7:19 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by ovg » Tue Apr 03, 2018 12:21 pm

Hmm, now SendInput !D also working :roll: :evil:

Stamimail
Posts: 698
Joined: Sat Aug 31, 2013 9:05 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by Stamimail » Tue Apr 03, 2018 9:53 pm

I've noticed that "Jump to folder" appears only if there is a "free space" in Open/Save dialog.
I've noticed that it's actaully "Libraries\Documents" vs Desktop difference.
When set to Desktop, I do have it.

ovg
Posts: 162
Joined: Thu Oct 27, 2016 7:19 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by ovg » Wed Apr 04, 2018 4:33 am

Stamimail wrote:I've noticed that it's actaully "Libraries\Documents" vs Desktop difference.
For me - in any place, if there is some "free space"
Untitled.png
You do not have the required permissions to view the files attached to this post.

Stamimail
Posts: 698
Joined: Sat Aug 31, 2013 9:05 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by Stamimail » Wed Apr 04, 2018 5:55 am

ovg wrote:
Stamimail wrote:I've noticed that it's actaully "Libraries\Documents" vs Desktop difference.
For me - in any place, if there is some "free space"
"Desktop" means "in any place", except for libraries.
If you in location that it looks like there is not "free space", put the cursor in the space between the Navigation Pane and the Name column, and then Right Click.

@NotNull
viewtopic.php?f=7&t=6095

ovg
Posts: 162
Joined: Thu Oct 27, 2016 7:19 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by ovg » Wed Apr 04, 2018 8:10 am

Wow, thanks!
"put the cursor in the space between the Navigation Pane and the Name column, and then Right Click." :oops: :D

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Wed Apr 04, 2018 9:13 am

ovg wrote:Wow, thanks!
"put the cursor in the space between the Navigation Pane and the Name column, and then Right Click." :oops: :D
Hidden in pages long discussions was this instruction:
  • In File Explorer or in OPen/Save dialog boxes: Right-click on an empty part of the file/folder list.
    It's a little hard to describe where exactly (The little space left from the file/folder icons is always OK to use), but you should end up with a context menu entry "Jump to Folder" with the familiar Everything logo:

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Wed Apr 04, 2018 9:22 am

Stamimail wrote:
I've noticed that "Jump to folder" appears only if there is a "free space" in Open/Save dialog.
I've noticed that it's actaully "Libraries\Documents" vs Desktop difference.
When set to Desktop, I do have it.
Currently only implemented for "normal" folders.
If you would like to have it in "special folders", like libraries, Recycle bin, add/remove programs .. no problem.
Same goes for Drives (rightclicking C:\ does not (yet) bring up the context menu in this test version)
Also easy to implement.

Note that the context menu entry is available on the Desktop, but selecting it, does nothing (no directory to change here :))


I will write a new version of the AHK and the CMD tonight (if nothing else interferes ...)

NotNull
Posts: 1398
Joined: Wed May 24, 2017 9:22 pm

Re: Use the power of Everything in Explorer and File dialogs

Post by NotNull » Wed Apr 04, 2018 9:32 am

Stamimail wrote: @NotNull
viewtopic.php?f=7&t=6095
Yesterday, during some non-related experiments, I messed up my Q-Dir filemanager. No problem - I'm used to that - but I noticed it was in German (author is German). Instead of Menu:File, I now got Menu:Datei (the German word for file), meaning Alt-D was bound to this menu entry.

Luckily I do have 2 à 3 other ways to get this working again (on paper; still have to build and test those)

Post Reply