Need help with multiple GUI Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
mrdon
Posts: 79
Joined: 08 Jul 2016, 01:43

Need help with multiple GUI

19 Jan 2017, 07:58

Hi

I need help to figure out whats wrong with the code below. When i click button "go to gui A", it does not show GUI, 2
same issue with other button. thank you

Code: Select all

#NoEnv
#Warn
#SingleInstance Force
SetWorkingDir %A_ScriptDir%

Gui, Add, Button, ga_submit x0 y0 , Go to Gui A
Gui, Add, Button, gb_submit x0 y+1, Go to Gui B
Gui, Add, Button, gc_submit x0 y+1, Go to Gui C
Gui, Add, Button, gd_submit x0 y+1, Go to Gui D
Gui Show, w100 h100, This is Main Window
return

Gui, 2: Add, text, x0 y0, This is Gui A
Gui, 2: Add, Button, x0 y+1, ga_back Back to Main

Gui, 3: Add, text, x0 y0, This is Gui B
Gui, 3: Add, Button, x0 y+1, gb_back Back to Main

Gui, 4: Add, text, x0 y0, This is Gui C
Gui, 4: Add, Button, x0 y+1, gc_back Back to Main

Gui, 5: Add, text, x0 y0, This is Gui D
Gui, 5: Add, Button, x0 y+1, gd_back Back to Main

a_submit:
Gui, 1:Hide
Gui, 2:Show, w100 h100, GUI A
return

a_back: 
Gui, 2:Destroy
Gui, 1:Show
return

b_submit:
Gui, 1:Hide
Gui, 3:Show, w100 h100, GUI B
return

b_back:
Gui, 3:Destroy
Gui, 1:Show 
return

c_submit:
Gui, 1:Hide
Gui, 4:Show, w100 h100, GUI C
return

c_back:
Gui, 4:Destroy
Gui, 1:Show 
return

d_submit:
Gui, 1:Hide
Gui, 5:Show, w100 h100, GUI D
return

d_back:
Gui, 5:Destroy
Gui, 1:Show
return

wolf_II
Posts: 2688
Joined: 08 Feb 2015, 20:55

Re: Need help with multiple GUI

19 Jan 2017, 08:12

Try this:
  • 5x replaced w100 => w200, so I can see the title
  • 4x replaced Destroy with Hide to allow several successive clicks on eg "Go to Gui A"
  • 4x moved a comma to the correct place
  • 1x moved Return a few lines down

Code: Select all

#NoEnv
#Warn
#SingleInstance Force
SetWorkingDir %A_ScriptDir%

Gui, Add, Button, ga_submit x0 y0 , Go to Gui A
Gui, Add, Button, gb_submit x0 y+1, Go to Gui B
Gui, Add, Button, gc_submit x0 y+1, Go to Gui C
Gui, Add, Button, gd_submit x0 y+1, Go to Gui D
Gui Show, w200 h100, This is Main Window

Gui, 2: Add, text, x0 y0, This is Gui A
Gui, 2: Add, Button, x0 y+1 ga_back, Back to Main

Gui, 3: Add, text, x0 y0, This is Gui B
Gui, 3: Add, Button, x0 y+1 gb_back, Back to Main

Gui, 4: Add, text, x0 y0, This is Gui C
Gui, 4: Add, Button, x0 y+1 gc_back, Back to Main

Gui, 5: Add, text, x0 y0, This is Gui D
Gui, 5: Add, Button, x0 y+1 gd_back, Back to Main
return

a_submit:
Gui, 1:Hide
Gui, 2:Show, w200 h100, GUI A
return

a_back:
Gui, 2:Hide
Gui, 1:Show
return

b_submit:
Gui, 1:Hide
Gui, 3:Show, w200 h100, GUI B
return

b_back:
Gui, 3:Hide
Gui, 1:Show
return

c_submit:
Gui, 1:Hide
Gui, 4:Show, w200 h100, GUI C
return

c_back:
Gui, 4:Hide
Gui, 1:Show
return

d_submit:
Gui, 1:Hide
Gui, 5:Show, w200 h100, GUI D
return

d_back:
Gui, 5:Hide
Gui, 1:Show
return

I hope that helps.
Just a few minor corrections and it worked as you probably intended.
mrdon
Posts: 79
Joined: 08 Jul 2016, 01:43

Re: Need help with multiple GUI

19 Jan 2017, 08:58

wolf_II wrote:Try this:
  • 5x replaced w100 => w200, so I can see the title
  • 4x replaced Destroy with Hide to allow several successive clicks on eg "Go to Gui A"
  • 4x moved a comma to the correct place
  • 1x moved Return a few lines down

