LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 128
Default Help with ammending a script

This script copies the first 14 entires from column A to sheet 2, then prints
sheet 2 then it does the same again but with the next 14

What I want it to do is copy the first 14 into dfferntet cells rather than
the same

Sub Print14()

Dim PrintRng As Range
Dim ws1 As Worksheet, ws2 As Worksheet

Set ws1 = Worksheets("sheet1")
Set ws2 = Worksheets("sheet2")

Set PrintRng = ws2.Range("a2")

ws2.PageSetup.PrintArea = "a2:a15"

With ws1
lastrow = .Cells(Rows.Count, 1).End(xlUp).Row
For i = 2 To lastrow Step 14
.Range("a" & i).Resize(14, 1).Copy PrintRng
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Next i
End With

End Sub


any ideas

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200601/1
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Addin for updating database by ammending pivottable nc Excel Discussion (Misc queries) 0 November 6th 06 08:51 AM
VB script help..please !! Anthony Excel Worksheet Functions 2 June 5th 05 03:26 PM
Excel 2000/XP script to Excel97 script hat Excel Programming 3 March 2nd 04 03:56 PM
Script? Scrappy[_2_] Excel Programming 1 July 21st 03 08:44 PM
what is a vb script george Excel Programming 1 July 16th 03 09:56 AM


All times are GMT +1. The time now is 02:59 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"