Object reference not set to an instance of an object  Topic is solved

Discussions relating to plugin development, and the Jiwa API.

Object reference not set to an instance of an object

Postby jak » Tue Dec 13, 2016 6:40 pm

Hi,

when we were trying to run action it says this error
"Object reference not set to an instance of an object."

we have already checked all our configuration,
can you please tell me steps to fix this issue.

Thank you in Advance!
jak
Occasional Contributor
Occasional Contributor
 
Posts: 22
Joined: Mon Oct 10, 2016 10:00 pm
Topics Solved: 0

Re: Object reference not set to an instance of an object

Postby Mike.Sheen » Tue Dec 13, 2016 8:31 pm

Hi jak,

You're not giving us much to go on here. There are a number of possible reasons why you're getting that error.

Is this caused by a plugin you have written?, or is it one of our standard plugins? Or is it a stand-alone application?

What version of Jiwa is this occurring in?

Mike
Mike Sheen
Chief Software Engineer
Jiwa Financials

If I do answer your question to your satisfaction, please mark it as the post solving the topic so others with the same issue can readily identify the solution
User avatar
Mike.Sheen
Overflow Error
Overflow Error
 
Posts: 2445
Joined: Tue Feb 12, 2008 11:12 am
Location: Perth, Republic of Western Australia
Topics Solved: 757

Re: Object reference not set to an instance of an object

Postby jak » Tue Dec 13, 2016 11:34 pm

Hi!

thanks for your quick reply,
i'm using jiwa version 7, and this error caused on magento integration standard plugin,
on every action given there, when we try to run any of the action it throws this message in logs,

I have attached is snapshot here,

this is happening for every action available in "Available Actions",

can you please tell me steps to fix this issue.

Thank you,
Attachments
jiwaerror.JPG
jak
Occasional Contributor
Occasional Contributor
 
Posts: 22
Joined: Mon Oct 10, 2016 10:00 pm
Topics Solved: 0

Re: Object reference not set to an instance of an object  Topic is solved

Postby Mike.Sheen » Sat Dec 17, 2016 12:20 pm

Hi jak,

To debug this, add some additional logging to the plugin.

In the plugin, search for a method named "CreateMagentoCategoriesFromJiwa" - there is a find tool on the toolbar of the code editor you can use to do this.

The last successful verbose log in your screenshot is "Finished retrieving Catalog tree from magento" - you can see where that is within CreateMagentoCategoriesFromJiwa - it'll look this this:

Code: Select all
MagentoIntegration.LogActivity(String.Format("Finished retrieving Catalog tree from magento"), JiwaMagento.IntegrationAction.LoggingPolicyTypes.Verbose, IntegrationAction);


Copy that line and paste it in various places in the code following to isolate where the issue is. Make sure you change the log text from "Finished retrieving Catalog tree from magento" to something identifiable - I generally use "checkpoint 1", "checkpoint 2", et cetera.

Then run the integration again (you'll need to log out and back into Jiwa after editing the plugin and before running the integration).

This should give us a better idea of that is causing the error. Try to isolate the exact line of code causing the problem, and report back here your findings.

Mike
Mike Sheen
Chief Software Engineer
Jiwa Financials

If I do answer your question to your satisfaction, please mark it as the post solving the topic so others with the same issue can readily identify the solution
User avatar
Mike.Sheen
Overflow Error
Overflow Error
 
Posts: 2445
Joined: Tue Feb 12, 2008 11:12 am
Location: Perth, Republic of Western Australia
Topics Solved: 757


Return to Technical and or Programming

Who is online

Users browsing this forum: No registered users and 8 guests