Code: Select all

#NoEnv
#Warn
#SingleInstance Force
SetWorkingDir %A_ScriptDir%

Gui, Add, Button, ga_submit x0 y0 , Go to Gui A
Gui, Add, Button, gb_submit x0 y+1, Go to Gui B
Gui, Add, Button, gc_submit x0 y+1, Go to Gui C
Gui, Add, Button, gd_submit x0 y+1, Go to Gui D
Gui Show, w200 h100, This is Main Window

Gui, 2: Add, text, x0 y0, This is Gui A
Gui, 2: Add, Button, x0 y+1 ga_back, Back to Main

Gui, 3: Add, text, x0 y0, This is Gui B
Gui, 3: Add, Button, x0 y+1 gb_back, Back to Main

Gui, 4: Add, text, x0 y0, This is Gui C
Gui, 4: Add, Button, x0 y+1 gc_back, Back to Main

Gui, 5: Add, text, x0 y0, This is Gui D
Gui, 5: Add, Button, x0 y+1 gd_back, Back to Main
return

a_submit:
Gui, 1:Hide
Gui, 2:Show, w200 h100, GUI A
return

a_back:
Gui, 2:Hide
Gui, 1:Show
return

b_submit:
Gui, 1:Hide
Gui, 3:Show, w200 h100, GUI B
return

b_back:
Gui, 3:Hide
Gui, 1:Show
return

c_submit:
Gui, 1:Hide
Gui, 4:Show, w200 h100, GUI C
return

c_back:
Gui, 4:Hide
Gui, 1:Show
return

d_submit:
Gui, 1:Hide
Gui, 5:Show, w200 h100, GUI D
return

d_back:
Gui, 5:Hide
Gui, 1:Show
return

I hope that helps.
Just a few minor corrections and it worked as you probably intended.

It works. thank you. however i try to apply this into my main script which contains about 21 gui in total, however it is only working with gui 2. the rest of the gui, when i hit back button, it goes to gui 1 but does not hide the gui. below is the code. it is basically the same. it just very long. thank you.

Code: Select all

#SingleInstance Force
SetWorkingDir %A_ScriptDir%

;~READ FROM INI FILE
IniRead,firstSkill,%A_ScriptDir%\key.ini,key,key1
IniRead,secondSkill,%A_ScriptDir%\key.ini,key,Key2
IniRead,thirdSkill,%A_ScriptDir%\key.ini,key,Key3
IniRead,fourthSkill,%A_ScriptDir%\key.ini,key,Key4
IniRead,fifthSkill,%A_ScriptDir%\key.ini,key,Key5
IniRead,ulti,%A_ScriptDir%\key.ini,key,Key6

IniRead,itemone,%A_ScriptDir%\key.ini,item,item1
IniRead,itemsecond,%A_ScriptDir%\key.ini,item,item2
IniRead,itemthird,%A_ScriptDir%\key.ini,item,item3
IniRead,itemfourth,%A_ScriptDir%\key.ini,item,item4
IniRead,itemfifth,%A_ScriptDir%\key.ini,item,item5
IniRead,itemsix,%A_ScriptDir%\key.ini,item,item6

