drop-down on form having recordsource question??

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a login drop-down (user names).. but after selecting a user, from the
list.. that value is written to the user name field of the first record (of
the table).. overwriting the value that was originally there (the first user
listed).. how can i stop this? I do not want them to be able to edit any
records (from this screen). I have another similiar problem on another
form.. a drop-down again.. but here the user is allowed to change the value
of the drop-down (to whatever they select).. thanks in advance!
 
Lpjennifer,

You apparently have the form bound to the Users table, and the combobox
is bound to the User Name field. Most likely, you do not really want
either of these. Probably the form should not be bound (i.e. the Record
Source property of the form should be blank), and the combobox should be
unbound (the Control Source property of the combobox should be blank).
Unless you want to record a history of login dates and times etc, you
don't need to store the login information in a table, and only want it
held temporarily in an unbound control on the form until such time as
the login credentials have been verified.
 
I have a login drop-down (user names).. but after selecting a user, from the
list.. that value is written to the user name field of the first record (of
the table).. overwriting the value that was originally there (the first user
listed).. how can i stop this? I do not want them to be able to edit any
records (from this screen). I have another similiar problem on another
form.. a drop-down again.. but here the user is allowed to change the value
of the drop-down (to whatever they select).. thanks in advance!

Change the Control Source property of this combo box from the name of
the user field to blank.

A combo box has two usually distinct uses: to edit and display data in
a table (for which a "bound" combo is appropriate), or to find records
on a form (for which you should use an "unbound" combo).

John W. Vinson[MVP]
Join the online Access Chats
Tuesday 11am EDT - Thursday 3:30pm EDT
http://community.compuserve.com/msdevapps
 
Thanks so much!.. got it :)

Steve Schapel said:
Lpjennifer,

You apparently have the form bound to the Users table, and the combobox
is bound to the User Name field. Most likely, you do not really want
either of these. Probably the form should not be bound (i.e. the Record
Source property of the form should be blank), and the combobox should be
unbound (the Control Source property of the combobox should be blank).
Unless you want to record a history of login dates and times etc, you
don't need to store the login information in a table, and only want it
held temporarily in an unbound control on the form until such time as
the login credentials have been verified.
 
Thanks so much!.. got it :)

John Vinson said:
Change the Control Source property of this combo box from the name of
the user field to blank.

A combo box has two usually distinct uses: to edit and display data in
a table (for which a "bound" combo is appropriate), or to find records
on a form (for which you should use an "unbound" combo).

John W. Vinson[MVP]
Join the online Access Chats
Tuesday 11am EDT - Thursday 3:30pm EDT
http://community.compuserve.com/msdevapps
 
Back
Top