Page 1 of 1

event when selecting a file

Posted: 21 Apr 2021, 17:59
by thomashawk
Hello everyone

Im looking for a way to grab the event of selecting files,
in order to open windows in browser, related to the selected files.

Id like it automatically, without any right click

I tryed with autoit but it didn't catch any event, on any files.

Any Ideas?

Thanks a lot.

Re: event when selecting a file

Posted: 22 Apr 2021, 16:48
by therube
Command | User Menu -> Customize
Menu Contents: Browser Search
Command: c:\seamonkey\seamonkey.exe -search %1

That will open SeaMonkey (if it is not already open) & perform a (browser) search for the currently highlighted item in Salamander (using your browsers default search engine).

Adjust as needed for your browser...

Re: event when selecting a file

Posted: 28 Apr 2021, 17:34
by thomashawk
Thanks but that's not what I meaned. I was looking for a way to launch commands automatically when browsing files. The result would be like a linked pannel in HTML. Anyway, I found a perfect solution with autoit. The script just click on a routine from the user menu when I click on a file from the browser, but it is nearly transparent. I post my script in order to help ppl if needed.

#include <Misc.au3>
#include <WinAPI.au3>
#include <WinAPIMisc.au3>
HotKeySet("{ESC}", "On_Exit")
Local $hDLL = DllOpen("user32.dll")

While 1
While WinActive("[CLASS:SalamanderMainWindowVer25]", "")
Local $hWnd = WinGetHandle("[CLASS:SalamanderMainWindowVer25]", "")
Local $tPoint = _WinAPI_GetMousePos(True, $hWnd)
If _IsPressed("01", $hDLL) Then
While _IsPressed("01", $hDLL)
If DllStructGetData($tPoint, "Y")>75 Then
ControlClick ("[CLASS:SalamanderMainWindowVer25]", "", "[CLASS:WinLib Universal Window2; INSTANCE:1]", "left", 1, 205, 10)
WinActivate("[CLASS:SalamanderMainWindowVer25]", "")

Func On_Exit()