;~ MAIN GUI
Gui Add, Picture, gaxesubmit x10 y72 w180 h100, %A_ScriptDir%\img\axe.png
Gui Add, Picture, gbloodseekersubmit x+1 y72 w180 h100, %A_ScriptDir%\img\bloodseeker.png
Gui Add, Picture, gbrewmastersubmit x+1 y72 w180 h100, %A_ScriptDir%\img\brewmaster.png
Gui Add, Picture, gcentaursubmit x+1 y72 w180 h100, %A_ScriptDir%\img\centaur-warchief.png
Gui Add, Picture, gcrystalmaidensubmit x+1 y72 w180 h100, %A_ScriptDir%\img\crystal-maiden.png
Gui Add, Picture, ghuskarsubmit x10 y175 w180 h100, %A_ScriptDir%\img\huskar.png
Gui Add, Picture, gjakirosubmit x+1 y175 w180 h100, %A_ScriptDir%\img\jakiro.png
Gui Add, Picture, glegioncommandersubmit x+1 y175 w180 h100, %A_ScriptDir%\img\legion-commander.png
Gui Add, Picture, glinasubmit x+1 y175 w180 h100, %A_ScriptDir%\img\lina.png
Gui Add, Picture, glionsubmit x+1 y175 w180 h100, %A_ScriptDir%\img\lion.png
Gui Add, Picture, glonedruidsubmit x10 y278 w180 h100, %A_ScriptDir%\img\lone-druid.png
Gui Add, Picture, gmeeposubmit x+1 y278 w180 h100, %A_ScriptDir%\img\meepo.png
Gui Add, Picture, gphantomassasinsubmit x+1 y278 w180 h100, %A_ScriptDir%\img\phantom-assassin.png
Gui Add, Picture, gpucksubmit x+1 y278 w180 h100, %A_ScriptDir%\img\puck.png
Gui Add, Picture, grubbicksubmit x+1 y278 w180 h100, %A_ScriptDir%\img\rubbick.png
Gui Add, Picture, gslardarsubmit x10 y381 w180 h100, %A_ScriptDir%\img\slardar.png
Gui Add, Picture, gstormsubmit x+1 y381 w180 h100, %A_ScriptDir%\img\storm-spirit.png
Gui Add, Picture, gsvensubmit x+1 y381 w180 h100, %A_ScriptDir%\img\sven.png
Gui Add, Picture, gtinkersubmit x+1 y381 w180 h100, %A_ScriptDir%\img\tinker.png
Gui Add, Picture, gzeussubmit x+1 y381 w180 h100, %A_ScriptDir%\img\zeus.png
SoundPlay, %A_ScriptDir%\sound\dota2.wav
Gui Show, w920 h500, Window

;~SECOND GUI
Gui, 2:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\axe.png
Gui, 2:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 2:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 2:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 2:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 3:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\bloodseeker.png
Gui, 3:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 3:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 3:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 3:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 4:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\brewmaster.png
Gui, 4:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 4:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 4:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 4:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 5:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\centaur-warchief.png
Gui, 5:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 5:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 5:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 5:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 6:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\crystal-maiden.png
Gui, 6:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 6:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 6:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 6:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 7:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\huskar.png
Gui, 7:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 7:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 7:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 7:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 8:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\jakiro.png
Gui, 8:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 8:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 8:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 8:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 9:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\legion-commander.png
Gui, 9:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 9:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 9:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 9:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 10:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\lina.png
Gui, 10:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 10:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 10:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 10:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 11:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\lion.png
Gui, 11:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 11:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 11:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 11:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 12:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\lone-druid.png
Gui, 12:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 12:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 12:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 12:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 13:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\meepo.png
Gui, 13:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 13:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 13:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 13:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 14:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\phantom-assassin.png
Gui, 14:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 14:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 14:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 14:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 15:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\puck.png
Gui, 15:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 15:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 15:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 15:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 16:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\rubbick.png
Gui, 16:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 16:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 16:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 16:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 17:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\slardar.png
Gui, 17:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 17:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 17:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 17:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 18:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\storm-spirit.png
Gui, 18:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 18:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 18:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 18:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 19:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\sven.png
Gui, 19:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 19:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 19:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 19:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 20:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\tinker.png
Gui, 20:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 20:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 20:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 20:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection

Gui, 21:Add, Picture, x0 y0 w256 h144, %A_ScriptDir%\img\zeus.png
Gui, 21:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 21:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 21:Add, Text, x0 y+1 w120 h23 +0x200, Press F = Full Combo
Gui, 21:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection
Return


axesubmit:
Gui, 1:Hide
Gui, 2:show, w257 h381, axe
SoundPlay, %A_ScriptDir%\sound\axe.wav
return

axeback:
Gui, 2:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

bloodseekersubmit:
Gui, 1:Hide
Gui, 3:show, w257 h381, bloodseeker
SoundPlay, %A_ScriptDir%\sound\bloodseeker.wav
return

bloodseekerback:
Gui, 3:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

brewmastersubmit:
Gui, 1:Hide
Gui, 4:show, w257 h381, brewmaster
SoundPlay, %A_ScriptDir%\sound\brewmaster.wav
return

brewmasterback:
Gui, 4:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

centaursubmit:
Gui, 1:Hide
Gui, 5:show, w257 h381, centaur
SoundPlay, %A_ScriptDir%\sound\centaur.wav
return

centaurback:
Gui, 5:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

crystalmaidensubmit:
Gui, 1:Hide
Gui, 6:show, w257 h381, crystalmaiden
SoundPlay, %A_ScriptDir%\sound\crystalmaiden.wav
return

crystalmaidenback:
Gui, 6:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

huskarsubmit:
Gui, 1:Hide
Gui, 7:show, w257 h381, huskar
SoundPlay, %A_ScriptDir%\sound\huskar.wav
return

