J
John Bundy
Thanks for looking
I work with Excel a lot and have built an array of string values, there are
about 200 in the test. I am trying to output these to word using code found
here, I'm getting no errors but nothing is happening either. Thanks for any
help and the code is below
Set owordapp = CreateObject("Word.Application")
'open a new document in Word
owordapp.Documents.Add DocumentType:=wdNewBlankDocument
owordapp.Visible = True
storeIndex = 1
'===THIS IS THE PROBLEM==========
Do Until storeArray(storeIndex, 16) = ""
activedocument.Range.insertafter storeArray(storeIndex, 16) & vbCrLf
activedocument.Range.insertafter storeArray(storeIndex, 17) & vbCrLf
storeIndex = storeIndex + 1
Loop
Probably something easy but I'm lost in Word
I work with Excel a lot and have built an array of string values, there are
about 200 in the test. I am trying to output these to word using code found
here, I'm getting no errors but nothing is happening either. Thanks for any
help and the code is below
Set owordapp = CreateObject("Word.Application")
'open a new document in Word
owordapp.Documents.Add DocumentType:=wdNewBlankDocument
owordapp.Visible = True
storeIndex = 1
'===THIS IS THE PROBLEM==========
Do Until storeArray(storeIndex, 16) = ""
activedocument.Range.insertafter storeArray(storeIndex, 16) & vbCrLf
activedocument.Range.insertafter storeArray(storeIndex, 17) & vbCrLf
storeIndex = storeIndex + 1
Loop
Probably something easy but I'm lost in Word