Information générale
Catégorie:
COM/DCOM et OLE Automation
Hello
The way I use is to select the array header after build it, copy it, and paste each time you change page.
To know if you are on a new page, use Word.Selection.Information(wdVerticalPositionRelativeToPage). If The new Position is lower than the old one, you change the page
Before your ENDWITH at the end, insert something like this :
.Row(1).Select
oWord.ActiveDocument.Selection.Copy
#DEFINE wdVerticalPositionRelativeToPage 6
lnVPos = oWord.ActiveDocument.Selection.Information(wdVerticalPositionRelativeToPage)
SELECT TABLE
SCAN
IF lnVPos > oWord.ActiveDocument.Selection.Information(wdVerticalPositionRelativeToPage)
oWord.ActiveDocument.Selection.Paste
ENDIF
lnVPos = oWord.ActiveDocument.Selection.Information(wdVerticalPositionRelativeToPage)
&& Insert tour Row with your data
ENDSCAN
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement