Solved

Column Heads in Forms 2.0 ListBox control

Posted on 1998-02-18
3
882 Views
Last Modified: 2008-02-01
I'm doing some programming for Outlook using VBScript, and I need to use a control that can display data in a list with multiple columns.  I have been using the ListBox control (MS Forms 2.0).

To display column heads, I set the ColumnHeads property to true:

ListBox.ColumnHeads = True

This creates space for the column heads at the top of the list box.  However, I have been unable to figure out how to actually put a heading in the ColumnHead area.  Anyone have any suggestions?

I did look in Excel's Object Browser, and the Help file for ColumnHeads just says the following:

"When the system uses the first row of data items as column headings, they can't be selected." (Copyright(c) 1996 Microsoft Corporation.)

I'm not even sure what this means.  How can I "get" the system to use the first row of data items as column heads?  Everything I've tried has failed.

If you can't answer this question, I'd appreciate some comments with suggestions of good alternatives.  My requirement is 12 columns, and the ability to put headings on the columns.
0
Comment
Question by:dmacioce
  • 2
3 Comments
 
LVL 6

Accepted Solution

by:
anthonyc earned 50 total points
ID: 1457469
do you have VB 5 on the machine?  If so, consider using DBGRID.  However, since I suspect you don't, consider this:

The list in a ComboBox consists of rows of data. Each row can have one or more columns, which can appear with or without headings. Some applications do not support column headings, others provide only limited support.

The same is true for the listbox.  

If you get any kind of activex grid, you should be able to use it.
0
 

Author Comment

by:dmacioce
ID: 1457470
Thanks.

Actually, MS FlexGrid control works fine (tried it out after I read your suggested), so I might use that.  
0
 
LVL 6

Expert Comment

by:anthonyc
ID: 1457471
MS Flexgrid is probably better actually!  thanks for the points
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question