5142 error when attemtpting to print to pdf from word 2007

I am migrating an Access 2003 application to 2007.  The application has an option to allow users to create word, pdf, and text copies to file.  The problem is that the code crashes when attempting to create the pdf file.  The 2003 version works fine.  I've already set the Adobe PDF setting and cleared the box labeled "Rely on system fonts only; do not use document fonts"
        'Open the folder with all the new Access
    Set fso = New FileSystemObject
    Set fldr = fso.GetFolder(stPath)
        'Open a new Distiller object
    Set oDistiller = New PdfDistiller6
        'Enumerate files in the save folder and convert .doc to .pdf
    SysCmd acSysCmdSetStatus, "Converting Word documents to Adobe PDF files...Please Wait..."
    For Each fl In fldr.Files
        If Right(fl.Name, 4) = ".doc" Then
            sOutputPDFName = stPath & Left(fl.Name, Len(fl.Name) - 3) & "pdf"    'Set pdf name
            Set wdDoc = wdObj.Documents.Open(stPath & fl.Name)                   'Open Doc
            wdDoc.PrintOut False, , , stPath & "tmp"                             'Print a temp ps file   
            wdDoc.Close False                                                    'Close the Doc
            oDistiller.FileToPDF stPath & "tmp", sOutputPDFName, "Print"         'Convert temp ps the .pdf
            Kill stPath & "tmp"                                                  'Delete the temp ps file
        End If
    Next fl
    Set oDistiller = Nothing
    Set fso = Nothing

Open in new window

Juan VelasquezAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Without automation, can you manually print to pdf when you open a word 2007 doc? If you cant there then that could explain it.

Its nothing silly like updated drivers required or anything like that is it? What version acrobat you got. I dont know if there are compatability problems maybe with the version you have with office 2007

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Juan VelasquezAuthor Commented:
I think it was a compatibility issue.  In Acrobat I ran the Repair utility and everything then worked.  Go figure.
Cool :)
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.