Cross_tab & Report Help

T

Ted

I have a report that is the result of a cross_tab. The
cross_tab contains all of the A/P detail (open invoices)
for a group of vendors.

In the cross_tab, I total all of the detail in a field
called balance and that gives me a cumulative dollar
total for each vendor and then print this total field on
the report.

I want to exclude any vendor that has a cumulative total
of 0 from the ensuing report. It will not allow me to
specify <>0 in the criteria of the cross_tab.

Can I write an expression on the report that excludes 0
balance records from printing?
 
D

Duane Hookom

If the balance is a field in the report, you can write code that would
cancel the formatting event of the section containing the 0 balance.
 
G

Guest

0Thanks for responding, but I'm not sure that I
understand your answer. The report that isplays the
results of the cross_tab has 1 line per vendor in the
detail section of the report.

Example:
Vendor Balance
ABC 100.00
DEF 75.00
GHI 0
JKL 125.99

In this example, I wan only want to print detail lines
for vendors ABD, DEF and JKL. Vendor GHI would not print
because the cumulative total of all open invoices
equals .00

Ted
 
D

Duane Hookom

Your code would look like this assuming your Balance field was bound to a
text box named txtBalance.
Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
Cancel = Me.txtBalance = 0
End Sub
 
Top