Results 1 to 2 of 2
  1. #1
    IncidentalProgrammer is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Aug 2014
    Location
    Texas
    Posts
    156

    Transferring (other than bound) value of a multi-column combobox on subform to combobox on main form

    I'm about to pull my hair out, over this one.

    For my database, I have a table with a list of state names and abbreviations to be used in comboboxes, and also region numbers (1-13) associated with the states. The setup behind my problem goes like this:

    Table with state abbreviations in first column, state names in second, and region numbers for each in third.
    I have a form where users will enter data on new Clients. The address and contact info is entered in a subform, in which the combobox for choosing the state has bound column set to 0 (because it needs to store the state with the address in the table), column count 3, and the other two columns' widths set to 0. I'm trying to get the region number from the third column of the selected state to populate a region field in the main form.
    The region field is also a combobox, but getting its value from a list of just region numbers (1-13) instead of from the table (to avoid repeats and include 13 for "national", which wouldn't be in the state table).

    I can't get it to do anything. I've tried several different methods, but most the things I've read seem to indicate that I need to use .column(#), so that's what I've got right now. Can anyone see what I'm doing wrong?

    Code:
        Dim insdRgn As String
        
        insdRgn = Me.ctlCtcSt.Column(2)
        
        Forms!frmClientAdd.Controls!ctlCltPrimRgn.Value = insdRgn


  2. #2
    IncidentalProgrammer is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Aug 2014
    Location
    Texas
    Posts
    156
    Waits until I've spent a day banging my head against it, I post about it, and THEN it works.

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

Similar Threads

  1. Combobox blank when bound column hidden
    By dippim in forum Forms
    Replies: 2
    Last Post: 11-25-2014, 11:18 AM
  2. Combobox and bound column settings
    By RabbidB in forum Access
    Replies: 14
    Last Post: 11-21-2013, 02:39 PM
  3. Replies: 1
    Last Post: 09-06-2011, 01:47 PM
  4. Replies: 29
    Last Post: 08-16-2011, 05:52 PM
  5. Replies: 0
    Last Post: 08-24-2010, 06:38 PM

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