troubleshooting Question

VB.NET 'Object reference not set to an instance of an object' Loading PDF in Adobe PDF Reader Component

Avatar of FamousMortimer
FamousMortimerFlag for United States of America asked on
Visual Basic.NET
5 Comments1 Solution649 ViewsLast Modified:
Hi Experts,

I am tring to create a form with a PDF viewer in a WPF application.  I am using QuickWPFMonthCalendar that i downloaded here: http://www.codeproject.com/Articles/34052/Quick-and-Simple-WPF-Month-view-Calendar

I created a form and added an AxAcroPDF Control but i receive Object reference not set to an instance of an object error.  Here is the code on Day double click, that is supposed to load a test pdf.

    Private Sub DayBoxDoubleClicked_event(ByVal e As NewAppointmentEventArgs) Handles AptCalendar.DayBoxDoubleClicked
        MessageBox.Show("You double-clicked on day " & CDate(e.StartDate).ToShortDateString(), "Calendar Event", MessageBoxButton.OK)
        Dim frmProject As New frmProjectDetails
        frmProject.AxAcroPDF1.LoadFile("D:\Temp\test.pdf")
        frmProject.Show()
    End Sub
ASKER CERTIFIED SOLUTION
FamousMortimer

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 5 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 5 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros