calculating count in textbox

G

Guest

Hi, I am using the following query (called "site_data_query") as data in a
report. I have included in the report a label "total records" next to which I
would like a number indicating the records from the query, in this case "8".
I tried this by inserting a textbox next to the label, then for its control
source in its properties box I typed this:
=Sum(Count([site_data_query]![musym]))
The result of which is "#error". Any help on how I can do this??

musym Site UserSite Comp ID
38E 451 052033 a
38E 604 061023 b
38E 610 061040 a
38E 611 061042 a
38E 612 061043 a
38E 615 061048 a
38E 617 061050 b
38E 618 061051 a
 
G

Guest

That didn't work. Again, the report is based on the "site_data_query", an
example of which is in my first message. I try to insert a textbox, which is
initially unbound, into the report, then go to the properties of that textbox
and for the control source type "=Count(*)"
And I get the "#error" message. ??

Duane Hookom said:
You are working much too hard. Try
=Count(*)

--
Duane Hookom
MS Access MVP
--

Giz said:
Hi, I am using the following query (called "site_data_query") as data in a
report. I have included in the report a label "total records" next to
which I
would like a number indicating the records from the query, in this case
"8".
I tried this by inserting a textbox next to the label, then for its
control
source in its properties box I typed this:
=Sum(Count([site_data_query]![musym]))
The result of which is "#error". Any help on how I can do this??

musym Site UserSite Comp ID
38E 451 052033 a
38E 604 061023 b
38E 610 061040 a
38E 611 061042 a
38E 612 061043 a
38E 615 061048 a
38E 617 061050 b
38E 618 061051 a
 
M

Marshall Barton

You probably put the text box in a Page Header/Footer
section. It must be in the REPORT Header/Footer section.
--
Marsh
MVP [MS Access]


That didn't work. Again, the report is based on the "site_data_query", an
example of which is in my first message. I try to insert a textbox, which is
initially unbound, into the report, then go to the properties of that textbox
and for the control source type "=Count(*)"
And I get the "#error" message. ??

Duane Hookom said:
You are working much too hard. Try
=Count(*)
--

Giz said:
Hi, I am using the following query (called "site_data_query") as data in a
report. I have included in the report a label "total records" next to
which I
would like a number indicating the records from the query, in this case
"8".
I tried this by inserting a textbox next to the label, then for its
control
source in its properties box I typed this:
=Sum(Count([site_data_query]![musym]))
The result of which is "#error". Any help on how I can do this??

musym Site UserSite Comp ID
38E 451 052033 a
38E 604 061023 b
38E 610 061040 a
38E 611 061042 a
38E 612 061043 a
38E 615 061048 a
38E 617 061050 b
38E 618 061051 a
 
G

Guest

Thank you, that worked ;)

Marshall Barton said:
You probably put the text box in a Page Header/Footer
section. It must be in the REPORT Header/Footer section.
--
Marsh
MVP [MS Access]


That didn't work. Again, the report is based on the "site_data_query", an
example of which is in my first message. I try to insert a textbox, which is
initially unbound, into the report, then go to the properties of that textbox
and for the control source type "=Count(*)"
And I get the "#error" message. ??

Duane Hookom said:
You are working much too hard. Try
=Count(*)
--

Hi, I am using the following query (called "site_data_query") as data in a
report. I have included in the report a label "total records" next to
which I
would like a number indicating the records from the query, in this case
"8".
I tried this by inserting a textbox next to the label, then for its
control
source in its properties box I typed this:
=Sum(Count([site_data_query]![musym]))
The result of which is "#error". Any help on how I can do this??

musym Site UserSite Comp ID
38E 451 052033 a
38E 604 061023 b
38E 610 061040 a
38E 611 061042 a
38E 612 061043 a
38E 615 061048 a
38E 617 061050 b
38E 618 061051 a
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top