Information générale
Titre:
OLE -- WHAT AM I DOING WRONG??
hello what is wrong with the following code:
code starts here
* use filename && calls for a database
set textmerge on
set textmerge delimiters to
i=1
go 1
do while i<=999999
@ 10,10 say " Processing rec # -->"+str(i)
set textmerge to D:PCLTEST.PRT noshow additive
TEXT
<>
6200 South Syracuse Street, Suite 150
Englewood, CO 80111
TEL: (303) 221-2000 FAX: (303) 221-3000
ENDTEXT
set textmerge to && closes the text file open
&& thru TEXTMERGE
** OLE is here ************************
oWorg=createobject("word.basic")
if i<=1 && loops thru main file, first instance of word
WITH oWorg && opens an instance of Word97
.fileopen("d:\pcltest\test1.doc") && file created and to be used as an "overlay"
.FILEPRINT(1,1,0,"d:\pcltest\pcltest.prt",,,,,,,,1,,)
endwith && assuming Word97 and a HP 5si laser
endif
if i>1 && <--- error line here
WITH oWorg
.fileopen("d:\pcltest\test1.doc") && file created and to be used as an "overlay"
.FILEPRINT(1,1,0,"d:\pcltest\pcltest.prt",,,,,,,,1,,)
endwith
endif
IF EOF()
SKIP -1
I=99999999
ELSE
skip
i=i+1
ENDIF
enddo
set textmerge to
*************
RELEASE ALL
************
Suivant
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