# Re: Win32ole & Adobe Acrobat Reader

**URL:** <https://www.ruby-forum.com/t/re-win32ole-adobe-acrobat-reader/75072>\
**Category:** Ruby\
**Created:** [November 7, 2006, 11:08am UTC](https://www.ruby-forum.com/t/re-win32ole-adobe-acrobat-reader/75072 "2006-11-07T11:08:57Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![philpraxis](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/p/77aa72/32.png) [@philpraxis](https://www.ruby-forum.com/u/philpraxis)\
**Post date:** [November 7, 2006, 11:08am UTC](https://www.ruby-forum.com/t/re-win32ole-adobe-acrobat-reader/75072/1 "2006-11-07T11:08:57Z")

</div>

Philippe L. wrote:

> > filename = “myfile.pdf”  
> > Works great, thanks a lot! I’ll keep on trying the OLE way of  
> > doing things: printing in the background could be useful too.

Here we are:

acrobat = WIN32OLE.new(‘AcroExch.App’)  
doc = WIN32OLE.new(‘AcroExch.AVDoc’)  
acrobat.show  
doc.open(“c:\Program Files\Microsoft Space-Bearing  
Paths\Are\Evil.pdf”, “ok”)  
#doc.printpagesex(0, 0, false, true, true, false, true, true, true)  
acrobat.exit

In order to discover the OLE Automation interfaces, I recommend this  
ruby program:

[http://homepage1.nifty.com/markey/ruby/win32ole/index\_e.html](http://homepage1.nifty.com/markey/ruby/win32ole/index_e.html)

Does anyone know how to retreive and change the default printer maybe?
