mikkokh Posted February 1, 2008 Posted February 1, 2008 Hi. What is wrong about this script? - Should "GUICtrlSetData" even work on this job, or have I misunderstand guide of Help file? Have I missed something? #include <GuiConstants.au3> $window = GuiCreate("Test Win", 150, 200, -1, -1) $listView = GuiCtrlCreateListView("", 10, 10, 130, 180, -1, $LVS_EX_FULLROWSELECT + $LVS_EX_GRIDLINES) GUICtrlSetData($listView, "test") GuiSetState(@SW_SHOW, $window) While Not (GUIGetMsg() = $GUI_EVENT_CLOSE) ;;; WEnd Thanks for help! - miXza-81 -
GaryFrost Posted February 1, 2008 Posted February 1, 2008 #include <GuiConstantsEx.au3> #include <ListViewConstants.au3> #include <GuiListView.au3> $window = GuiCreate("Test Win", 150, 200, -1, -1) $listView = GuiCtrlCreateListView("", 10, 10, 130, 180, -1, $LVS_EX_FULLROWSELECT + $LVS_EX_GRIDLINES) _GUICtrlListView_AddColumn($listView, "Column") _GUICtrlListView_AddColumn($listView, "New Column 2", 100) ;~ GUICtrlSetData($listView, "test") ; un-comment this and it will change the header column 1 or index 0 GuiSetState(@SW_SHOW, $window) While Not (GUIGetMsg() = $GUI_EVENT_CLOSE) ;;; WEnd SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference.
mikkokh Posted February 1, 2008 Author Posted February 1, 2008 #include <GuiConstantsEx.au3> #include <ListViewConstants.au3> #include <GuiListView.au3> $window = GuiCreate("Test Win", 150, 200, -1, -1) $listView = GuiCtrlCreateListView("", 10, 10, 130, 180, -1, $LVS_EX_FULLROWSELECT + $LVS_EX_GRIDLINES) _GUICtrlListView_AddColumn($listView, "Column") _GUICtrlListView_AddColumn($listView, "New Column 2", 100) ;~ GUICtrlSetData($listView, "test") ; un-comment this and it will change the header column 1 or index 0 GuiSetState(@SW_SHOW, $window) While Not (GUIGetMsg() = $GUI_EVENT_CLOSE) ;;; WEndThank you. - Now I understand what "GUICtrlSetData" relly do for ListView... So, there is not simplier way to make several Columns at same time after "GuiCtrlCreateListView" function? Perhaps I should do that job with combination of Array, loop and that "_GUICtrlListView_AddColumn" function... - miXza-81 -
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