Results 1 to 5 of 5
  1. #1
    mikichi is offline Advanced Beginner
    Windows 7 32bit Access 2007
    Join Date
    Oct 2013
    Posts
    45

    question | how to change a value with choice in a combo box

    hi,
    i have a two column that one stores a professions and other stores a number of the profession like that:
    number professions
    1 singer
    2 police man
    3 teacher



    "number" column is a combo box, that boundColumn property is two.
    i want that in the form when i choose a value in a combo box i will see the profession in other text box in my form.
    if i choose 2 in combo box i see in a other text box in my form police man.
    thank you,
    miki
    p.s:sorry on my horrible english

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,771
    I assume the combobox is multi-column.

    Expression in textbox can refer to column index of combobox. If the profession is in column 2 the index is 1 because index starts with 0: =[comboboxname].Column(1)
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    mikichi is offline Advanced Beginner
    Windows 7 32bit Access 2007
    Join Date
    Oct 2013
    Posts
    45
    thank you!!
    i write in "source control" =[comboboxname].Column(1).
    but now i have other problem. its doesn't update my data base. because i change the source control!
    thenk you,
    miki

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,771
    And it shouldn't. Should not save the profession name if you are saving the ID number. Save one or the other, not both.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  5. #5
    mikichi is offline Advanced Beginner
    Windows 7 32bit Access 2007
    Join Date
    Oct 2013
    Posts
    45
    Quote Originally Posted by June7 View Post
    And it shouldn't. Should not save the profession name if you are saving the ID number. Save one or the other, not both.
    lol! i dont think on this ><
    thank you very much. its exellent forum

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

Similar Threads

  1. Replies: 3
    Last Post: 12-11-2012, 09:12 AM
  2. Replies: 4
    Last Post: 08-25-2012, 07:19 PM
  3. Visible text boxes when combo box choice selected
    By nichmeg in forum Programming
    Replies: 3
    Last Post: 10-16-2011, 02:53 PM
  4. List box update from combo box choice
    By allykid in forum Forms
    Replies: 1
    Last Post: 03-08-2011, 10:06 PM
  5. populate boxes based on combo box choice
    By Mattm1958 in forum Forms
    Replies: 13
    Last Post: 08-30-2010, 02:09 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