bshoenhair Posted December 27, 2004 Share Posted December 27, 2004 I have a listview in my GUI and I have a couple of issues I am unable to tackle: 1. How can I remove the selected item(s) from the gui listview ? 2. How can I hide a column in the gui listview ? I tried a blank string that should work but it doesn't, seems that extra spaces are added as a default so you are unable to hide a column. Link to comment Share on other sites More sharing options...
LOULOU Posted December 27, 2004 Share Posted December 27, 2004 (edited) For deleting an item in a listview$LVM_DELETEITEM = $LVM_DELETEITEM = 0x1008GuiCtrlSendMsg($listview, $LVM_DELETEITEM, current_selection , 0)For the second question go on microsoft website at the following adresshttp://msdn.microsoft.com/library/default...._deleteitem.aspon the left part of the screen you have an explanation about all LV_xxx command I am sure you find sure to find what you search for Edited December 27, 2004 by LOULOU Link to comment Share on other sites More sharing options...
bshoenhair Posted December 27, 2004 Author Share Posted December 27, 2004 @LOULOU Where did you find '0x1008' that is related to $LVM_DELETEITEM ? I checked but could not find any info on how to hide a column. Link to comment Share on other sites More sharing options...
bshoenhair Posted December 27, 2004 Author Share Posted December 27, 2004 OK, I can now delete the selected item with $LVM_DELETEITEM = 0x1008 $ItemCount = ControlListView("listview items","",$listview,"GetItemCount") For $i = 0 To $ItemCount - 1 If ControlListView("listview items","",$listview,"IsSelected",$i) Then GuiCtrlSendMsg($listview, $LVM_DELETEITEM,$i,0) $i = $i - 1 EndIf Next But still can't figure out how to hide a column Any help appreciated. Link to comment Share on other sites More sharing options...
Holger Posted December 27, 2004 Share Posted December 27, 2004 (edited) ! You can NOT hide a column but only DELETE it !!!$LVM_DELETECOLUMN = 0x101C ... $col = 3 GUICtrlSendMsg($listview,$LVM_DELETECOLUMN,$col,0)So long...Edit: if you are looking for the values for the commands try searching via google for "winuser.h" or "commctrl.h". Edited December 27, 2004 by Holger Old project:GUI/Tray menu with icons and colors Other old stuff:IconFileScanner, TriState/ThreeState GUI TreeView, GUI ContextMenu created out of a TreeView Link to comment Share on other sites More sharing options...
Developers Jos Posted December 27, 2004 Developers Share Posted December 27, 2004 ! You can NOT hide a column but only DELETE it !!!$LVM_DELETECOLUMN = 0x1028 ... $col = 3 GUICtrlSendMsg($listview,$LVM_DELETECOLUMN,$col,0)So long...Edit: if you are looking for the values for the commands try searching via google for "winuser.h" or "commctrl.h".<{POST_SNAPBACK}>would setting the columnwidth to 0 do it ?(LVM_SETCOLUMNWIDTH) SciTE4AutoIt3 Full installer Download page  - Beta files    Read before posting   How to post scriptsource   Forum etiquette Forum Rules  Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Holger Posted December 27, 2004 Share Posted December 27, 2004 (edited) @JdeB: oohhh, sorry...yep, great idea Thanks for info Forgot: $LVM_SETCOLUMNWIDTH = 0x101E ... $col = 3 GUICtrlSendMsg($listview,$LVM_SETCOLUMNWIDTH,$col,0) Edited December 27, 2004 by Holger Old project:GUI/Tray menu with icons and colors Other old stuff:IconFileScanner, TriState/ThreeState GUI TreeView, GUI ContextMenu created out of a TreeView Link to comment Share on other sites More sharing options...
bshoenhair Posted December 27, 2004 Author Share Posted December 27, 2004 @JdeB: oohhh, sorry...yep, great idea Thanks for info Forgot:$LVM_SETCOLUMNWIDTH = 0x1030 ... $col = 3 GUICtrlSendMsg($listview,$LVM_SETCOLUMNWIDTH,$col,0)<{POST_SNAPBACK}>This is not working for me, anyone else experiencing this ? Link to comment Share on other sites More sharing options...
Holger Posted December 27, 2004 Share Posted December 27, 2004 (edited) change to this: $LVM_SETCOLUMNWIDTH = 0x101E $LVM_DELETECOLUMN = 0x101C Sorry, my mistake :"> Edited December 27, 2004 by Holger Old project:GUI/Tray menu with icons and colors Other old stuff:IconFileScanner, TriState/ThreeState GUI TreeView, GUI ContextMenu created out of a TreeView Link to comment Share on other sites More sharing options...
bshoenhair Posted December 28, 2004 Author Share Posted December 28, 2004 Great, thanks thanks for the help. Link to comment Share on other sites More sharing options...
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