Hi,
My need today is to create a report for a worklow which creates a VM.
My first thought was to create a word document with bookmarks, and use VCO PowerShell plugin to run a script which edit bookmarks values..
I end up with a well-running script on my PowerShell host. But as soon as I try to call it from VCO, I end up with messages llike this
Script is very light and simple
$Filename = "C:\data\Scripts\Bookmark1.docx"
$Word = New-Object -ComObject Word.Application
$Document = $Word.documents.open($Filename)
$Bookmark = $Document.Bookmarks("Book2").Select()
$Word.Selection.text = "Bookmark is filled"
I've digged up a bit, and it seems that, as soon as VCO hits line 4, it goes boom.
Does anybody had any experience with this ? Can you help me ?
Thanks