rootx Posted March 6, 2017 Posted March 6, 2017 (edited) I would like to hide the header in the listview, but I did not find anything in the help and in the forum, you have some advice, thanks. Edited March 7, 2017 by rootx
Moderators Melba23 Posted March 6, 2017 Moderators Posted March 6, 2017 rootx, So you missed the $LVS_NOCOLUMNHEADER style? M23 rootx and Ambient 2 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
rootx Posted March 7, 2017 Author Posted March 7, 2017 13 hours ago, Melba23 said: rootx, So you missed the $LVS_NOCOLUMNHEADER style? M23 Thx Melba23, but why it doesn't work when I using the icons? I read the help, but I did not understand why it happens. Thx expandcollapse popup#include <GUIConstantsEx.au3> #include <GuiImageList.au3> #include <GuiListView.au3> #include <WindowsConstants.au3> Global $g_hListView Example() Func Example() Local $hGUI, $hImage $hGUI = GUICreate("(UDF Created) ListView Create", 400, 300) $g_hListView = _GUICtrlListView_Create($hGUI, "test header", 2, 2, 394, 268);<--- $LVS_NOCOLUMNHEADER -- $LVS_SHOWSELALWAYS ????? _GUICtrlListView_SetExtendedListViewStyle($g_hListView, BitOR($LVS_EX_GRIDLINES, $LVS_EX_FULLROWSELECT, $LVS_EX_SUBITEMIMAGES)) GUISetState(@SW_SHOW) ; Load images $hImage = _GUIImageList_Create() _GUIImageList_Add($hImage, _GUICtrlListView_CreateSolidBitMap($g_hListView, 0xFF0000, 16, 16)) _GUIImageList_Add($hImage, _GUICtrlListView_CreateSolidBitMap($g_hListView, 0x00FF00, 16, 16)) _GUIImageList_Add($hImage, _GUICtrlListView_CreateSolidBitMap($g_hListView, 0x0000FF, 16, 16)) _GUICtrlListView_SetImageList($g_hListView, $hImage, 1) ; Add columns _GUICtrlListView_InsertColumn($g_hListView, 0, "Column 1", 100) _GUICtrlListView_InsertColumn($g_hListView, 1, "Column 2", 100) _GUICtrlListView_InsertColumn($g_hListView, 2, "Column 3", 100) ; Add items _GUICtrlListView_AddItem($g_hListView, "Row 1: Col 1", 0) _GUICtrlListView_AddSubItem($g_hListView, 0, "Row 1: Col 2", 1) _GUICtrlListView_AddSubItem($g_hListView, 0, "Row 1: Col 3", 2) _GUICtrlListView_AddItem($g_hListView, "Row 2: Col 1", 1) _GUICtrlListView_AddSubItem($g_hListView, 1, "Row 2: Col 2", 1) _GUICtrlListView_AddItem($g_hListView, "Row 3: Col 1", 2) ; Loop until the user exits. Do Until GUIGetMsg() = $GUI_EVENT_CLOSE GUIDelete() EndFunc ;==>Example https://www.autoitscript.com/autoit3/docs/libfunctions/_GUICtrlListView_Create.htm
InnI Posted March 7, 2017 Posted March 7, 2017 @rootx $g_hListView = _GUICtrlListView_Create($hGUI, "test header", 2, 2, 394, 268, BitOR($LVS_DEFAULT, $LVS_NOCOLUMNHEADER)) rootx 1
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