Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2003
    Posts
    1

    Unanswered: Selected fields!! Urgent

    Hi guys,

    I would like to do in my db a simple thing (I am rookie in Acess).
    I have two fields in my table with the names of the plants, like scientific name and local name and I would like when a user in a form that I have designed puts a new data, pick the scientific name of one plant, automaticaly apears in the text box , the local name.
    Another question is, I have two fields one with countries and the other with cities, and I would like when I choose a countrie appears only the cities of that country, as we see in many Databases!!
    Please I need this with quite urgency.
    Best regards.
    Paulo Maio

  2. #2
    Join Date
    Sep 2003
    Posts
    19

    Re: Selected fields!! Urgent

    For your 1st question : Make the box where the user enters the scientific name a combo box w/ recordsource = the table w/ your sci and standard names. Set column count = 2. You can make the 2nd column (standard name) width = 0 if you don't want the user to see that in the dropdown. Then set the controlsource of the standard name box to scinamebox.column2. When the info in the scinamebox changes, the standard name box will auto-update.

    For you 2nd question. On the after update event of the country box, do this :
    assuming tblcities has 2 columns - 1 with city name & 1 with country name & that your form has a country text box and a city text box

    me!city.recordsource = "select city from tblcities where country = """ & me!country & """"
    me!city.requery

    Originally posted by pmaio
    Hi guys,

    I would like to do in my db a simple thing (I am rookie in Acess).
    I have two fields in my table with the names of the plants, like scientific name and local name and I would like when a user in a form that I have designed puts a new data, pick the scientific name of one plant, automaticaly apears in the text box , the local name.
    Another question is, I have two fields one with countries and the other with cities, and I would like when I choose a countrie appears only the cities of that country, as we see in many Databases!!
    Please I need this with quite urgency.
    Best regards.
    Paulo Maio

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •