can anyone take a look at this? I can't get it to delete an Item from the list.
FileChangeDir(@ScriptDir) GUICreate("zzz", 320, 260) $Listbox1 = GuiSetControl ("list", "", 10,20,300,200) $AddDir = GUISetControl ("button", "Add Dir", 10,210,100,20) GuiSetControlNotify() $DelItem = GUISetControl ("button", "Del Item", 110,210,100,20) GuiSetControlNotify() $ClearList = GUISetControl ("button", "Clear List", 210,210,100,20) GuiSetControlNotify() ;------------------------------------------------- While GUIMsg() > 0 if GuiRead () = $AddDir Then $dirpath = FileSelectFolder("Choose a directory.", "", 0) If @error <> 1 AND $dirpath <> "" Then GUISetControlData($Listbox1, $dirpath) EndIf EndIf if GuiRead () = $DelItem Then $selitem = GuiRead($Listbox1) ;;;missing code to remove the selected item from the list EndIf if GuiRead () = $ClearList Then GUISetControlData($Listbox1, "") EndIf Wend
If I use "ControlCommand" with the command "DelString", I can only delete the first Item in the List.
Although the Documentation is one of the best I ever saw, I can't find it.
I already searched this Forum and also yahoo.group.
It would also be nice to know: Is it possible to change the value of an item in the list? But thats not the way important as to delete one.
arctor




