HELP About Continuation section too long

Post AHK_H specific scripts & libraries and discuss the usage and development of HotKeyIt's fork/branch
User avatar
manehscripts
Posts: 126
Joined: 03 May 2019, 16:10

HELP About Continuation section too long

24 May 2019, 01:54

Hello! Please, somebody help me!
I'm following this tutorial but I can not get results.

Splitting a Long Line into a Series of Shorter Ones: https://www.autohotkey.com/docs/Scripts.htm

Code: Select all

Var =
(
...
)
Var = %Var%`n  ; Add more text to the variable via another continuation section.
(
...
)
FileAppend, %Var%, C:\My File.txt
My Script:

Code: Select all

Gui, Add, Edit, r1 ReadOnly w200 vAlert, Stopped!
Gui, Add, Button, vStartScript gStartG, START!
Gui, Show,
return

toggle := 0
StartG:
    toggle := !toggle
    if (toggle) {
        GuiControl,,StartScript, STOP!
        GuiControl,,Alert, Running!
        
		CritObj := CriticalObject({"variable1": 10})

        DllOn := AhkThread("
        (
			Var =
			(
				... 150lines
			)
			Var = %Var%`n
			(
				... +150lines
			)
			Var = %Var%`n
			(
				... +150lines
			)
        )", &CritObj)
		DllOn.ahkPause("Off")
    } else {
        DllOn.ahkTerminate.1
        GuiControl,,Alert, Stopped!
        GuiControl,,StartScript, START!
    }
return

Esc::ExitApp
GuiClose:
ExitApp
User avatar
manehscripts
Posts: 126
Joined: 03 May 2019, 16:10

Re: HELP About Continuation section too long

24 May 2019, 08:16

HotKeyIt wrote:
24 May 2019, 04:10
Try

Code: Select all

var.="
(
...
)"
Hello, thanks for answering!
I tried:

Code: Select all

			var="
			(
				... 150lines
			)"
			var.="
			(
				... +150lines
			)"
			var.="
			(
				... +150lines
			)"
And:

Code: Select all

			var.="
			(
				... 150lines
			)"
			var.="
			(
				... +150lines
			)"
			var.="
			(
				... +150lines
			)"
And show error:

Code: Select all

The following variable name contains an illegal character:
"
"
-----------------------------------------------------------
Stop to think, shut up to resist, and act to win!
kyuuuri
Posts: 340
Joined: 09 Jan 2016, 19:20

Re: HELP About Continuation section too long

24 May 2019, 08:53

Are you escaping all the %? can you show us the code that goes inside the continuation section?
User avatar
manehscripts
Posts: 126
Joined: 03 May 2019, 16:10

Re: HELP About Continuation section too long

24 May 2019, 09:12

kyuuuri wrote:
24 May 2019, 08:53
Are you escaping all the %? can you show us the code that goes inside the continuation section?
Hello, thanks.

I did some tests and got to do read numbers, letters he does not recognize (can someone tell me why?)
And another detail, even partitioning, continues to present the error Continuation section too long.

Code: Select all

Gui, Add, Edit, r1 ReadOnly w200 vAlert, Stopped!
Gui, Add, Button, vStartScript gStartG, START!
Gui, Show,
return

toggle := 0
StartG:
    toggle := !toggle
    if (toggle) {
        GuiControl,,StartScript, STOP!
        GuiControl,,Alert, Running!
        
		CritObj := CriticalObject({"variable1": 10})

        DllOn := AhkThread("
        (
		
			number .= (123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797646896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689679768451233757896896797684512337578968967976845123375789689)
			number .= (000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000)
			MsgBox, %number%
			
			text .= (abc)
			text .= (dfg)
			MsgBox, %text%
			
        )", &CritObj)
		DllOn.ahkPause("Off")
    } else {
        DllOn.ahkTerminate.1
        GuiControl,,Alert, Stopped!
        GuiControl,,StartScript, START!
    }
return

Esc::ExitApp
GuiClose:
ExitApp
Last edited by manehscripts on 24 May 2019, 10:41, edited 2 times in total.
-----------------------------------------------------------
Stop to think, shut up to resist, and act to win!
swagfag
Posts: 6222
Joined: 11 Jan 2017, 17:59

Re: HELP About Continuation section too long

24 May 2019, 10:30

Code: Select all

AhkThread("
(
	var := ""
	(
		""""text""""
	`)""

	var .= ""``n
	(
		more """"text""""
	`)""

	MsgBox % var
)")

MsgBox OK to close everything
it would be easier if u loaded the scripts as files or wrote it in ahk_h v2
otherwise u have to learn the subtle differences between legacy-mode and expression-mode continuations sections in v1, what to escape when, and just how much
seems like a hassle
User avatar
manehscripts
Posts: 126
Joined: 03 May 2019, 16:10

Re: HELP About Continuation section too long

24 May 2019, 10:41

swagfag wrote:
24 May 2019, 10:30

Code: Select all

AhkThread("
(
	var := ""
	(
		""""text""""
	`)""

	var .= ""``n
	(
		more """"text""""
	`)""

	MsgBox % var
)")

MsgBox OK to close everything
it would be easier if u loaded the scripts as files or wrote it in ahk_h v2
otherwise u have to learn the subtle differences between legacy-mode and expression-mode continuations sections in v1, what to escape when, and just how much
seems like a hassle
Thank you for your help, it worked but I still can not partition, the example below it still looks like Continuation section too long.
Leveraging, do you suggest me use v2? I do not remember why I wanted to stay on v1.

Code: Select all

Gui, Add, Edit, r1 ReadOnly w200 vAlert, Stopped!
Gui, Add, Button, vStartScript gStartG, START!
Gui, Show,
return

toggle := 0
StartG:
    toggle := !toggle
    if (toggle) {
        GuiControl,,StartScript, STOP!
        GuiControl,,Alert, Running!
        
		CritObj := CriticalObject({"variable1": 10})

        DllOn := AhkThread("
        (
			var := ""
			(
				12313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131212313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141241231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123142554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434725541231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121411231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471242554347123131214124255434712425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554342554347123131214124255434712425543471231312141242554347124712313121412425543471231312141242554347123131214124255434714255434712313121412425543471242554347123131214124255434712231312141242554347123131214124255434712313121412424255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712554347123131214124255434712313121412425543471231312141242425543471231312141242554347124255434712313121412425543471255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214255434712313121412425543471242554347123131214124255434712425543471231312141242554425543471231312141242554347124255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712347124124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312142554347123131214124255434712425543471231312141242554347124255434712313121412425544255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712425543471231312141242554347123471241242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121425543471231312141242554347124255434712313121412425543471242554347123131214124255442554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471234712412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141231312141242554347123131214124255434712313121412313121412425543471231312141242554347123131214123131214124255434712313121412425543471231312141231312141242554347123131214124255434712313121412313121412425543471231312141242554347123131214123131214124255434712313213412131214124255434712313121412313121412425543471231312141242554347123131214
			`)""

			var .= ""``n
			(
				00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
			`)""
			MsgBox, %var%
        )", &CritObj)
		DllOn.ahkPause("Off")
    } else {
        DllOn.ahkTerminate.1
        GuiControl,,Alert, Stopped!
        GuiControl,,StartScript, START!
    }
return

Esc::ExitApp
GuiClose:
ExitApp
-----------------------------------------------------------
Stop to think, shut up to resist, and act to win!
swagfag
Posts: 6222
Joined: 11 Jan 2017, 17:59

Re: HELP About Continuation section too long

24 May 2019, 11:12

the 16k character limit has been violated
u have one big continuation section in ur main script that contains 2 smaller, yet-to-become "continuation sections" each of which is 16k characters long
therefore the combined length of the big continuation section then is ...?
User avatar
manehscripts
Posts: 126
Joined: 03 May 2019, 16:10

Re: HELP About Continuation section too long

24 May 2019, 11:19

swagfag wrote:
24 May 2019, 11:12
the 16k character limit has been violated
u have one big continuation section in ur main script that contains 2 smaller, yet-to-become "continuation sections" each of which is 16k characters long
therefore the combined length of the big continuation section then is ...?
Sorry but I did not understand.
I thought that while using sessions and partitioning the code it would not give that error. I'm trying to add #includes script.ahk but at the time of compiling the .exe it requests the .ahk file, I do not understand why it does not include in the .exe. That's why I'm adding all the script in the main. If you can help me with this question too, I appreciate it.
-----------------------------------------------------------
Stop to think, shut up to resist, and act to win!
swagfag
Posts: 6222
Joined: 11 Jan 2017, 17:59

Re: HELP About Continuation section too long

24 May 2019, 12:06

Code: Select all

DllOn := AhkThread("
(
			var := ""
			(
				12313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131212313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141241231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123142554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434725541231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121411231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471242554347123131214124255434712425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554342554347123131214124255434712425543471231312141242554347124712313121412425543471231312141242554347123131214124255434714255434712313121412425543471242554347123131214124255434712231312141242554347123131214124255434712313121412424255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712554347123131214124255434712313121412425543471231312141242425543471231312141242554347124255434712313121412425543471255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214255434712313121412425543471242554347123131214124255434712425543471231312141242554425543471231312141242554347124255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712347124124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312142554347123131214124255434712425543471231312141242554347124255434712313121412425544255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712425543471231312141242554347123471241242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121425543471231312141242554347124255434712313121412425543471242554347123131214124255442554347123131214124255434712425543471231312141242554347124255434712313121412425543471242554347123131214124255434712425543471231312141242554347124255434712313121412425543471234712412425543471231312141242554347123131214124255434712313121412425543471231312141242554347123131214124255434712313121412425543471231312141231312141242554347123131214124255434712313121412313121412425543471231312141242554347123131214123131214124255434712313121412425543471231312141231312141242554347123131214124255434712313121412313121412425543471231312141242554347123131214123131214124255434712313213412131214124255434712313121412313121412425543471231312141242554347123131214
			`)""

			var .= ""``n
			(
				00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
			`)""
			MsgBox, %var%
)", &CritObj)
a line can only ever contain at most 16 383 characters, after being preprocessed by the interpreter. the line DllOn:=AhkThread("......",&CritObj) ends up exceeding that limit. its 16 680 characters long
it doesnt matter that u have split the continuation sections inside the thread script. the continuation section in the main script needs to be broken up.

#Include is a janky way to run scripts from file, imo. i dont even know if that does anything at all when the script is compiled
OutputVar := AhkThread(ScriptOrFile, Parameters, Title, ScriptIsFile, DllToUse) accepts a path to a script if the correct flag is set
this probably wont work either if ur goal is to have a single compiled executable and no auxiliary .ahk scripts laying around

maybe u could pack the scripts in with reshacker and MemoryLoadString
User avatar
manehscripts
Posts: 126
Joined: 03 May 2019, 16:10

Re: HELP About Continuation section too long

24 May 2019, 21:49

Hi @swagfag. Thanks for the explanation!.
I'm new to Autohotkey and I'm learning, and I started using SetTimer for repetitions, but as I increased my script, I realized I needed to create an independent loop, that's when I met Autohotkey.dll
With this I needed to learn new functions and adapt, but my program was almost finished, with 7k+ lines, so to not have to redo everything from scratch, I'm having to use v1 with this adaptation to Autohotkey.dll where I can create these simultaneous processes and independently.
I have a loop with 75857 characters that needs to be run inside the AhkThread()

Edit:
I made some changes to the code and it looks like it now works fine. But I have not yet tested with my entire script inside the partitions, the test I did was with set of letters and numbers.
I noticed that it raises an error when it exceeds 16,383 characters and is inside a MsgBox (I'll leave the error example just below).

This test works very well now:

Code: Select all

Gui, +AlwaysOnTop
Gui, Add, Edit, r1 ReadOnly w200 vAlert, Stopped!
Gui, Add, Button, vStartScript gStartG, START!
Gui, Show,
return

toggle := 0
StartG:
    toggle := !toggle
    if (toggle) {
        GuiControl,,StartScript, STOP!
        GuiControl,,Alert, Running!
		CritObj := CriticalObject({"variable1": "10:"})
		script:="
		("
		15000 characters
		)"
		script.="
		("
		+15000 characters
		)"
		script.="
		("
		+15000 characters
		)"
		script.="
		("
		+15000 characters
		)"
		DllOn:=AhkThread(script,&CritObj)
		FileAppend, %script%, C:\countcheck.txt
    } else {
        DllOn.ahkTerminate.1
        GuiControl,,Alert, Stopped!
        GuiControl,,StartScript, START!
    }
return

Esc::ExitApp
GuiClose:
ExitApp
Here displays error in MsgBox when it exceeds the character limit, but saves the file with all the characters::

Code: Select all

Gui, +AlwaysOnTop
Gui, Add, Edit, r1 ReadOnly w200 vAlert, Stopped!
Gui, Add, Button, vStartScript gStartG, START!
Gui, Show,
return

toggle := 0
StartG:
    toggle := !toggle
    if (toggle) {
        GuiControl,,StartScript, STOP!
        GuiControl,,Alert, Running!
		CritObj := CriticalObject({"variable1": "10:"})
		script:="
		("
		MsgBox, 15000 characters
		)"
		script.="
		("
		+15000 characters
		)"
		script.="
		("
		+15000 characters
		)"
		script.="
		("
		+15000 characters
		)"
		DllOn:=AhkThread(script,&CritObj)
		FileAppend, %script%, C:\countcheck.txt
    } else {
        DllOn.ahkTerminate.1
        GuiControl,,Alert, Stopped!
        GuiControl,,StartScript, START!
    }
return

Esc::ExitApp
GuiClose:
ExitApp
Screenshot_7.png
Screenshot_7.png (5.06 KiB) Viewed 5770 times
-----------------------------------------------------------
Stop to think, shut up to resist, and act to win!
User avatar
manehscripts
Posts: 126
Joined: 03 May 2019, 16:10

Re: HELP About Continuation section too long

25 May 2019, 18:56

Sorry duplicate the post.
But I would like to share that I have been able to solve my problem, after much study and attempts. Thanks to those who collaborated, you all are top! :dance:

EDIT!!!
I found myself thinking ... :think:
I've been trying so hard to learn how to use Autohotkey.dll to make independent concurrent processes work, and now I'm using a code that does not have the Autohotkey.dll call
Can anyone tell me how it's working? I compiled and the file next to the executable is not necessary cause everything works!

Code: Select all

Gui, +AlwaysOnTop
Gui, Add, Edit, r1 ReadOnly w200 vAlert, Stopped!
Gui, Add, Button, vStartScript gStartG, START!
Gui, Show,
return

toggle := 0
StartG:
    toggle := !toggle
    if (toggle) {
        GuiControl,,StartScript, STOP!
        GuiControl,,Alert, Running!
		CritObj := CriticalObject({"variable1": "Count: "})
		
       script:="
        ("
            Loop {
                CritObj := CriticalObject(A_Args[1])
				variable1 = `% CritObj.variable1
				var1++
        )"
        script.="
        ("
				ToolTip, %variable1%%var1%
			}
        )"

		DllOn:=AhkThread(script,&CritObj)
    } else {
        DllOn.ahkTerminate.1
        GuiControl,,Alert, Stopped!
        GuiControl,,StartScript, START!
    }
return

Esc::ExitApp
GuiClose:
ExitApp
-----------------------------------------------------------
Stop to think, shut up to resist, and act to win!

Return to “AutoHotkey_H”

Who is online

Users browsing this forum: No registered users and 19 guests