Acrobat 9 PDDoc Object Not Created for Some Users (VB6 App)

We have an old VB6 app that uses the Acrobat Type Library to access and manipulate the PDDoc object in pdf files. It has run for years using Acrobat 6. We upgraded to Acrobat 9, and the code worked fine on my PC, and when I installed it on users' workstations.

It also presents a view of the pdf using the AcroPDF dll (was pdf.ocx under Acrobat 6), which works fine.

I installed both the Acrobat 9 and our app on our Terminal Server (through Add/Remove Programs). I logged in as administrator, with Domain Admin rights.

For users accessing it through theTerminal Server, it does not work uless they are signed with the same login. It doesn't even work for me when I log in with my own name, and my login also has Domain Admin rights. (There is one other user it does work for, and he and I have the same rights!)

We then uninstalled Acrobat 9, went back to 6, went back to the original app, and now it is doing the same thing under Acrobat 6, which it had never done before. So something was different after the Acrobat 9 install, and is still giving us problems we never had.

They get an error: "object variable or with block variable not set".

The app creates an instance of a dll we wrote (in VB6) and :calls a method:
Set AcroInvoice = New SRSClaimsUI_Equity.AcrobatInvoice
TDBNDeletePageFrom.MaxValue = AcroInvoice.GetPageCount(m_strLoadFileName)

The AcroInvoice.GetPageCount method creates the PDDoc object and then just looks for the page count:
Set pdTarget = CreateObject("AcroExch.PDDoc")
GetPageCount = pdTarget.GetNumPages

It is either blowing up at the call to the dll method, or when the dll tries to call GetNumPages.

I assume that it either can't get to the dll (it's in the same folder and is registered by the set program, or can't get to Acrobat. But it can show the pdf with AcroPDF (on another form), so it does access Acrobat.

This is a critical application. Any help would be very appreciated. Thanks.
Who is Participating?
bobhwestConnect With a Mentor Author Commented:
We found the solution. There is a profile file in Terminal Server that controls each user's access. We deleted that file and the other users were able to use the system.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.