Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hey Guys,
I've been trying to use VBA in Excel to cut and paste to Word a set o cells. I'm trying to use a loop to cut and paste multiple times on differen pages. The problem lies in that everytime I paste it overwrites the previou paste I made. I've tried recording a macro in Word to see wha happens, and everything doesn't work the same way when using excel' macro. It appears that when I make a paste I've still got the previous past selected and it overwrites. Here's a set of code I've been trying to get to work, I REALL appreciate if someone could help me out! I'm desperate and bee banging my head against the wall with this. ![]() With wrdDoc 'Write Data Sheets("Sheet2").Select For iWrd = 0 To Finali - 1 iFirstRow = iWrd * 28 iLastRow = (iWrd * 28) + 27 If iFirstRow = 0 Then iFirstRow = 1 End If Range("A" & iFirstRow & ":B" & iLastRow).Select Selection.Copy .Content.InsertAfter "Header" .Content.PasteExcelTable False, False, False .Content.InsertBreak Next iWr -- Message posted from http://www.ExcelForum.com |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
overwritten files | Excel Discussion (Misc queries) | |||
Overwritten Equations | Excel Discussion (Misc queries) | |||
Overwritten Fil | Excel Discussion (Misc queries) | |||
overwritten file | Charts and Charting in Excel | |||
.XLB OverWritten | Excel Discussion (Misc queries) |