use strict; use Win32::OLE; my $WordApp = Win32::OLE->GetActiveObject("Word.Application"); #blah blah