Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

a neat trick!


  • Please log in to reply
7 replies to this topic
Rajat
  • Members
  • 1904 posts
  • Last active: Jul 17 2015 07:45 AM
  • Joined: 28 Mar 2004
You can drag & drop files over .bat .exe .com .pif .cmd etc. files. this makes them run with the dropped file as their first parameter. u can do it with compiled AHK scripts as they too are executable, but not with .ahk files.

this single line code will add that functionality to .ahk scripts too!!

RegWrite, REG_SZ, HKCR, AutoHotkeyScript\shellex\DropHandler,,{86C86720-42A0-1069-A2E8-08002B30309D}


Chris, i'd strongly suggest adding it to default installation of AHK. i've used it for ages with .aut files and then with .au3 files ...it has no side-effects.

or maybe i can add it to the TextPad syntax installation script...if u feel for some reason it'd b better.

MIA

CleanNews.in : Bite sized latest news headlines from India with zero bloat


Chris
  • Administrators
  • 10727 posts
  • Last active:
  • Joined: 02 Mar 2004
Great stuff. I was wondering why something like "Run, MyScript.ahk param1 param2" didn't work. Maybe this will fix all such things.

Do you know if this works on Win9x?

Beastmaster
  • Guests
  • Last active:
  • Joined: --

or maybe i can add it to the TextPad syntax installation script...if u feel for some reason it'd b better

Boing ( --> a cartoon like kind of funny noise :lol: ) - here it is. My my trigger.

Would you mind to approve/confirm a default color scheme for syntax highlighting files. I'm willing to get one done (cause it looks like a plain matter of diligence work). But I would leave it with AHK's pros to decide about the order/categories and the colors (if there's something like a standard in the world of coding geeks 8) )

For a first review I've left the command reference (raw style) in the forum.

Chris
  • Administrators
  • 10727 posts
  • Last active:
  • Joined: 02 Mar 2004
I don't think we need standard colors. We should just be thankful when someone comes along with a syntax file, which takes a lot of time and effort. However, if there's no strong preference, the TextPad colors chosen by Rajat can be used.

I will be including the TextPad config and any others in an Extras folder with future releases.

Rajat
  • Members
  • 1904 posts
  • Last active: Jul 17 2015 07:45 AM
  • Joined: 28 Mar 2004

Do you know if this works on Win9x?


i reckon i've used it on WinME.
but test on W98 didn't work. will check if there's another way.

but i'm sure adding it won't break anything in those systems.

MIA

CleanNews.in : Bite sized latest news headlines from India with zero bloat


Rajat
  • Members
  • 1904 posts
  • Last active: Jul 17 2015 07:45 AM
  • Joined: 28 Mar 2004

Boing ( --> a cartoon like kind of funny noise ) - here it is. My my trigger.


beastmaster there were a couple of reasons y i added that.

firstly, bcoz its deviating from the default behaviour of .ahk scripts till now so i thought maybe Chris wud like to make it an option (maybe asked during syntax installation or something).

secondly, as he's already being nice by promptly listening to my frequent comments and suggestions (many of which he's already implemented) so if there's something that i can do instead of troubling him with it, then i'd be glad to do it.

MIA

CleanNews.in : Bite sized latest news headlines from India with zero bloat


Chris
  • Administrators
  • 10727 posts
  • Last active:
  • Joined: 02 Mar 2004
You may be right about making this behavior optional: I suspect it would mess up some people who are innocently dragging and dropping files (to move them or make copies) and accidentally launch a script if they drop something too close to one.

Although clearly there are uses for drag & drop, it seems to me that such a feature wouldn't be used by the average user. Because of this, I won't make it the default. Instead, a checkbox during the installation process is probably in order.

Rajat
  • Members
  • 1904 posts
  • Last active: Jul 17 2015 07:45 AM
  • Joined: 28 Mar 2004
yeah that'd do. :)

MIA

CleanNews.in : Bite sized latest news headlines from India with zero bloat