Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re^2: Win32::OLE and Word: accessing all headers and comments

by roho (Bishop)
on Mar 19, 2019 at 11:00 UTC ( [id://1231425]=note: print w/replies, xml ) Need Help??


in reply to Re: Win32::OLE and Word: accessing all headers and comments
in thread Win32::OLE and Word: accessing all headers and comments

I was facing a similar issue and your code sample was just the thing I needed. For my system (Windows 10 -- Office 2016) I had to make Win32::OLE::Const more generic, and I added "close" and "quit" to close the document and end MS Word. Thank you poj for the sample code.
use Win32::OLE::Const "Microsoft Office .* Object Library"; # Close document $Doc->Close(); undef $Doc; # Close MS Word $Word->Quit(); undef $Word;

"It's not how hard you work, it's how much you get done."

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1231425]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (6)
As of 2024-04-23 18:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found