Qry not updating from form Adult video chat numbers for iphone

If you find that DCount works at an acceptable speed you can combine it with some VBA code to ensure that it always shows an up-to-date value.Clear the entry from the Control Source property of the unbound text box and instead have VBA write a value into the box for you.

This should be the name of a field which will contain a value for every record.If you are counting records you must choose a field which can be guaranteed to contain data (ideally the primary key field).Alternatively you can use the asterisk (*) to represent all fields.In this example the Control Source of the textbox uses the values in two combo boxes (named cbo Office and cbo Department) included in the expression: =DCount("[Staff ID]","tbl Staff","[Office]='" & [cbo Office] & "' AND [Department]='" & [cbo Department] & "'") Using DCount this way is easy but it has its disadvantages.If the number of records in the recordset changes, perhaps because the user adds or deletes records, the value shown in the textbox is not automatically recalculated.

Leave a Reply