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 

child Gui not created second time

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



Joined: 08 Oct 2006
Posts: 67
Location: denmark

PostPosted: Wed May 21, 2008 11:38 am    Post subject: child Gui not created second time Reply with quote

Sorry about the problematic subject, but I'm uncertain how to describe this:

I have a GUI with a listview in it, in that listview I can click on a column and start up another GUI:

Code:


MyListView:
if A_GuiEvent = DoubleClick
{
listviewrow := A_EventInfo
    LV_GetText(selectedRow, A_EventInfo)  ; Get the text from the row's first field.
    GoSub ChangeSelection
}
Return


The ChangeSelection sub draws a new gui

Gui 2:Default

Gui Color, FFFFFF                 
Gui +FFFF00   
GuiControl, -default, OK

Gui Show, X0 Y0 w300 h100, selectionchanger ;
Gui, Add, Text,,OPTAGELSE I GANGE . %NewHotKeyName%

Gui, Add, Button,gButtonStartAgain x40 y60,Start Forfra

Gui, Add, Button,gButtonStopRecording  x120 y60,Stop Optagelsen



Return


in that new GUI if I close the window and then I double click on the listview again then the GUI gets created again, which is fine. If I click on one of the buttons and then close the window and try to create it again by double clicking in my listview nothing happens. I suppose it must be one of the subprocesses that got called by clicking on the buttons but can't find which currently, I was rather hoping that there was some way to use GuiClose to take care of this problem.

I've tried to just put GuiClose: in but that didn't do anything, I don't want to do GuiClose:
ExitApp,
because I don't want to exit the whole app.

I don't mind if I end up destroying both GUIs just as long as when I start the one with the list control up again I can double click on that list control and start up my second gui.


Last edited by pantagruel on Mon Jun 02, 2008 10:29 am; edited 1 time in total
Back to top
View user's profile Send private message
imapow



Joined: 13 Mar 2008
Posts: 162
Location: Trøndelag, Norway

PostPosted: Wed May 21, 2008 12:14 pm    Post subject: Reply with quote

dude, use [code ][/code ]

Code:

MyListView:
if A_GuiEvent = DoubleClick
{
listviewrow := A_EventInfo
LV_GetText(selectedRow, A_EventInfo) ; Get the text from the row's first field.
GoSub ChangeSelection
}
Return


The ChangeSelection sub draws a new gui

Gui 2:Default

Gui Color, FFFFFF
Gui +FFFF00
GuiControl, -default, OK

Gui Show, X0 Y0 w300 h100, selectionchanger ;
Gui, Add, Text,,OPTAGELSE I GANGE . %NewHotKeyName%

Gui, Add, Button,gButtonStartAgain x40 y60,Start Forfra

Gui, Add, Button,gButtonStopRecording x120 y60,Stop Optagelsen



Return

_________________
-._.-¨¯¨-._.-IM@PΩW-._.-¨¯¨-._.-
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   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