Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Keeping default value for a list box

Status
Not open for further replies.

erictheman

Programmer
Jul 16, 2002
12
CA
I need some help. I have a list box field with two values in it. "Active" and "Deleted". I use code for the form on current property. [Jobstatus] = "Active" It works fine. Every record I go to it shows Active. But the problem is that if I choose Deleted on a record, when I come back to it, it changes to Active. How do I keep it default as Active but if I change it to Delete it will stay that way not turn back to Active? Thank you for your help!
 
Do you have a what is the control souce behind the list box. I.E. you need to be storing that data somewhere.

Let me know and we can move forward from there.

Jay
 
Is there a control souce behind the list box. I.E. you need to be storing that data somewhere.

Let me know and we can move forward from there.

Jay
 
Yes. I made it using the list box wizard and had two values. It's being store in a table as well.
 
First I would check the properties for the list box. Right click on the list box, click properties and check the control source for the list box. It should be a field from the table that the form is based on. If no control source is listed, that is the problem. Change the control source to the appropriate field in the table. If a control source is listed, go to the next step.

Open the table that contains the field that the list box represents. Manually change the value of one of the records from Active to Deleted. Note the value in the field will most likely be numeric and the default will be 1.

Once you have changed the value, open the form and go to the record that you changed in the table. Does the list box show Deleted?

Let me know the results of this and we can move forward.

Jay
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top