Connect two NAV databases by consuming NAV WS

Lec11Lec11 Member Posts: 91
edited 2012-03-15 in NAV Three Tier
Hello!

I'm trying to connect two NAV 2009 databases by using NAV web services. I was able to read data from another database by reading Freddy Kristiansen's blog: http://blogs.msdn.com/b/freddyk/archive/2010/01/22/connecting-to-nav-web-services-from-microsoft-dynamics-nav-2009-sp1.aspx. However I'm having difficulties in using page update method ... it seems much easier in using it in the .NET environment. Can somebody at least show me the right direction in using this method from NAV?

Thanks!

Answers

  • Lec11Lec11 Member Posts: 91
    Meanwhile I became more interested in using .NET interop for consuming NAV web services from inside NAV. This happened after I found Waldo's very useful article http://dynamicsuser.net/blogs/waldo/archive/2010/12/30/nav-2009-r2-net-interop-calling-a-web-service.aspx.

    I'm setting the security mode to TransportCredentialOnly, client authentication to windows and impersonation level to delegation. When I try to call from RTC the web service, I get the following authorization error:
    This message is for C/AL programmers: The call to member Read failed: The remote server returned an error: (401) Unauthorized..

    I get the error even if I run it from the same machine as the web service. Everything is setup correctly ... the web service is up and running, as long as I can call it with success from .NET application for example. Does anybody have an idea of what else do I have to check?

    Thanks!
  • Lec11Lec11 Member Posts: 91
    Problem solved ... changed client authentication to Ntlm and it works. :D
  • julkifli33julkifli33 Member Posts: 1,092
    Lec11 wrote:
    Problem solved ... changed client authentication to Ntlm and it works. :D
    i have problem when accessing webservice
    the error message is
    Access denied. Delegation or Impersonation permission is required for access.

    is it the same as your problem?
    how to solve it?
  • ara3nara3n Member Posts: 9,256
    the issue to the above error is delegation issue. You need to setup correct http SPN. take a look at MSDN documentation on how to setup 3 tiered environment.
    Ahmed Rashed Amini
    Independent Consultant/Developer


    blog: https://dynamicsuser.net/nav/b/ara3n
Sign In or Register to comment.