dropdown with yes/no options and 1/0 values

  • Thread starter Thread starter hwdoyle
  • Start date Start date
H

hwdoyle

Guest
hi everybody,
i am making an access database based on a mysql/web project. in the database, there are a lot of fields which answer yes/no questions and are stored as 0/1 in the database. i would like my dropdown to to have a yes/no option, and then insert 0 or 1 into the database accordingly. i would also like the existing value to be pre-selected in the dropdown. i am used to doing this in web forms, and not sure how to implement using access forms.

what is the best way to do this with access?

thanks,
harry
 
One way to do this is to create a table where you have two fields
populated with values as follows:

-------- F1 F2
Record1 Yes -1
Record2 No 0

Use this table as the record source of your combobox.
Field1(F1) should be the visible field. Bind Field2(F2) --
this will be the value that will be stored in your database.

There are other ways to achieve the same result, but
this should work just as well.
 
Last edited:
You can create your own combo box and define the fields and the values of the fields and also choose which field to be visible to the user. Make the Yes/No field visbible but bind the -1/0 field to the table field.
 

Users who are viewing this thread

Back
Top Bottom