ChrisL Posted June 14, 2007 Posted June 14, 2007 Is it possible to highlight multiple rows in a listview? I would have thought given that there is a listview style called $LVS_SINGLESEL that multiple selections would be the default but apparently not? #include <GUIConstants.au3> #Include <GuiListView.au3> $Form1 = GUICreate("", 824, 663, 200, 24) $h_listview = GUICtrlCreateListView("OrderID|Name|DueBy|ReleaseTime|Job Status|", 4, 44, 816, 561) GuiCtrlSetFont(-1,14,400,2) _GUICtrlListViewSetColumnWidth ( $h_listview, 0, 150 ) _GUICtrlListViewSetColumnWidth ( $h_listview, 1, 150 ) _GUICtrlListViewSetColumnWidth ( $h_listview, 2, 200 ) _GUICtrlListViewSetColumnWidth ( $h_listview, 3, 200 ) _GUICtrlListViewSetColumnWidth ( $h_listview, 4, 100 ) GUICtrlCreateListViewItem("0|0|0|0|0",$h_listview) GUICtrlCreateListViewItem("1|1|1|1|1",$h_listview) GUICtrlCreateListViewItem("2|2|2|2|2",$h_listview) GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case Else ;; EndSwitch WEnd [u]Scripts[/u]Minimize gui to systray _ Fail safe source recoveryMsgbox UDF _ _procwatch() Stop your app from being closedLicensed/Trial software system _ Buffering Hotkeys_SQL.au3 ADODB.Connection _ Search 2d Arrays_SplashTextWithGraphicOn() _ Adjust Screen GammaTransparent Controls _ Eventlogs without the crap_GuiCtrlCreateFlash() _ Simple Interscript communication[u]Websites[/u]Curious Campers VW Hightops Lambert Plant Hire
evilertoaster Posted June 14, 2007 Posted June 14, 2007 The defualts for the GUICtrlCreateListView() function make it only single select. To override this try- $h_listview = GUICtrlCreateListView("OrderID|Name|DueBy|ReleaseTime|Job Status|", 4, 44, 816, 561,$LVS_SHOWSELALWAYS) Which manually tells it parameters for the style (not letting it assign the defaults)
ChrisL Posted June 14, 2007 Author Posted June 14, 2007 The defualts for the GUICtrlCreateListView() function make it only single select. To override this try- $h_listview = GUICtrlCreateListView("OrderID|Name|DueBy|ReleaseTime|Job Status|", 4, 44, 816, 561,$LVS_SHOWSELALWAYS) Which manually tells it parameters for the style (not letting it assign the defaults) Cool Thanks [u]Scripts[/u]Minimize gui to systray _ Fail safe source recoveryMsgbox UDF _ _procwatch() Stop your app from being closedLicensed/Trial software system _ Buffering Hotkeys_SQL.au3 ADODB.Connection _ Search 2d Arrays_SplashTextWithGraphicOn() _ Adjust Screen GammaTransparent Controls _ Eventlogs without the crap_GuiCtrlCreateFlash() _ Simple Interscript communication[u]Websites[/u]Curious Campers VW Hightops Lambert Plant Hire
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