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 

Help formatting a MsgBox statement

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



Joined: 08 Apr 2009
Posts: 5333
Location: San Diego, California

PostPosted: Thu Oct 01, 2009 7:25 pm    Post subject: Help formatting a MsgBox statement Reply with quote

I apologize for the /lame/ example, also for the long post but trivial question.

Using msgbox, I attempt to continue the line but I see the . character which I do not want.

I do understand some methods to continue script lines, and I know this works:

http://www.autohotkey.com/docs/Scripts.htm#continuation
Code:
; EXAMPLE #1:
Var =
(
Line 1 of the text.
Line 2 of the text. By default, a linefeed (`n) is present between lines.
)
msgbox %var%


Arrow Is there a way to rewrite the MsgBox below without changing to the above style/method?

Code:
#SingleInstance force
return
#q::

WinGetActiveTitle, Title

ControlGetFocus, OutputVarFoc , %Title%

MouseGetPos, OutputVarX, OutputVarY, OutputVarWin, OutputVarControl

WinGetTitle, Mtitle, ahk_id %OutputVarWin%

MsgBox, The active window is "%Title%!`nfocus!%OutputVarFoc%!`nx=!%OutputVarX%!`ny=!%OutputVarY%!
 . `nid=!%OutputVarWin%!`nctl=!%OutputVarControl%!`nmouse_win!%Mtitle%!
Back to top
View user's profile Send private message
jaco0646



Joined: 07 Oct 2006
Posts: 3113
Location: MN, USA

PostPosted: Thu Oct 01, 2009 8:05 pm    Post subject: Reply with quote

Code:
MsgBox,% "The active window is " Title "!`nfocus!" OutputVarFoc "!`nx=!" OutputVarX "!`ny=!" OutputVarY
 . "!`nid=!" OutputVarWin "!`nctl=!" OutputVarControl "!`nmouse_win!" Mtitle "!"
Back to top
View user's profile Send private message Visit poster's website
Roland



Joined: 08 Jun 2006
Posts: 307

PostPosted: Thu Oct 01, 2009 8:07 pm    Post subject: Reply with quote

Code:
MsgBox,
( join
The active window is "%Title%!`nfocus!%OutputVarFoc%!`nx=!%OutputVarX%!`ny=!%OutputVarY%!
`nid=!%OutputVarWin%!`nctl=!%OutputVarControl%!`nmouse_win!%Mtitle%!
)


?
Back to top
View user's profile Send private message
Leef_me



Joined: 08 Apr 2009
Posts: 5333
Location: San Diego, California

PostPosted: Thu Oct 01, 2009 8:58 pm    Post subject: Reply with quote

thank you both. Just what I was looking for.

@ jaco0646 you lost my double-quote! Crying or Very sad Wink
Back to top
View user's profile Send private message
jaco0646



Joined: 07 Oct 2006
Posts: 3113
Location: MN, USA

PostPosted: Thu Oct 01, 2009 9:59 pm    Post subject: Reply with quote

Surprised
Code:
MsgBox,% "The active window is """ Title "!`nfocus!" OutputVarFoc "!`nx=!" OutputVarX "!`ny=!" OutputVarY
 . "!`nid=!" OutputVarWin "!`nctl=!" OutputVarControl "!`nmouse_win!" Mtitle "!"
Back to top
View user's profile Send private message Visit poster's website
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