AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Listvars with multiple scripts running simultaneously

 
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
ProsperousOne



Joined: 19 Sep 2005
Posts: 115

PostPosted: Thu Aug 21, 2008 12:14 pm    Post subject: Listvars with multiple scripts running simultaneously Reply with quote

My autohotkey.ini file includes utilities.ahk, which contains a hotkey for listvars.

I use utilities.ahk in all scripts I write.

When I press the hotkey for listvars, I keep getting the variables for the ahk.ini file, not the script I'm running.

Here's an example of the files:

ahk.ini
Code:
#include utilities.ahk
Var1 = 123


How can I control which variables are retreived with listvars when multiple scrips are running?

myscript.ahk
Code:
#include utilities.ahk
Var2 = 345



utilities.ahk
Code:
^v::Listvars
Back to top
View user's profile Send private message
[VxE]



Joined: 07 Oct 2006
Posts: 3254
Location: Simi Valley, CA

PostPosted: Thu Aug 21, 2008 12:17 pm    Post subject: Reply with quote

Change ^v::ListVars to ~^v::ListVars, then use the little red buttons at the top right corner to reach the one you want Wink
_________________
Ternary (a ? b : c) guide     TSV Table Manipulation Library
Post code inside [code][/code] tags!
Back to top
View user's profile Send private message
ProsperousOne



Joined: 19 Sep 2005
Posts: 115

PostPosted: Thu Aug 21, 2008 4:23 pm    Post subject: Reply with quote

[VxE] wrote:
use the little red buttons at the top right corner to reach the one you want Wink


I assume you mean the grey close "x" button?

I don't get it.... I'm only getting one window to open (seeme to be different each time... maybe depending on the order the scripts were launched?)

Actually, my included file line is

Code:
~^+v::ListVars


I added the "~" as you suggested, but it's only opening up one variable list window... Confused

thx!
Back to top
View user's profile Send private message
ProsperousOne



Joined: 19 Sep 2005
Posts: 115

PostPosted: Mon Aug 25, 2008 3:51 pm    Post subject: Reply with quote

bump
Back to top
View user's profile Send private message
n-l-i-d
Guest





PostPosted: Mon Aug 25, 2008 4:44 pm    Post subject: Reply with quote

See the OnMessage documentation and the last 2 examples. With only the hotkeyed PostMessage in your "always running" script, and the OnMessage -> ListVars in your scripts/include, combined with a small "which script's vars do you want to see" selection GUI on keypress, it would work.

If you include the hotkey in all scripts, only the last (I guess) will be active, and you'll only see those ListVars.

HTH
________________________________________________________
New here? Please, before you post...
1. Read the tutorial and try the examples. -> 2. Take a look at the command list to get an idea of what you could do. -> 3. Create your script. Consult the documentation and the FAQ if you get stuck. -> 4. Search the forum if you need help or examples, method 1 (forum), method 2 (site), method 3 (Google). -> 5. Post your code on the forum in the "Ask for Help" section if you still run into problems (but read this first). -> 6. There is more AHK on autohotkey.net and the Wiki and there is an AHK IRC chat.
Back to top
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group