I've got 2 tables
tblHdr
hdrId
hdrComments
tblDtl
hdrId
dtlId
dtlDate
dtlComments
the report is sorted by dtlDate, and it prints the hdrComments and the
dtlComments if there is data
I only want to print the hdrComments once if there are 2 sequential
rows with the same hdrId
different hdrId -
hdrId 1, dtlID 1, hdrComments, dtlComments
hdrId 2, dtlId 2, hdrComments, dtlComments
same hdrId -
hdrId 1, dtlID 1, hdrComments, dtlComments
hdrId 1, dtlID 2, dtlComments
hdrId 2, dtlId 2, hdrComments, dtlComments
sometimes it doesn't print the hdrId 1 hdrComments -
hdrId 3, dtlID 1, hdrComments, dtlComments
hdrId 1, dtlID 1, hdrComments, dtlComments
hdrId 2, dtlId 2, hdrComments, dtlComments
this is the code that I'm using
Dim lngHdrId As Long
Private Sub Detail_Print(Cancel As Integer, PrintCount As Integer)
On Error Resume Next
hdrComments.Visible = Not (IsNull(hdrComments))
If (hdrComments.Visible) Then
If (hdrId = lngHdrId) Then
hdrComments.Visible = False
End If
End If
lngHdrId = HdrId
End Sub
Private Sub Report_Open(Cancel As Integer)
lngHdrId = -1
End Sub
and it usually works, both occasionally, it sets visible = true (based
on debug.print), with comments data, but the comments don't print
I've tried using this with the onFormat event, same problem
is there any way to do this ? 1 1175 le*********@natpro.com wrote: I've got 2 tables tblHdr hdrId hdrComments
tblDtl hdrId dtlId dtlDate dtlComments
the report is sorted by dtlDate, and it prints the hdrComments and the dtlComments if there is data
I only want to print the hdrComments once if there are 2 sequential rows with the same hdrId
different hdrId - hdrId 1, dtlID 1, hdrComments, dtlComments hdrId 2, dtlId 2, hdrComments, dtlComments
same hdrId - hdrId 1, dtlID 1, hdrComments, dtlComments hdrId 1, dtlID 2, dtlComments hdrId 2, dtlId 2, hdrComments, dtlComments
sometimes it doesn't print the hdrId 1 hdrComments - hdrId 3, dtlID 1, hdrComments, dtlComments hdrId 1, dtlID 1, hdrComments, dtlComments hdrId 2, dtlId 2, hdrComments, dtlComments
this is the code that I'm using
Dim lngHdrId As Long Private Sub Detail_Print(Cancel As Integer, PrintCount As Integer) On Error Resume Next hdrComments.Visible = Not (IsNull(hdrComments)) If (hdrComments.Visible) Then If (hdrId = lngHdrId) Then hdrComments.Visible = False End If End If
lngHdrId = HdrId End Sub
Private Sub Report_Open(Cancel As Integer) lngHdrId = -1 End Sub
and it usually works, both occasionally, it sets visible = true (based on debug.print), with comments data, but the comments don't print
I've tried using this with the onFormat event, same problem
is there any way to do this ?
Set the Hide Duplicates property of the hdrComments control to Yes.
--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA) This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: praba kar |
last post by:
Dear all,
In Php array_slice function base
we can print array contents as per our desire
eg)
$a = array(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15);
$arr = array_slice($a,10,10);
this function...
|
by: J M |
last post by:
I have Windows2000 Application Event Log file in CSV format with all
kinds of entries However I need to process following types of records
for print logs and generate report:
9/19/2003,8:15:57...
|
by: shaqattack1992-newsgroups |
last post by:
I have a table with a hyperlink field pointing to an Excel file that I
would like to automatically print out on a report form.
For example, I have a table:
Part--------Drawing(hyperlink field)...
|
by: djsdaddy |
last post by:
Good Day to All, I am organizing some Affirmative Action data and I need to be able to sum a number of field totals and then print them in a report. I have 5 tables that store the data that I need...
|
by: devikacs |
last post by:
i am new to C# .net. i am trying to print the contents of a sql table on a form using datagridview.
i've first printed the values of a select command on the datagridview. on clicking a button, the...
|
by: Gilberto |
last post by:
pks00
Expert
280 Posts April 16th, 2007
01:08 PM
Re: How to print MS Access 2000 report to PDF995 printer by VBA Code
Sweet, your using pdf995, makes answering this question that much...
|
by: michael8027 |
last post by:
Please Direct Me To How Can I Print A The Contents Of Datagrid Which I Have Selected From A Combobox I Wanna To Print Only Contents Not Form Plesase Send Ways How To With Code Itself
|
by: ajaykhedekar |
last post by:
I am Showing Mulitple MSRS Reports on Single ASP.Net WEB Page using Mulitple ReportViewer Controls. If User wants to Print the Reports, then user has to click Print button provided by ReportViewer...
|
by: alivip |
last post by:
when I wont to inser (anyting I print) to the textbox it will not inser
it just print then hanging
# a look at the Tkinter Text widget
# use ctrl+c to copy, ctrl+x to cut selected text,
#...
|
by: sajjad2008 |
last post by:
Hi Everyone!
how to print specific contents of vb form in vb6. can someone give the code example please... actually, i want to draw a graph on vb6 form and then print it. please help....
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
| |