Jump to content
Sign in to follow this  
grasshopper3

checkbox inside a listview, possible & how?

Recommended Posts

grasshopper3

I would like to create a list view where one of the elements of an item and a usable checkbox. Is this possible?

Share this post


Link to post
Share on other sites
KaFu
grasshopper3

i found what you are talking about but i am unable to get it working. Could you give me some code with a working item. I tried..

#include <GUIListView.au3>

$gui = GuiCreate("listview",400,300)

$sHeaderText = "Drive|Device|Password|Share|Share Path"
$handle = _GUICtrlListView_Create($gui,$sHeaderText,10,10,380,280,$LVS_EDITLABELS,$LVS_EX_CHECKBOXES)
$view = _GUICtrlListView_AddItem($handle, "hello|world")


GuiSetState()

While 1
    $msg=GuiGetMsg()
    If $msg=-3 Then Exit
Wend

Share this post


Link to post
Share on other sites
Yashied
grasshopper3

_GUICtrlListView_SetExtendedListViewStyle($handle, $LVS_EX_CHECKBOXES)

This does do what I wanted, but is there a way to put the check box in any other column besides the first column?

Share this post


Link to post
Share on other sites
KaFu

This does do what I wanted, but is there a way to put the check box in any other column besides the first column?

AFAIK sadly not (same for Icons). A work around I use in SMF is to resort the columns with _GUICtrlListView_SetColumnOrder().

Share this post


Link to post
Share on other sites
Zedna

AFAIK sadly not (same for Icons). A work around I use in SMF is to resort the columns with _GUICtrlListView_SetColumnOrder().

There are scripts on the forum for the icons in other columns

but for checkboxes really no.

Share this post


Link to post
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
Sign in to follow this  

×