2nd gui window

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
sbrady
Posts: 105
Joined: 15 Mar 2014, 20:41
Location: Virginia Beach

2nd gui window

Post by sbrady » 23 Aug 2017, 12:08

below is my code to open a window when you click on a button. Doesnt work.

Code: Select all

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ABOUT BUTTON
Buttonabout:

Gui, MyGui:+Owner,  ;Show, x600 y100 h350 w300
WinExist("A")
WinGetPos,,, sizeX, sizeY
WinMove, (A_ScreenWidth/2)-(sizeX/2), (A_ScreenHeight/2)-(sizeY/2)
GUI, submit, nohide
Gui MyGui, Font, s10
Gui MyGui, Add, Edit, vscroll  +wrap h320 w270 +0x100 readonly,created Jul 1, 2014`nby Shawn Brady`n`n08-22-17`nv5.8 added path to new folder to clipboard`n`n08-21-17`nfixed search QNAP if proj not found`n`n08-17-17`nmake new QNAP proj, generate an email`n`n08-16-17`nMinAll minimizes ALL apps and desktop windows,then opens Gails Widget`n`n08-15-17`nfixed make new project with iSU names`n`n08-14-17`nadded open Features4\Producers if project not found otherwise`n`n08-10-17`nadd iPray category so new code for reading and writing`n`n08-08-17`nadd ctl+sh+3 to auto generate email for new QNAP projects`n`n08-03-17`nadded MOTS QNAP category, search and make`n`n07-26-17`nfixed Interactive search and Make project`n`n07-19-17`nstringleft 3 so search is for WOK not Mar`n`n07-12-17`nQNAP in all caps`n`n07-12-17`nno v1 needed for new projects`n`n07-11-17`nrecoded for qnap`n`n

return
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; END ABOUT BUTTON

Nightwolf85
Posts: 302
Joined: 05 Feb 2017, 00:03

Re: 2nd gui window

Post by Nightwolf85 » 23 Aug 2017, 12:23

I don't see you showing the new GUI:

Code: Select all

Gui, MyGui:Show
before the return.

Does that do what you expect?

sbrady
Posts: 105
Joined: 15 Mar 2014, 20:41
Location: Virginia Beach

Re: 2nd gui window

Post by sbrady » 23 Aug 2017, 12:24

this tweek still does not work.

Code: Select all

Buttonabout:

Gui, MyGui:+Owner,  
Gui, MyGui:Show, x600 y100 h350 w300
WinExist("A")
WinGetPos,,, sizeX, sizeY
WinMove, (A_ScreenWidth/2)-(sizeX/2), (A_ScreenHeight/2)-(sizeY/2)
Gui, MyGui, submit, nohide
Gui, MyGui, Font, s10
Gui, MyGui, Add, Edit, vscroll  +wrap h320 w270 +0x100 readonly,created Jul 1, 2014`nby Shawn Brady`n`nUpdates:`n08-23-17 Found type in link to folder in email body`n`n08-22-17`nv5.8 added path to new folder to clipboard`n`n08-21-17`nfixed search QNAP if proj not found`n`n08-17-17`nmake new QNAP proj, generate an email`n`n08-16-17`nMinAll minimizes ALL apps and desktop windows,then opens Gails Widget`n`n08-15-17`nfixed make new project with iSU names`n`n08-14-17`nadded open Features4\Producers if project not found otherwise`n`n08-10-17`nadd iPray category so new code for reading and writing`n`n08-08-17`nadd ctl+sh+3 to auto generate email for new QNAP projects`n`n08-03-17`nadded MOTS QNAP category, search and make`n`n07-26-17`nfixed Interactive search and Make project`n`n07-19-17`nstringleft 3 so search is for WOK not Mar`n`n07-12-17`nQNAP in all caps`n`n07-12-17`nno v1 needed for new projects`n`n07-11-17`nrecoded for qnap`n`n



return
GuiClose:

Nightwolf85
Posts: 302
Joined: 05 Feb 2017, 00:03

Re: 2nd gui window

Post by Nightwolf85 » 23 Aug 2017, 12:28

Sorry didn't notice the commas you have when adding to your GUI,

Code: Select all

Gui, MyGui:submit, nohide
Gui, MyGui:Font, s10
Gui, MyGui:Add, Edit, vscroll  +wrap h320 w270 +0x100 readonly,created Jul 1, 2014`nby Shawn Brady`n`nUpdates:`n08-23-17 Found type in link to folder in email body`n`n08-22-17`nv5.8 added path to new folder to clipboard`n`n08-21-17`nfixed search QNAP if proj not found`n`n08-17-17`nmake new QNAP proj, generate an email`n`n08-16-17`nMinAll minimizes ALL apps and desktop windows,then opens Gails Widget`n`n08-15-17`nfixed make new project with iSU names`n`n08-14-17`nadded open Features4\Producers if project not found otherwise`n`n08-10-17`nadd iPray category so new code for reading and writing`n`n08-08-17`nadd ctl+sh+3 to auto generate email for new QNAP projects`n`n08-03-17`nadded MOTS QNAP category, search and make`n`n07-26-17`nfixed Interactive search and Make project`n`n07-19-17`nstringleft 3 so search is for WOK not Mar`n`n07-12-17`nQNAP in all caps`n`n07-12-17`nno v1 needed for new projects`n`n07-11-17`nrecoded for qnap`n`n
Does that work?

sbrady
Posts: 105
Joined: 15 Mar 2014, 20:41
Location: Virginia Beach

Re: 2nd gui window

Post by sbrady » 23 Aug 2017, 12:31

still not working even with the show command

Code: Select all

Gui, MyGui:+Owner,
Gui, MyGui: Show, x600 y100 h350 w300
;WinExist("A")
;WinGetPos,,, sizeX, sizeY
;WinMove, (A_ScreenWidth/2)-(sizeX/2), (A_ScreenHeight/2)-(sizeY/2)
;Gui, MyGui, submit, nohide
;Gui, MyGui, Font, s10
Gui, MyGui, Add, Edit, vscroll  +wrap h320 w270 +0x100 readonly,created Jul 1, 2014`nby Shawn Brady`n`nUpdates:`n08-23-17 Found type in link to folder in email body`n`n08-22-17`nv5.8 added path to new folder to clipboard`n`n08-21-17`nfixed search QNAP if proj not found`n`n08-17-17`nmake new QNAP proj, generate an email`n`n08-16-17`nMinAll minimizes ALL apps and desktop windows,then opens Gails Widget`n`n08-15-17`nfixed make new project with iSU names`n`n08-14-17`nadded open Features4\Producers if project not found otherwise`n`n08-10-17`nadd iPray category so new code for reading and writing`n`n08-08-17`nadd ctl+sh+3 to auto generate email for new QNAP projects`n`n08-03-17`nadded MOTS QNAP category, search and make`n`n07-26-17`nfixed Interactive search and Make project`n`n07-19-17`nstringleft 3 so search is for WOK not Mar`n`n07-12-17`nQNAP in all caps`n`n07-12-17`nno v1 needed for new projects`n`n07-11-17`nrecoded for qnap`n`n

Nightwolf85
Posts: 302
Joined: 05 Feb 2017, 00:03

Re: 2nd gui window

Post by Nightwolf85 » 23 Aug 2017, 12:33

Change your Gui, MyGui, Add to the correct one I posted above (Gui, MyGui:Add, Edit)

Also for your submit and Font

sbrady
Posts: 105
Joined: 15 Mar 2014, 20:41
Location: Virginia Beach

Re: 2nd gui window

Post by sbrady » 23 Aug 2017, 12:35

figured it out, dont remember having to use : instead of , in creating the GUI

Code: Select all

Gui, MyGui: Show, x600 y100 h350 w300
WinExist("A")
WinGetPos,,, sizeX, sizeY
WinMove, (A_ScreenWidth/2)-(sizeX/2), (A_ScreenHeight/2)-(sizeY/2)
Gui, MyGui: submit, nohide
Gui, MyGui: Font, s10
Gui, MyGui: Add, Edit, vscroll  +wrap h320 w270 +0x100 readonly,created Jul 1, 2014`nby Shawn Brady`n`nUpdates:`n08-23-17 Found type in link to folder in email body`n`n08-22-17`nv5.8 added path to new folder to clipboard`n`n08-21-17`nfixed search QNAP if proj not found`n`n08-17-17`nmake new QNAP proj, generate an email`n`n08-16-17`nMinAll minimizes ALL apps and desktop windows,then opens Gails Widget`n`n08-15-17`nfixed make new project with iSU names`n`n08-14-17`nadded open Features4\Producers if project not found otherwise`n`n08-10-17`nadd iPray category so new code for reading and writing`n`n08-08-17`nadd ctl+sh+3 to auto generate email for new QNAP projects`n`n08-03-17`nadded MOTS QNAP category, search and make`n`n07-26-17`nfixed Interactive search and Make project`n`n07-19-17`nstringleft 3 so search is for WOK not Mar`n`n07-12-17`nQNAP in all caps`n`n07-12-17`nno v1 needed for new projects`n`n07-11-17`nrecoded for qnap`n`n

Post Reply

Return to “Ask for Help (v1)”