By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,504 Members | 2,596 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,504 IT Pros & Developers. It's quick & easy.

How to a Combo Box to a default value

P: 22
Hi. A have a combo box which has a list, "Yes" & "No" on a form,i am trying to set the value to "No" in that combo box when the forms load. Any ideas.!!Thx.
Jul 19 '07 #1
Share this Question
Share on Google+
2 Replies


Expert 100+
P: 344
Hi. A have a combo box which has a list, "Yes" & "No" on a form,i am trying to set the value to "No" in that combo box when the forms load. Any ideas.!!Thx.

If you just want to set it when the form loads, then in the on_open event of the form type cboMyBox='No'

If you want it for every record, put it in the on_current event of the form
Jul 19 '07 #2

P: 24
If the combo box's recordsource is only 'yes' and 'no' then you should think about using a check box. This way the user only has one option either checking it or not. It can make you program run a little more efficient. Also you can default the value for the check box by making the default value in properties =NO. However, if the combo box is dynamic (meaning that you have multiple options to fill the combo box's values then you can make it default to "No" by just using the default value option in the properties menu for the combo box and writing in ="No"
Jul 19 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.