web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

What's difference calling Custom Service from .NET Application or from WebApp in same Host

(0) ShareShare
ReportReport
Posted on by 900

Hello, I have a weird problem calling Custom Services(Web Services) from ASP.NET MVC application running in the same AX host where AOS is running my Custom Services.

I have made a simple Console based Application calling my Custom Services. Configuration in this Console Application is exactly same that it is in MVC based Web Application. When I run Console Application in same Host where Custom Services are, calling Custom services works fine, but when running Web Application in same Host's IIS calling those same Custom Services I get error that 'connection is refused'.

So what is the difference running Console Application or Web Application in same Host? Only what I know are permissions etc what comes when logging into system with user's account or what are the permissions for Web Application or it's pool running under IIS in same Host.

Have any of you any ideas how to solve this problem?

My Custom Sevices running under AOS have default Security settings like shown in the picture below

Config files in Web Application and Console Application are identical what comes to Web Service usage settings

<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
</startup>
<system.serviceModel>
<bindings>
<netTcpBinding>
<binding name="NetTcpBinding_WebServicesForWebUIService" />
</netTcpBinding>
</bindings>
<client>
<endpoint address="net.tcp://node7:8201/DynamicsAx/Services/WebServicesForWebUIServiceGroup"
binding="netTcpBinding" bindingConfiguration="NetTcpBinding_WebServicesForWebUIService"
contract="WebServicesForWebUIService" name="NetTcpBinding_WebServicesForWebUIService">
<identity>
<userPrincipalName value="domain_aos_service@weblan.local" />
</identity>
</endpoint>
</client>
</system.serviceModel>
</configuration>

I also use same proxy .cs class both Console and Web Application which are created with svcutil.

Thanks,

Mike


*This post is locked for comments

I have the same question (0)
  • Mike Land Profile Picture
    900 on at

    Sorry, Web Application's error is "Failed to logon to Microsoft Dynamics AX.".

    So, can anyone give advice what could be wrong?

  • Verified answer
    Mike Land Profile Picture
    900 on at

    Solved the problem by myself.

  • Ivan (Vanya) Kashperuk Profile Picture
    on at

    Would you mind actually explaining your solution for others to benefit from it as well?

    Thanks

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans