AutoHotkey Community

It is currently May 27th, 2012, 2:40 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 7 posts ] 
Author Message
PostPosted: November 22nd, 2009, 5:36 pm 
Offline

Joined: February 2nd, 2008, 4:35 am
Posts: 643
I need this so that i can know if the file opened is an .ahk or not

* My file extensions = hidden in Explorer options (so dont show in Notepad titlebar)


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 22nd, 2009, 5:54 pm 
Offline

Joined: July 18th, 2006, 12:18 pm
Posts: 403
Get the notepad title.. Then append .ahk to end of it..

Then use IfFileExist..

NotePadTitle .= .ahk


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 22nd, 2009, 6:10 pm 
Offline

Joined: February 2nd, 2008, 4:35 am
Posts: 643
Actually it's a little more involved than i implied..

--> I do not know the wherabouts of the file opened (ie explorer is not opened at that location - is just Notepad window & no explorer window)


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 22nd, 2009, 6:24 pm 
Offline

Joined: July 18th, 2006, 12:18 pm
Posts: 403
if the AHK file has a GUI, you could use ControlGet to deterime if its a ahk program/script or not.

There are numerous ways using ahk_class etc.. You tried these?

Or maybe im still not understanding


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 22nd, 2009, 6:34 pm 
Offline

Joined: February 2nd, 2008, 4:35 am
Posts: 643
i3egohan wrote:
if the AHK file has a GUI, you could use ControlGet to deterime if its a ahk program/script or not
No, no Gui is running, am just editing the script

Am currently searching for a 3rd-party command-line tool which will provide this info (but which quite probably doesnt exist)


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 22nd, 2009, 8:57 pm 
Offline
User avatar

Joined: December 26th, 2005, 4:40 pm
Posts: 8776
Please search the forum for getremotecommandline


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 23rd, 2009, 3:03 am 
Offline

Joined: February 2nd, 2008, 4:35 am
Posts: 643
Brilliant!! Thanks for that SKAN !! :D


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: Alpha Bravo, Bing [Bot], rbrtryn and 19 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group