in reply to Adding MSWord custom properties in Win32::OLE
At the time we were doing lots of MS stuff, fortunately those days are now long past, but maybe this will help.use strict; use Win32::OLE qw(in); use Win32::OLE::Const 'Microsoft Office'; my $Doc = Win32::OLE->GetObject('g:\scratch\test.doc'); if ( ( 0 + Win32::OLE::LastError() ) != 0 ) { $Doc->CustomDocumentProperties->Add( { Name => 'A custom property', LinkToContent => 0, Type => msoPropertyTypeString, Value => "Whatever" } ); }
|
---|
Replies are listed 'Best First'. | |
---|---|
Putting it all together
by thoglette (Scribe) on Sep 06, 2006 at 05:06 UTC |