E_POINTER

Invalid Pointer

Beckhoff · TwinCAT 2 Automation Interface

What does E_POINTER mean?

An invalid pointer was provided to the function. For ProduceXml(), this applies to the output pXML parameter, indicating the variable to store the XML string is not properly allocated. For CreateChild(), this means the pipItem pointer, intended to receive the new child item's interface, is invalid, preventing the successful creation and return of the child item.

Common Causes

  • A null pointer was dereferenced in the control software.
  • An invalid memory address was accessed.
  • A corrupted variable reference points to an uninitialized memory location.

Repair Steps & Checklist

Click steps to track your progress.

  1. 1

    Ensure the output pXML or pipItem parameter is a valid, allocated pointer capable of receiving the expected output (BSTR or ITcSmTreeItem interface).

  2. 2

    Check for memory allocation issues in the calling code or improper variable declaration for the output parameter.

  3. 3

    Verify the calling environment's COM object handling and pointer management conventions.

Browse all codes in this manual (12)
Verified technical data. Last updated: March 2026

Related Faults

Source: Beckhoff TwinCAT 2 Automation Interface