Results 1 to 4 of 4
  1. #1
    joelmeaders is offline Advanced Beginner
    Windows XP Access 2007
    Join Date
    Jan 2012
    Posts
    33

    Get column head name from list box?

    Is there any way to return the column head (String) from a listbox?



    I am building a section in a program for higher security users to add new fields to certain combo boxes. The list box is set as table/query and dynamically loads different tables based on user input.

    I have everything else worked out except retrieving the column headings so I can dynamically save new values into tables. The tables do not have the same field names.

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    Using the Column property and referring to row 0 should return the heading:

    ?Forms!frmCharges.lstPayments.Column(3,0)
    OrderDate

    OrderDate is the heading in the 4th column.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    joelmeaders is offline Advanced Beginner
    Windows XP Access 2007
    Join Date
    Jan 2012
    Posts
    33
    Quote Originally Posted by pbaldy View Post
    Using the Column property and referring to row 0 should return the heading:

    ?Forms!frmCharges.lstPayments.Column(3,0)
    OrderDate

    OrderDate is the heading in the 4th column.
    It was right in front of my face the whole time. Thanks a lot!!

  4. #4
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    No problemo!
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

Please reply to this thread with any new information or opinions.

Similar Threads

  1. List in Report Won't Show a Column in the Source Table
    By italianfinancier in forum Access
    Replies: 1
    Last Post: 05-28-2011, 02:23 AM
  2. In over my head
    By TylerB in forum Access
    Replies: 2
    Last Post: 05-04-2011, 04:07 PM
  3. Replies: 5
    Last Post: 10-18-2010, 04:56 AM
  4. Populating list box with column heading?
    By kawi6rr in forum Programming
    Replies: 1
    Last Post: 08-13-2010, 12:51 PM
  5. List box column check..
    By empyrean in forum Programming
    Replies: 1
    Last Post: 10-28-2009, 08:18 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums