Search found 643 matches

by Hellbent
18 Oct 2019, 03:55
Forum: Ask For Help
Topic: one key two actions toggle
Replies: 8
Views: 258

Re: one key two actions toggle

Rohwedder wrote:
18 Oct 2019, 03:24
If I pressed F2, I want F1 to send "if" part the first time I press F1: In else as desired!

I almost feel like you're trolling me here.

I want F1 to send "if" part
In else as desired!
:lol:
by Hellbent
18 Oct 2019, 03:46
Forum: Ask For Help
Topic: one key two actions toggle
Replies: 8
Views: 258

Re: one key two actions toggle

the first time I press F1 First off I think that we can both agree that based on what his code is doing, we are right in assuming that he doesn't mean for this to happen only on the first time that he presses F1 after having pressed F2. With that out of the way, I see the meaning of this to be para...
by Hellbent
18 Oct 2019, 01:55
Forum: Ask For Help
Topic: one key two actions toggle
Replies: 8
Views: 258

Re: one key two actions toggle

If I pressed F2, I want F1 to send "if" part the first time I press F1. Therefore boolean should be set to the intitalization value = True Try it. #SingleInstance,Force Global boolean := true F1::MyFunc() MyFunc() { if (boolean:=!boolean) { ToolTip, in if } else { ToolTip, In else } } return F2:: b...
by Hellbent
18 Oct 2019, 00:55
Forum: Ask For Help
Topic: one key two actions toggle
Replies: 8
Views: 258

Re: one key two actions toggle

Rohwedder wrote:
18 Oct 2019, 00:44
Hallo,
try:

Code: Select all


f2::
Send ^{1}
sleep 200
MouseClick, left, 107, 577,,1
MouseClick, left, 107, 537,,1
Send ^{9}
boolean := true   ;<---------------- should be false
return
boolean should be set to false here
by Hellbent
18 Oct 2019, 00:35
Forum: Ask For Help
Topic: one key two actions toggle
Replies: 8
Views: 258

Re: one key two actions toggle

Try this.

Code: Select all


#SingleInstance,Force



1::MyFunc()

