Pagebreak in Excel from VBA Access

tdubs

Registered User.
Local time
Today, 04:17
Joined
May 30, 2006
Messages
27
Hi,

How can I make a pagebreak in a excel spreadsheet from VBA ACCESS

I recorded a macro in excel to see how is the syntax of the code....

it came out to be
ActiveWindow.SelectedSheets.HPageBreaks.Add Before:=ActiveCell


so I change my code to
xlbook.Sheets(sheetname).HPageBreak.Add

but it doesnt work. I have tried chaing the above code but still says that it doesnt support that method..


Your help is much appreciatte it. Thanks in advance
 
Hello,
I'm having the exact same problem as you. I want to reset and add new page breaks in a new worksheet that is created from VBA code in Access.

Did you ever figure out how to?
 

Users who are viewing this thread

Back
Top Bottom