Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thank you to those who replied to my question about
changing list box text. The comments were very helpful. Today I need to put text into the listbox column headings. The listbox property has been set to show three columns. Using help, I have been unable to find a code statement that will do this. Any suggestions? Keith |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Keith
You can't do that by code. Listbox column headers appear only when you populate the box with a spreadsheet range that has columnheaders. HTH. Best wishes Harald "Keith" skrev i melding ... Thank you to those who replied to my question about changing list box text. The comments were very helpful. Today I need to put text into the listbox column headings. The listbox property has been set to show three columns. Using help, I have been unable to find a code statement that will do this. Any suggestions? Keith |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I don't recall the "listbox problem 1" question (maybe the OP was looping
through the range to selectively add stuff to the listbox????). But I can use code and have headers: Option Explicit Private Sub UserForm_Activate() With Me.ListBox1 .ColumnCount = 3 .RowSource _ = Worksheets("Sheet1").Range("a2:c10").Address(exter nal:=True) .ColumnHeads = True End With End Sub (I figure there was a lot of stuff from the original thread that I missed). ===== To the OP: Maybe you could add some labels right above the listbox and use them for headers. Harald Staff wrote: Hi Keith You can't do that by code. Listbox column headers appear only when you populate the box with a spreadsheet range that has columnheaders. HTH. Best wishes Harald "Keith" skrev i melding ... Thank you to those who replied to my question about changing list box text. The comments were very helpful. Today I need to put text into the listbox column headings. The listbox property has been set to show three columns. Using help, I have been unable to find a code statement that will do this. Any suggestions? Keith -- Dave Peterson |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
"Dave Peterson" skrev i melding
... But I can use code and have headers: Bad choice of words from me, sorry. Yes, one can set the Rowsource / Listfillrange by code also. But one can not have columnheaders if the list is populated using VBA code .Additem or .List Best wishes Harald |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Excellent choice of words this time <bg.
Harald Staff wrote: "Dave Peterson" skrev i melding ... But I can use code and have headers: Bad choice of words from me, sorry. Yes, one can set the Rowsource / Listfillrange by code also. But one can not have columnheaders if the list is populated using VBA code .Additem or .List Best wishes Harald -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Listbox Problem | Excel Discussion (Misc queries) | |||
Listbox problem | Excel Discussion (Misc queries) | |||
listbox problem | Excel Programming | |||
Listbox Problem | Excel Programming | |||
listbox problem | Excel Programming |