I need to open a PDF document and paint it to my own Graphics object.
The first step in that appears to be creating a IacDocument.
IacDocument * aiDoc;
aiDoc = new IacDocument(NULL);
That 2nd line yields a Null Reference Exception. What's going on that I can't even get to square one?
Thanks.
Daniel Wilson
NULL Reference Exception when creating IacDocument
Still getting NULL Reference
I'm back to PDFCreator after experimenting elsewhere ... trying again.
According to the VS Object Browser, a new IacDocument wants a System.Windows.Forms.ScrollableControl as an argument to the constructor. So I have put a Panel named panel1 on my form. System.Windows.Forms.Panel inherits from System.Windows.Forms.ScrollableControl, so this should be good:
IacDocument * aiDoc;
aiDoc = new IacDocument(panel1);
I still get the NULL Reference Exception.
What am I doing wrong?
thanks.
According to the VS Object Browser, a new IacDocument wants a System.Windows.Forms.ScrollableControl as an argument to the constructor. So I have put a Panel named panel1 on my form. System.Windows.Forms.Panel inherits from System.Windows.Forms.ScrollableControl, so this should be good:
IacDocument * aiDoc;
aiDoc = new IacDocument(panel1);
I still get the NULL Reference Exception.
What am I doing wrong?
thanks.
The declaration of the the document object is as follows:
IacDocument document = new IacDocument( null )
However you need to initialize the library and activate it first by calling:
// initialize the library and set our license key
acPDFCreatorLib.Initialize();
acPDFCreatorLib.SetLicenseKey(licensee, activationCode);
Hope this helps.
IacDocument document = new IacDocument( null )
However you need to initialize the library and activate it first by calling:
// initialize the library and set our license key
acPDFCreatorLib.Initialize();
acPDFCreatorLib.SetLicenseKey(licensee, activationCode);
Hope this helps.