Gerard has asked for the wisdom of the Perl Monks concerning the following question:
If I take out Line 2278 I receive the same error for the next line. Must be somthing to do with ActiveDocument I guess. By the way - the two scripts are in the same directory and are working in the same directory. Thus I am stumped. Is there any obvious reason as to why this should work in one place but not in the other. In both cases it is in a sub routine all by itself. Any ideas would be greatly appreciated. Cheers, Gerard.my $template = "templates\\standard letter.doc"; my $datasource = "c:\\windows\\desktop\\test.csv"; my $ret = "c:\\windows\\desktop\\test.doc"; use strict; use Win32::OLE ; use Win32::OLE::Const 'Microsoft Word'; my $Word= Win32::OLE->new('Word.Application', 'Quit'); $Word->Documents->Open($template); #line 2278 $Word->ActiveDocument->MailMerge->OpenDataSource($datasource); $Word->ActiveDocument->SaveAs($ret);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Another Win32::OLE question
by cacharbe (Curate) on Oct 20, 2001 at 20:24 UTC | |
by Gerard (Pilgrim) on Oct 21, 2001 at 03:51 UTC | |
by cacharbe (Curate) on Oct 21, 2001 at 07:27 UTC | |
by Gerard (Pilgrim) on Oct 21, 2001 at 08:23 UTC | |
|
Re: Another Win32::OLE question
by traveler (Parson) on Oct 20, 2001 at 20:08 UTC |