By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,534 Members | 943 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,534 IT Pros & Developers. It's quick & easy.

trouble with Excel and 'vpagebreak'

P: n/a
To All:

I am a newbie to VB.net and am writing an application in VB.net in which I
successfully create an Excel sheet, tabulate and format some data on a sheet
titled "summarySheet".

A difficulty arises when I try to define where a page break should be. I
need to fit a landscape table on one sheet. I thought that "telling" Excel
where the vertical page break is would cause it to reduce the zoom factor,
thus fitting the table on one page. The vertical page break appears to have
been ignored.

The following bit of code shows how the pertinent object are defined.

Any ideas?

Thanks,
Ron

'-------------------------
Dim exc As New Excel.Application()
Dim summarySheet As Excel.Worksheet

summarySheet.ResetAllPageBreaks()
summarySheet.VPageBreaks.Add(exc.Range("J8"))
'-------------------------


Nov 20 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.