MyFunc(override:="") { 
	static boolean := true 
	if(override){
		boolean:=0
		return
	}
	if (boolean:=!boolean) { 
		msgbox, in hotkey 1 if( boolean = true )
	} else {
		msgbox, in hotkey 1 else `n boolean = false
	}

}



2::
MyFunc(1)
return

by Hellbent
17 Oct 2019, 21:34
Forum: Ask For Help
Topic: Issue with gui hotkey control Topic is solved
Replies: 4
Views: 136

Re: Issue with gui hotkey control Topic is solved

Thanks to @gregster I have a better solution.

Code: Select all

else if((Newkey "" != MyHotkey "" &&MyHotkey!="")
by Hellbent
17 Oct 2019, 21:29
Forum: Bug Reports
Topic: if(VarContainingString =/!= OtherVarContainingString) Bug
Replies: 4
Views: 258

Re: if(VarContainingString =/!= OtherVarContainingString) Bug

wolf_II Thanks Wolf but that gets the same result, they evaluate as equal. gregster Thanks. Seems a bit odd, but it is how it is. I was going to use something like this if((Var1!=Var2&&Var2!="")||(Var1=Var2&&Strlen(Var1)!=Strlen(Var2))) But if(Var1 "" != Var2 "" && Var2!="") Is a better solution. *...
by Hellbent
17 Oct 2019, 20:22
Forum: Ask For Help
Topic: Issue with gui hotkey control Topic is solved
Replies: 4
Views: 136

Re: Issue with gui hotkey control Topic is solved

I've made a bug report about this so i'll just use a work around in my script. Either. else if((Newkey!=MyHotkey&&MyHotkey!="")||(Newkey=MyHotkey&&Newkey!="")) or else if((Newkey!=MyHotkey&&MyHotkey!="")||(Newkey=MyHotkey&&Strlen(Newkey)!=Strlen(MyHotkey))) That last one makes me laugh a bit :roll: ...
by Hellbent
17 Oct 2019, 19:52
Forum: Bug Reports
Topic: if(VarContainingString =/!= OtherVarContainingString) Bug
Replies: 4
Views: 258

if(VarContainingString =/!= OtherVarContainingString) Bug

I think that this should speak for it's self. Var1:="+1" Var2:="1" msgbox,% Var1 "`n" Var2 "`nClearly they are different." if( Var1 != Var2 ) msgbox, they are different but you won't get to see this message Var1 = +1 Var2 = 1 msgbox,% Var1 "`n" Var2 "`nClearly they are different." if( Var1 != Var2 )...
by Hellbent
17 Oct 2019, 19:13
Forum: Ask For Help
Topic: Prevent repeat triggering while using KeyWait command Topic is solved
Replies: 6
Views: 186

Re: Prevent repeat triggering while using KeyWait command Topic is solved

I don't use hotkeys often, but I figured that there must be a simpler way to do it than the way I posted above. Here is what I have. don't think it's going to get any simpler than this. Index:=0 F12:: KeyWait,F12,T0.6 if(A_TimeSinceThisHotkey>=500){ ToolTip,% ++Index } KeyWait, F12 return
by Hellbent
17 Oct 2019, 18:47
Forum: Ask For Help
Topic: Prevent repeat triggering while using KeyWait command Topic is solved
Replies: 6
Views: 186

Re: Prevent repeat triggering while using KeyWait command Topic is solved

Code: Select all


Index:=0

F12::
	StartPress:=A_TickCount
	while(GetKeyState("F12","P")){
		if((A_TickCount-StartPress)>=500){
			ToolTip,% ++Index
			break
		}else 	{
			Sleep,10
		}
	}

	keywait,F12
	return


by Hellbent
17 Oct 2019, 18:01
Forum: Ask For Help
Topic: Prevent repeat triggering while using KeyWait command Topic is solved
Replies: 6
Views: 186

Re: Prevent repeat triggering while using KeyWait command Topic is solved

This should do the trick.

Code: Select all

Index:=0

F12::
	StartPress:=A_TickCount
	keywait,F12
	if((A_TickCount-StartPress)>500){
		ToolTip,% ++Index
	}
	return
by Hellbent
17 Oct 2019, 17:48
Forum: Ask For Help
Topic: Prevent repeat triggering while using KeyWait command Topic is solved
Replies: 6
Views: 186

Re: Prevent repeat triggering while using KeyWait command Topic is solved

I think that this should do it.

Code: Select all

index:=0

F12 Up::
	Tooltip,% ++Index
	return
***Edit***

NVM, didn't see that you want it for after a long key press.
by Hellbent
17 Oct 2019, 17:27
Forum: Ask For Help
Topic: Assign array value
Replies: 3
Views: 154

Re: Assign array value

I have never been able to get that to work and I've tried what has to be every possible way to force an expression.

I always just end up doing something like this.

Code: Select all

array := []
fileRead, temp, test.txt
array[1]:=temp
temp:=""
If someone does know how to get it to work I'd love to see it.
by Hellbent
17 Oct 2019, 12:02
Forum: Ask For Help
Topic: Screenshot specific region of screen Topic is solved
Replies: 9
Views: 180

Re: Screenshot specific region of screen Topic is solved

Here is the first script edited to take shots of the selected region and save them with A_Now as the name with the press of a hotkey. I set the hotkey to F1, change as you wish. #SingleInstance,Force IfNotExist,%A_ScriptDir%\Recorded Shots FileCreateDir, %A_ScriptDir%\Temp Screen Shots SetWorkingDir...
by Hellbent
17 Oct 2019, 11:20
Forum: Ask For Help
Topic: Script will not go away
Replies: 2
Views: 61

Re: Script will not go away

Relaunch the window.
by Hellbent
17 Oct 2019, 11:10
Forum: Ask For Help
Topic: 2 SetTimer -1 at same time, and SoundPlay, , 1
Replies: 3
Views: 155

Re: 2 SetTimer -1 at same time, and SoundPlay, , 1

I haven't had to deal with Soundplay many times in the past.

When I had used it, I just put the soundplay in another script and used the first script to run it whenever I wanted it to play/ play again.
by Hellbent
17 Oct 2019, 11:02
Forum: Ask For Help
Topic: Screenshot specific region of screen Topic is solved
Replies: 9
Views: 180

Re: Screenshot specific region of screen Topic is solved

It's a great tool, but I was wondering. After capturing images. Is it possible to give them date stamps so when I record another, it doesn't overwrite? Simplest way would be to just use the create new folder controls at the top. Other than that you can edit the name that the image gets saved as. Gd...
by Hellbent
17 Oct 2019, 10:24
Forum: Ask For Help
Topic: Screenshot specific region of screen Topic is solved
Replies: 9
Views: 180

Re: Screenshot specific region of screen Topic is solved

A_Perry_1984 wrote:
17 Oct 2019, 10:16
Yes! Thank you. This is exactly what I was wanting.
It's a great tool for making image sequences that can be used to create time lapse videos. This one is still in the early stages of development, but works well enough in it's current state to work in many cases.
by Hellbent
17 Oct 2019, 10:08
Forum: Ask For Help
Topic: Associative Array with variable as key - beginner question Topic is solved
Replies: 2
Views: 70

Re: Associative Array with variable as key - beginner question Topic is solved

It looks like you have everything right except that you need to change the values to strings A quick way you can do the without going over everything in your list and adding quotes is to just declare a variable with the same name N:="N" Y:="Y" You could have other issues (I only glanced at your code...

Go to advanced search