Solved

Displaying PDF inside a VB Form

Posted on 2004-05-03
6
892 Views
Last Modified: 2007-12-19
My eventuall goal is to display PDFs on a vb form.  To begin, I'm using an example which I found in the Adobe SDK.  Without going into the code immediately, upon execution, I receive the following error:

Run-time error '429':
ActiveX component can't create object

The debugger is referencing the following line of code:
Set AcroExchApp = CreateObject("AcroExch.App")

Any suggestions?
0
Comment
Question by:dryale
  • 3
  • 2
6 Comments
 
LVL 4

Expert Comment

by:Arragorn
ID: 10977981
Hi dryale,

Normally that error means simply that it can't find the object you are trying to create ("AcroExch.App") and can be solved by running regsvr32 to make sure that a reference to the object is placed in the Registry.  Are you sure that the objects name ends with .app extension. This is a new one for me I'm used to the objects ending with a .dll extension.

0
 

Author Comment

by:dryale
ID: 10978033
The object name does end with .app.  The code snipet above was copied directly from Adobe SDK samples.  I have not installed the entire Adobe product, just the free: Adobe Reader.  I'm wondering if this makes a difference?  If so, does this mean I would only be able to distribute the application to those who have the full Adobe product?
0
 
LVL 28

Accepted Solution

by:
vinnyd79 earned 50 total points
ID: 10978179
You could try the Webbrowser control (Microsoft Internet Controls).

WebBrowser1.Navigate2 "C:\Somefile.pdf"
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 

Author Comment

by:dryale
ID: 10978211
Yes, i would view it in the browser, however, I have to view it in a form, because I need to add a few listboxes and stuff at the top.
0
 
LVL 28

Expert Comment

by:vinnyd79
ID: 10978235
But the webbrowser control is a control that goes on your form so you can still add your listboxes and stuff.
0
 

Author Comment

by:dryale
ID: 10978672
Thank you very much vinnyd79.  This will work great.
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now