Avatar of Mike Eghtebas
Mike Eghtebas
Flag for United States of America

asked on 

vb.net, listbox header

On a vb.net winform below, A is what I have.
Question: Is it possible to make changes to the header area, as shown on B above?
headerLike:
1. Add a continuous line under header captions.
2. Make header text bold, change its size, etc.

The code populating this listbox is:
      lstCustomers.Items.Add("Cust ID" & ControlChars.Tab & "F. Name" & ControlChars.Tab & _
                               "L. Name" & ControlChars.Tab & "City" & ControlChars.Tab & "State")

        lstCustomers.Items.Add("-------" & ControlChars.Tab & "-------" & ControlChars.Tab & _
                               "-------" & ControlChars.Tab & "-------" & ControlChars.Tab & "-------")

        ' ADD CUSTOMERS TO lstCustomers
        For Each customer In customers
            lstCustomers.Items.Add(customer.CustomerID & ControlChars.Tab & _
                                                      customer.FirstName & ControlChars.Tab & _
                                                      customer.LastName & ControlChars.Tab & _
                                                      customer.State & ControlChars.Tab & _
                                                      customer.City)
        Next

Open in new window

Visual Basic.NETC#.NET Programming

Avatar of undefined
Last Comment
LordWabbit

8/22/2022 - Mon