Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Visual Basic > VB.NET 1.0 > VB.NET 2002/2003 Basics
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
VB.NET 2002/2003 Basics For coders who are new to Visual Basic, working in .NET versions 2002 or 2003 (1.0 and 1.1).
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB.NET 2002/2003 Basics section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old June 4th, 2004, 08:26 AM
Friend of Wrox
 
Join Date: Sep 2003
Location: , Kent, United Kingdom.
Posts: 130
Thanks: 0
Thanked 0 Times in 0 Posts
Default Printing Multiple Pages

I am having trouble printing to more than one page, at the start of my print document, I set hasmorepages to true and I set it to false at the end of the report. But when the printing message appears it always says print page 1 of document. How do I tell it to print page 2 etc?


Thanks in Advance
Louisa

Reply With Quote
  #2 (permalink)  
Old June 7th, 2004, 04:19 AM
Friend of Wrox
 
Join Date: Sep 2003
Location: , Kent, United Kingdom.
Posts: 130
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I am using this code, I have put it at the end of the report, however each time it hits the if the line count is always the same, as it seems to be printing the first page over and over again.

If LineCount > LinesPerPage Then
            ev.HasMorePages = True
            LineCount = LineCount - LinesPerPage
        Else
            ev.HasMorePages = False
            MessageBox.Show("Report Finished", "Information", MessageBoxButtons.OK, MessageBoxIcon.Information, MessageBoxDefaultButton.Button1)
End If

Louisa

Reply With Quote
  #3 (permalink)  
Old June 7th, 2004, 09:17 AM
Friend of Wrox
Points: 3,489, Level: 24
Points: 3,489, Level: 24 Points: 3,489, Level: 24 Points: 3,489, Level: 24
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Central, NJ, USA.
Posts: 1,102
Thanks: 0
Thanked 2 Times in 2 Posts
Default

It doesn't look like it would work... how does reducing the line count help? I don't see anything here to cause you to move to the next page.


Hal Levy
Web Developer, PDI Inc.

NOT a Wiley/Wrox Employee
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Printing Multiple Pages raja.tadi VB How-To 0 June 26th, 2006 05:19 PM
Printing multiple pages at a go leo_vinay ASP.NET 1.0 and 1.1 Professional 0 November 3rd, 2005 07:22 AM
Printing pages ken killeen VB.NET 2002/2003 Basics 0 October 27th, 2004 07:31 AM
Printing Several Pages Louisa VB.NET 2002/2003 Basics 1 April 8th, 2004 09:26 AM
Printing Web Pages gaghazoul VBScript 0 February 5th, 2004 02:26 PM



All times are GMT -4. The time now is 04:37 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.