Wrox Home  
Search P2P Archive for: Go

  Return to Index  

ado_dotnet thread: Re: Printing from a database


Message #1 by Richard Ainsley <rainsley@p...> on Fri, 01 Feb 2002 12:11:45 -0800
What I did was to create module level variables which kept trak of the item

I was printing at the bottom of the last page out, then each time the

PrintPage event fires I use that information to properly set up the new

page. You need to use variables which are scoped outside the PrintPage event

handler for shure.



Hope this helps.





----- Original Message -----

From: <Kyle@T...>

To: "ADO.NET" <ado_dotnet@p...>

Sent: Monday, January 28, 2002 6:33 AM

Subject: [ado_dotnet] Printing from a database





> In a PrintPage event I am opening a data reader and reading the records

> in a while loop.  When I reach the MarginBounds I am setting

> e.HasMorePages to true followed by a return statement.  When the next

> page attempts to print and the PrintPage event executes again it runs all

> of the code within the PrintPage method creating an error condition and

> does not just continue at the same place in the while loop.  How is the

> process of printing a large number of records from a database usually

> handled?




$subst('Email.Unsub').



Message #2 by "Kyle" <Kyle@T...> on Fri, 1 Feb 2002 15:59:51 -0500
Thanks, I ended up using a dataview to loop through the data and

variables to keep track of the print position and it's working great.



Kyle



-----Original Message-----

From: Richard Ainsley [mailto:rainsley@p...]

Sent: Friday, February 01, 2002 3:12 PM

To: ADO.NET

Subject: [ado_dotnet] Re: Printing from a database



What I did was to create module level variables which kept trak of the

item

I was printing at the bottom of the last page out, then each time the

PrintPage event fires I use that information to properly set up the new

page. You need to use variables which are scoped outside the PrintPage

event

handler for shure.



Hope this helps.





----- Original Message -----

From: <Kyle@T...>

To: "ADO.NET" <ado_dotnet@p...>

Sent: Monday, January 28, 2002 6:33 AM

Subject: [ado_dotnet] Printing from a database





> In a PrintPage event I am opening a data reader and reading the

records

> in a while loop.  When I reach the MarginBounds I am setting

> e.HasMorePages to true followed by a return statement.  When the next

> page attempts to print and the PrintPage event executes again it runs

all

> of the code within the PrintPage method creating an error condition

and

> does not just continue at the same place in the while loop.  How is

the

> process of printing a large number of records from a database usually

> handled?




$subst('Email.Unsub').








$subst('Email.Unsub').


  Return to Index