[AccessD] Conditional Display of TextBox in Report Detail

Joe O'Connell joconnell at indy.rr.com
Thu Mar 13 10:22:00 CST 2003


Larry,

If your textbox has a transparent background and transparent border, try
changing the source for the textbox to display nothing.  The source would be
something like this: = Iif(datafield=0,"",datafield)

Joe O'Connell
joconnell at indy.rr.com


-----Original Message-----
From: Lawrence Mrazek <lmrazek at lcm-res.com>
To: accessd at databaseadvisors.com <accessd at databaseadvisors.com>
Date: Thursday, March 13, 2003 11:06 AM
Subject: [AccessD] Conditional Display of TextBox in Report Detail


|Greetings:
|
|Using Access XP. I calculated field in the detail section of a report
|that compares an invoice amount with a check amount. I'd like the
|textbox to display if the value of the textbox does not equal zero. I've
|tried to use the following code in the "OnFormat" property of the detail
|section:
|
|Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
|On Error GoTo ERR_OnFormat
|
|    If Me.Difference = 0 Then
|        Me.Difference.Visible = False
|    End If
|
|Exit_ERR_OnFormat:
|    Exit Sub
|
|ERR_OnFormat:
|    MsgBox Err.Description
|    Resume Exit_ERR_OnFormat
|
|End Sub
|
|This code correctly detects the first textbox where the value <>0, but
|doesn't find any others (I've checked, and I should have a couple of
|other textboxes displaying).
|
|Thanks in advance for your help.
|
|Larry Mrazek
|LCM Research, Inc.
|lmrazek at lcm-res.com
|http://www.lcm-res.com
|
|-
|
|_______________________________________________
|AccessD mailing list
|AccessD at databaseadvisors.com
|http://databaseadvisors.com/mailman/listinfo/accessd
|Website: http://www.databaseadvisors.com





More information about the AccessD mailing list