Combobox update problem

collizz

Registered User.
Local time
Today, 20:52
Joined
Feb 6, 2006
Messages
29
Hi

I have a table: tblDocument, that includes a field statusCode, which is validated through a decode table: tblCodeDecode.

tblCodeDecode has a 2-part primary key: categoryCode + subCode, as well as non-key fields: activeInd and description, as follows:

STA | INC | True | In Progress
STA | AC1 | True | For Review
STA | AC2 | True | For Approval
STA | ACT | True | Active

My form: frmDocumentView is opened acFormEdit, and shows document record details, including a combobox which is based on a query: qryStatus

SELECT subCode, description
FROM tblCodeDecode
WHERE categoryCode = "STA"
AND activeInd = True

When I load my form, it shows all tblDocument data as expected, as well as showing the record's status description value in the combobox.

Property Sheet values for the combobox are:

Name = cboStatus
Control Source = statusCode
ColumnCount = 2
Column Widths = 0; 2.542
Row Source = qryStatus
Row Source Type = Table/Query
Bound Column = 1
Enabled = Yes
Locked = No

What I can't do is select a new status value from the combo list, to replace the original loaded value.

I can see the list of status descriptions, and select the new value, but the combobox won't update

What rookie mistakes am I making here, please?
 
It maybe that the Control Source of your Combo Box is from the wrong Table.

It should be getting its Data from tblCodeDecode.

I think.
 
Additionally, make sure that the query underlying the form is updateable. Check here for why it could be non-updateable. Also, the form's AllowEdits needs to be set to YES.
 

Users who are viewing this thread

Back
Top Bottom