"PerryC" <pe******@yahoo.com> wrote in message
news:ea**************************@posting.google.c om...
I have a memo field, say Field1, in a form. Then I want to create a
report showing all the sum (or the adding up of all the texts ever
entered into this field.
i.e.
Record1: Field1 contain "ABC"
Record2: Field1 contain "DEF"
Record3: Field1 contain "GHI"
Record4: Field1 contain "JKL"
Record5: Field1 contain "MNO"
In the report, I want it to show: "ABCDEFGHIJKLMNO"
I know if the field were numbers, I can simply say Sum([field1]), but
now it is memo or text, what is the code for replacing sum?
There is no "append all the information from this field in every record"
built-in function. You will have to accumulate the total yourself, in
code... for that code to be run for each record, it will have to be in the
Format or Print event of the Detail Section. Unfortunately, those events can
fire more than once per record, so you'll have to code to make sure you
don't append the same information more than once. The operator to append one
string to another is "&"... a VBA statement might look something like this:
If .... <whatever you need to assure you
haven't processed this record already) Then
strAllText = strAllText & Me!txtThisText
End If
Larry Linson
Microsoft Access MVP