Hello All,
I am working with NAV web services through VS 2008.
When I tried to execute one function of one codeunit of NAV published as a web-service, It got executed completely and after last line of function execution, I am gett9ing the following error:
"The type Microsoft.Dynamics.Nav.Runtime.INavRecordHandle is unknown."
Please help me if you have any idea.
Thanks.
Ravi_Thakkar
Ahmedabad, Gujarat, India
E Mail :
ravi.thakkar@hotmail.com 0
Answers
Also what kind of code are you executing?
Independent Consultant/Developer
blog: https://dynamicsuser.net/nav/b/ara3n
Web Services are able to throw an error on web from NAV ERROR messages.
So, I put, ERROR message in last line of my function.
So, instead of showing "The type Microsoft.Dynamics.Nav.Runtime.INavRecordHandle is unknown." ERROR,
It displayed, my ERROR message on web.
So, I can come to know about the success of execution up to which line.
Ahmedabad, Gujarat, India
E Mail : ravi.thakkar@hotmail.com
I would like to replicate the issue.
Independent Consultant/Developer
blog: https://dynamicsuser.net/nav/b/ara3n
ExpenseClaimedByEmployee(VAR PurchHeader_IRec : Record "Purchase Header")
It is giving me the result in exception : ABC
That means successful execution of whole function up to ERROR('ABC') stmt.
If i am not putting the ERROR('ABC') stmt then it is showing me the error
Microsoft.Dynamics.Nav.Runtime.INavRecordHandle is Unknown
Can you help me?
Ahmedabad, Gujarat, India
E Mail : ravi.thakkar@hotmail.com
Group Program Manager, Client
Microsoft Dynamics NAV
http://blogs.msdn.com/freddyk
The information in this post is provided "AS IS" with no warranties, and confers no rights. This post does not represent the thoughts, intentions, plans or strategies of my employer. It is solely my opinion.
Ahmedabad, Gujarat, India
E Mail : ravi.thakkar@hotmail.com
ExpenseClaimedByEmployee(VAR PurchHeader_IRec : Record "Purchase Header")
This probably means that Webservices will see this as a function taking a Record as parameter (which in your C# method is a key) and returning a Record - which cannot be done - there you have it.
I am just guessing here - haven't tried it.
Group Program Manager, Client
Microsoft Dynamics NAV
http://blogs.msdn.com/freddyk
The information in this post is provided "AS IS" with no warranties, and confers no rights. This post does not represent the thoughts, intentions, plans or strategies of my employer. It is solely my opinion.
Thanks for your response.
I think you may be right.
I have used the Function Parameter as a Pass By Reference. I will try to change it and try to do that. Will revert back.
Thanks.
Ahmedabad, Gujarat, India
E Mail : ravi.thakkar@hotmail.com
You were right.
Actually I had one Variable as a Parameter which was a "Pass By Reference Variable".
I changed the logic and removed that variable and it worked.
Thanks.
Ahmedabad, Gujarat, India
E Mail : ravi.thakkar@hotmail.com