Results 1 to 3 of 3
  1. #1
    Roger81 is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jul 2011
    Posts
    4

    Cascading field

    Hi,

    I 've got 2 fields: country and city. After selecting the country(row source from the countries table) I want to be able to select only the cities from that country, in other words, in the row source of the city I use a query like:
    SELECT TS_TiposTest.IDCity
    FROM TS_TiposTest
    WHERE TS_TiposTest.IDCountry= ???CurrentRecord??? How do I select the current record IDCountry value?

    I need to do this at data (table) level, doing it at form level doesn't solve the problem.



    Thanks!

  2. #2
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    assuming the IDCountry is your first combobox

    SELECT TS_TiposTest.IDCity
    FROM TS_TiposTest
    WHERE TS_TiposTest.IDCountry= me.IDCountry

    then in the ON EXIT property of your country combobox you have to requrey the contents of the IDCITY combo box

    IDCity.requery

  3. #3
    Roger81 is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jul 2011
    Posts
    4
    Thanks! Problem solved

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

Similar Threads

  1. Cascading Combo Box Help
    By euphoricdrop in forum Forms
    Replies: 3
    Last Post: 04-12-2011, 05:35 PM
  2. cascading drop down
    By ManvinderKaur in forum Forms
    Replies: 1
    Last Post: 06-23-2010, 05:31 PM
  3. cascading combo
    By rexb in forum Forms
    Replies: 9
    Last Post: 10-26-2009, 04:10 PM
  4. Cascading ?
    By dlburkins in forum Forms
    Replies: 5
    Last Post: 09-27-2009, 04:41 AM
  5. Cascading Combo Box
    By nywi6100 in forum Forms
    Replies: 0
    Last Post: 10-23-2006, 01:45 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