use strict; use Win32::OLE; my $PR = Win32::OLE->new('DSOleFile.PropertyReader', 'Quit'); my $filename = "c:\\test.doc"; my $prop = $PR->GetDocumentProperties($filename) || die("Unable read file properties for '$filename' ", Win32::OLE->LastError()); $prop->SetProperty('title', 'My Title'); $prop->SetProperty('subject', 'My Subject'); $prop->SetProperty('author', 'My Author'); $prop->SetProperty('manager', 'My Manager'); $prop->SetProperty('company', 'My Company'); $prop->SetProperty('category', 'My Category'); $prop->SetProperty('keywords', 'My Keywords'); $prop->SetProperty('comments', 'My Comments');