huskarback:
Gui, 7:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

jakirosubmit:
Gui, 1:Hide
Gui, 8:show, w257 h381, jakiro
SoundPlay, %A_ScriptDir%\sound\jakiro.wav
return

jakiroback:
Gui, 8:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

legioncommandersubmit:
Gui, 1:Hide
Gui, 9:show, w257 h381, legion commander
SoundPlay, %A_ScriptDir%\sound\legioncommander.wav
return

legioncommanderback:
Gui, 9:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

linasubmit:
Gui, 1:Hide
Gui, 10:show, w257 h381, lina
SoundPlay, %A_ScriptDir%\sound\lina.wav
return

linaback:
Gui, 10:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

lionsubmit:
Gui, 1:Hide
Gui, 11:show, w257 h381, lion
SoundPlay, %A_ScriptDir%\sound\lion.wav
return

lionback:
Gui, 11:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

lonedruidsubmit:
Gui, 1:Hide
Gui, 12:show, w257 h381, lone druid
SoundPlay, %A_ScriptDir%\sound\lonedruid.wav
return

lonedruidback:
Gui, 12:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

meeposubmit:
Gui, 1:Hide
Gui, 13:show, w257 h381, meepo
SoundPlay, %A_ScriptDir%\sound\meepo.wav
return

meepoback:
Gui, 13:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

phantomassasinsubmit:
Gui, 1:Hide
Gui, 14:show, w257 h381, phantom assasin
SoundPlay, %A_ScriptDir%\sound\phantomassasin.wav
return

phantomassasinback:
Gui, 14:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

pucksubmit:
Gui, 1:Hide
Gui, 15:show, w257 h381, puck
SoundPlay, %A_ScriptDir%\sound\puck.wav
return

puckback:
Gui, 15:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

rubbicksubmit:
Gui, 1:Hide
Gui, 16:show, w257 h381, rubbick
SoundPlay, %A_ScriptDir%\sound\rubbick.wav
return

rubbickback:
Gui, 16:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

slardarsubmit:
Gui, 1:Hide
Gui, 17:show, w257 h381, slardar
SoundPlay, %A_ScriptDir%\sound\slardar.wav
return

slardarback:
Gui, 17:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

stormsubmit:
Gui, 1:Hide
Gui, 18:show, w257 h381, storm
SoundPlay, %A_ScriptDir%\sound\storm.wav
return

stormback:
Gui, 18:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

svensubmit:
Gui, 1:Hide
Gui, 19:show, w257 h381, sven
SoundPlay, %A_ScriptDir%\sound\sven.wav
return

svenback:
Gui, 19:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

tinkersubmit:
Gui, 1:Hide
Gui, 20:show, w257 h381, tinker
SoundPlay, %A_ScriptDir%\sound\tinker.wav
return

tinkerback:
Gui, 20:Hide
Gui, 1:show
SoundPlay, %A_ScriptDir%\sound\dota2.wav
return

zeussubmit:
Gui, 1:Hide
Gui, 21:show, w257 h381, zeus
SoundPlay, %A_ScriptDir%\sound\zeus.wav
return

~end::exitapp
wolf_II
Posts: 2688
Joined: 08 Feb 2015, 20:55

Re: Need help with multiple GUI  Topic is solved

19 Jan 2017, 10:30

check your gLabels:
you have 20 copies of Gui, ##:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection
you want 20 variations like Gui, ##:Add, Button, x70 y350 w120 h23 g$$$$$$$back, Back To Hero Selection < $$$$ need to be different each time.
Also insert one more of the subs, zeusback: is missing.
I hope that helps.
mrdon
Posts: 79
Joined: 08 Jul 2016, 01:43

Re: Need help with multiple GUI

19 Jan 2017, 10:34

wolf_II wrote:check your gLabels:
you have 20 copies of Gui, ##:Add, Button, x70 y350 w120 h23 gaxeback, Back To Hero Selection
you want 20 variations like Gui, ##:Add, Button, x70 y350 w120 h23 g$$$$$$$back, Back To Hero Selection < $$$$ need to be different each time.
Also insert one more of the subs, zeusback: is missing.
I hope that helps.
dammit, thanks bro..silly of me..
its ok now... :D
asad41163
Posts: 268
Joined: 29 Jul 2014, 14:31

Re: Need help with multiple GUI

22 Jan 2018, 03:12

Hi mrdon
Please put the final code until we all learn
thanks in advance

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: gongnl, jaka1, Rohwedder and 260 guests