This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

DEVELOPERS FORUM - Returning Null Exception when adding Item using AML....

raviraj - Tuesday, April 19, 2011 9:51 AM:

Hello All

I m adding Item Using AML

string _newBomCompRel = "<AML>" +
                                                   "<Item type = 'ahi_part_request' action = 'add'>" +
                                                      "<related_id>" + compId + "</related_id>" +
                                                      "<source_id>" + assmblyId + "</source_id>" +
                                                   "</Item>" +
                                                  "</AML>";
                Item newBomCompRel = MyInnovator.applyAML(_newBomCompRel);

When i run this it Retrns the Error "NullReference Exception was Unhandled"

Object reference not set to an instance of an object.

do anybody know this ..... Please Help.....

 



Brian - Tuesday, April 19, 2011 10:03 AM:

Hi Raviraj,

First check that the AML works from the NASH script. Then you will know if the AML is correct.

I suspect that "MyInnovator" has not been created correctly. You should try to debug the code so that you can see what is actually happening.

Cheers,

Brian.