Apzo Posted February 18, 2005 Posted February 18, 2005 Hello all I'd like to fill an input box with the content of a previously generated ListViewItem. I tried : #include <GUIConstants.au3> Opt("GUIOnEventMode", 1) $MAING = GUICreate("", 250, 222) GUISetOnEvent($GUI_EVENT_CLOSE, "CLOSEClicked") $user = GuiCtrlCreateInput("", 0, 0, 100, 20) $online = GuiCtrlCreateListView ("Label", 0, 22, 200, 130 ) GuiCtrlCreateListViewItem("toto", $online) GUICtrlSetOnEvent(-1, "DumpData") GUISetState(@SW_SHOW) While 1 Sleep(100000) Wend Func CLOSEClicked() Exit EndFunc Func DumpData () MsbBox(0, "", "Hey, I'm alive !!"); test purpose $Data = GUICtrlRead(@GUI_CtrlId) GUICtrlSetData($user, $Data) EndFunc Problem : when I select "toto" in my list, the input box stays empty. Of course this script is very simple, actually I have a listview filled with listviewitems and I don't know how many. I need GUIOnEventMode set to 1. Any idea ? Thanks in advance, Apzo. All the pop3 functions.Rsync your files on your USB key (or anywhere else)
Triton Posted February 18, 2005 Posted February 18, 2005 With GuiCtrlCreateListViewItem("toto", $online) you have to guictrlread the Listview GUICtrlRead($online) = $toto Then that poses another isue, you put that in a loop and it will loop forever unless somehow you unselect it. I really not entirely sure how to set that up, maybe this will spark something Triton
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now