XL98: TextColumn Property Displays Only the First Column

Last reviewed: February 28, 1998
Article ID: Q181814
The information in this article applies to:
  • Microsoft Excel 98 Macintosh Edition

SYMPTOMS

When you set the TextColumn property for a ComboBox or ListBox control on a UserForm in a Visual Basic for Applications macro, Microsoft Excel may display the first column in the range of data instead of the column that you specify.

WORKAROUND

To work around this problem, set the ColumnWidths property to 0 (zero) so the column you want to display is the first column in the range of data that has a column width greater than 0. For example, if you want to display the second column in the list, but return a value from the first column of the list, use the properties that are listed in the following table.

   Property        Value
   ---------------------

   BoundColumn         1
   ColumnCount         2
   ColumnsWidths       0
   TextColumn          2

STATUS

Microsoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

MORE INFORMATION

The TextColumn property identifies the column in a ComboBox or ListBox control that is displayed. Values for the TextColumn property range from 1 to the number of columns in the list. For example, the first column is 1, the second column is 2, and so on. Setting the TextColumn property to 0 displays the ListIndex values. Setting the TextColumn property to 1 displays the first column that has a ColumnWidth greater than 0.

REFERENCES

For more information about the TextColumn property, click the Office Assistant while in the Visual Basic Editor, type "How do I use the TextColumn property?" click Search, and then click to view "TextColumn property."

NOTE: If the Assistant is hidden, click the Office Assistant button on the Standard toolbar. If Microsoft Help is not installed on your computer, please see the following article in the Microsoft Knowledge Base:

   ARTICLE-ID: Q179216
   TITLE     : OFF98: How to Use the Microsoft Office Installer Program


Additional query words: XL98
Keywords : kbdta xlvbainfo
Version : MACINTOSH:98
Platform : MACINTOSH
Issue type : kbbug
Solution Type : kbpending


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: February 28, 1998
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.