You need to sign in to do that
Don't have an account?
Karthik j
System.NullPointerException: Attempt to de-reference a null object External entry point
Hii
I am trying to deploy my code from git to sandbox, In the middle of this process I am getting this error.
OLHandler_test afterInsert System.NullPointerException: Attempt to de-reference a null object External entry point.
Can anyone please help in solving this?
I am trying to deploy my code from git to sandbox, In the middle of this process I am getting this error.
OLHandler_test afterInsert System.NullPointerException: Attempt to de-reference a null object External entry point.
Can anyone please help in solving this?
Hi Karthik,
System.NullPointerException: Attempt to de-reference a null object is very common error in apex class. It occurs when your variable (sobject, list, set or any other data type) is not initialized (allocated memory). In order to use the non primitive data type in the code we need to initialize the memory first. If we don’t do that it may result in Attempt to de-reference a null object error. This error may occur in Apex classes, Visualforce pages with Apex controller, Test classes, Apex Triggers.
For more information and their resolution, please refer the below link :-
https://www.sfdcpoint.com/salesforce/system-nullpointerexception-attempt-to-de-reference-a-null-object/
https://developer.salesforce.com/forums/?id=906F00000008xK8IAI
Please mark it as best answer so that it can help others as well.
Regards,
Priya Ranjan
Can you please share the the code of OLHandler_test with line number when you are gettign error due to deploymwnt
Regards
Mukesh
As explained by @Priya you should be able to find the Null Pointer Exception. As mentioned by @Mukesh, if you still need help in identifying the error, you will have to share your code snippet with explanation and don't forgot to highlight the line Number and the error where this Exception is occuring.
Thanks,
Ashish Singh.