sql statement as record source for textbox

  • Thread starter Thread starter pierre
  • Start date Start date
P

pierre

Hi all,

I want to dynamically display on a form the number of record meeting a
condition in a database.

this sql is not working

SELECT Count(tblSection.k_etat) AS CompteDek_etat
FROM tblSection
How can i do that?

regards,
pierre
 
pierre said:
Hi all,

I want to dynamically display on a form the number of record meeting a
condition in a database.

this sql is not working

SELECT Count(tblSection.k_etat) AS CompteDek_etat
FROM tblSection
How can i do that?

regards,
pierre

You can't use a SQL string as the ControlSource for a TextBox. Try the
DCount() function instead.
 
Back
Top