Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4231176
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T01:56:29+00:00 2026-05-21T01:56:29+00:00

I have a wx.ListCtrl that has the wx.LC_REPORT bit set. It has 3 columns.

  • 0

I have a wx.ListCtrl that has the wx.LC_REPORT bit set. It has 3 columns. I want the first column to be populated with a check box for each other entry. I tried using the ListCtrl.InsertItem method, but it only takes one argument (info) and I can’t find any docs as to what that argument needs to be. I’ve tried just passing a wx.CheckBox to InsertItem to no avail.

Is it possible to have a checkbox as an entry in a wxPython ListCtrl? If so, how would I go about doing that?

In case there’s any ambiguity as to what I’m talking about, here’s a picture of what I want (not sure if this is wx, but it’s what I’m looking for). I want the checkboxes next to 1..5 in the No. column.

list control with checkboxes

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-21T01:56:29+00:00Added an answer on May 21, 2026 at 1:56 am

    Have a look at wx.lib.mixins.listctrl.

    import wx
    import wx.lib.mixins.listctrl as listmix
    
    class TestListCtrl(wx.ListCtrl, listmix.CheckListCtrlMixin, listmix.ListCtrlAutoWidthMixin):
        def __init__(self, *args, **kwargs):
            wx.ListCtrl.__init__(self, *args, **kwargs)
            listmix.CheckListCtrlMixin.__init__(self)
            listmix.ListCtrlAutoWidthMixin.__init__(self)
            self.setResizeColumn(3)
    
        def OnCheckItem(self, index, flag):
            print(index, flag)
    
    class MainWindow(wx.Frame):
        def __init__(self, *args, **kwargs):
            wx.Frame.__init__(self, *args, **kwargs)
            self.panel = wx.Panel(self)
            self.list = TestListCtrl(self.panel, style=wx.LC_REPORT)
            self.list.InsertColumn(0, "No.")
            self.list.InsertColumn(1, "Progress")
            self.list.InsertColumn(2, "Description")
            self.list.Arrange()
            for i in range(1, 6):
                self.list.Append([str(i), "", "It's the %d item" % (i)])        
            self.button = wx.Button(self.panel, label="Test")
            self.sizer = wx.BoxSizer(wx.VERTICAL)
            self.sizer.Add(self.list, proportion=1, flag=wx.EXPAND | wx.ALL, border=5)
            self.sizer.Add(self.button, flag=wx.EXPAND | wx.ALL, border=5)
            self.panel.SetSizerAndFit(self.sizer)
            self.Show()
    
    app = wx.App(False)
    win = MainWindow(None)
    app.MainLoop()
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a ListCtrl that displays a list of items for the user to
I'm working in wx.Python and I want to get the columns of my wx.ListCtrl
I have a multiple selection wxListBox and I want to keep the condition that
I have a listctrl with CheckBox in it(LVS_EX_CHECKBOXES) .It is a single column List
I have a wxPython ListCtrl with five columns. Four of these hold strings, the
Have had to write my first proper multithreaded coded recently, and realised just how
I have two wxListCtrl and want to process the Ctrl + Enter keyboard event
Have a bunch of WCF REST services hosted on Azure that access a SQL
Have finally got a responsive site working (of a fashion). What I want to
Have a look at one of my websites: moskah.com The problem is that it

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.