Highlighted
Absent Member.
Absent Member.
538 views

[archive] Object reference not set to an instance of an object

[Migrated content. Thread originally posted on 25 September 2007]

I get the above error when I perform the following line of code

MODIFY OUTLOOK-ADD @SaveContacts(OUT-XML-STRING).

OUT-XML-STRING is just a variable containing information. It is not null.


I have created the Object before the SaveContacts line code using

CREATE ContactCreater HANDLE IN OUTLOOK-ADD (OUTLOOK-ADD USAGE IS HANDLE OF ContactCreater) (This does not give me an error and OUTLOOK-ADD is a numeric value)

Here is the DEF file

>>IMP(ACU-CBLFLAGS=-Sa)
* K:\68\work\OUTLOOK.DEF - OLE object definitions for OutlookAddin
* Generated: Monday, September 24, 2007
OBJECT @OutlookAddin

* ContactCreater
CLASS @ContactCreater
CLSID, EF866FC1-20C8-4C9C-9934-8463F58476F4
NAME, "ContactCreater"
DEFAULT-INTERFACE, "ContactCreaterEvents"
* SaveContacts
METHOD, 2, @SaveContacts,
"BSTR" @pContactsXMLData, TYPE 8


Does anyone know why I am getting the error "Object reference not set to an instance of an object" when the SaveContacts line is performed?
0 Likes
1 Reply
Highlighted
Absent Member.
Absent Member.

RE: [archive] Object reference not set to an instance of an object

Can you post the .def file also?
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.