Jump to content

Adding info under columns in lists


Recommended Posts

Well, I have found 2 functions that should be helpful, at least one of them since I am using columns, _GUICtrlListAddItem & _GUICtrlListInsertItem

_GUICtrlListInsertItem($h_listbox, $s_text[, $i_index=-1]) doesn't seem to work for me, maybe my syntax is wrong

I tried _GUICtrlListInsertItem($list_test, "Test" , 0)

$list_test being the name of my list view and "Test" being the text to insert into a column, and 0 being the column ID

Link to comment
Share on other sites

Well, I have found 2 functions that should be helpful, at least one of them since I am using columns, _GUICtrlListAddItem & _GUICtrlListInsertItem

_GUICtrlListInsertItem($h_listbox, $s_text[, $i_index=-1]) doesn't seem to work for me, maybe my syntax is wrong

I tried _GUICtrlListInsertItem($list_test, "Test" , 0)

$list_test being the name of my list view and "Test" being the text to insert into a column, and 0 being the column ID

Do you get any type of error after the call? Your syntax is correct, but without seeing more code, it will be difficult to help you.
Auto3Lib: A library of over 1200 functions for AutoIt
Link to comment
Share on other sites

#include <GuiConstants.au3>
#Include <GuiList.au3>
#Include <GuiListView.au3>

GuiCreate("test", 300, 300,-1, -1)

$Button_1 = GuiCtrlCreateButton("Button2", 110, 250, 60, 30)

$list_test = GUICtrlCreateListView ("Test1|Test2|Test3",0,0,300,240);,$LVS_SORTDESCENDING)
GUICtrlSendMsg($list_test, $LVM_SETEXTENDEDLISTVIEWSTYLE, $LVS_EX_GRIDLINES, $LVS_EX_GRIDLINES)
GUICtrlSendMsg($list_test, $LVM_SETEXTENDEDLISTVIEWSTYLE, $LVS_EX_FULLROWSELECT, $LVS_EX_FULLROWSELECT)

GuiSetState()
While 1
    $msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
        ExitLoop
    Case $msg = $Button_1
        _GUICtrlListInsertItem($list_test, "Test" , 0)
    Case Else
;;;
    EndSelect
WEnd

Edited by Jabberwock
Link to comment
Share on other sites

$list_test being the name of my list view and "Test" being the text to insert into a column, and 0 being the column ID

if it's a "list vew" your using the wrong functions.

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

#include <GuiConstants.au3>
#Include <GuiList.au3>
#Include <GuiListView.au3>

GuiCreate("test", 300, 300,-1, -1)

$Button_1 = GuiCtrlCreateButton("Button2", 110, 250, 60, 30)

$list_test = GUICtrlCreateListView ("Test1|Test2|Test3",0,0,300,240);,$LVS_SORTDESCENDING)
GUICtrlSendMsg($list_test, $LVM_SETEXTENDEDLISTVIEWSTYLE, $LVS_EX_GRIDLINES, $LVS_EX_GRIDLINES)
GUICtrlSendMsg($list_test, $LVM_SETEXTENDEDLISTVIEWSTYLE, $LVS_EX_FULLROWSELECT, $LVS_EX_FULLROWSELECT)

GuiSetState()
While 1
    $msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
        ExitLoop
    Case $msg = $Button_1
        _GUICtrlListInsertItem($list_test, "Test" , 0)
    Case Else
;;;
    EndSelect
WEnd
created a listview

$list_test = GUICtrlCreateListView ("Test1|Test2|Test3",0,0,300,240);,$LVS_SORTDESCENDING)
oÝ÷ ÚÚâyÛh±ë]jÖ¢¶¥Ë[£î¶ö«¦åz+¢¶¥ËoìºÚ"µÍBWÑÕRPÝÝ[Ù][J ÌÍÛÝÝÝ    ][ÝÕÝ    ][ÝÈ
BoÝ÷ ÚwvÚ.±éb²Ûâ{îËb¢v®¶­s`¥ôuT7G&ÄÆ7EfWtç6W'DFVÒb33c¶Æ7E÷FW7BÂÂgV÷CµFW7BgV÷C²
Edited by gafrost

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...