Consuming a Web Service in AX 2012
Consuming a Web Service in AX 2012
在AX2012版本中如果想调用外部的Web Service变得非常容易。
第一步,在VS中创建一个Web Service并发布

第二步,创建一个Class Library,并将创建的Web Services引用到该类库当中,并ADD to AOD中


第三步,用JOB调用该Web Services,运行Job
static void KimConsumeWebService(Args _args)
{
ClassLibrary1.Class1 webService;
ClassLibrary1.ServiceReference1.WebService1SoapClient clients;
System.ServiceModel.Description.ServiceEndpoint endPoint;
System.ServiceModel.EndpointAddress endPointAddress;
System.Type type;
System.Exception ex;
;
try
{
type = CLRInterop::getType('ClassLibrary1.ServiceReference1.WebService1SoapClient');
clients = AifUtil::createServiceClient(type);
print clients.Kim();
pause;
}
catch(Exception::CLRError)
{
ex = CLRInterop::getLastException(); while(ex)
{
info(CLRInterop::getAnyTypeForObject(ex.ToString()));
ex = ex.get_InnerException();
}
}
}

Consuming a Web Service in AX 2012的更多相关文章
- Dynamics AX 2012 R2 安装 AIF IIS上的Web服务
1.为什么使用IIS上的WEB服务 组件? 如果你要在Dynamics AX Service中使用HTTP Adapter,那么你就要安装IIS上的WEB服务 组件.HTTP Adapter会在IIS ...
- 【转载】在 Visual Studio 2012 中创建 ASP.Net Web Service
在 Visual Studio 2012 中创建 ASP.Net Web Service,步骤非常简单.如下: 第一步:创建一个“ASP.Net Empty Web Application”项目 创建 ...
- Consuming a RESTful Web Service
本篇文章将介绍使用Spring来建立RESTful的Web Service. 我们通过一个例子来说明这篇文章:这个例子将会使用Spring的RestTemplate来从Facebook的提供的API中 ...
- Error in WCF client consuming Axis 2 web service with WS-Security UsernameToken PasswordDigest authentication scheme
13down votefavorite 6 I have a WCF client connecting to a Java based Axis2 web service (outside my c ...
- Part 17 Consuming ASP NET Web Service in AngularJS using $http
Here is what we want to do1. Create an ASP.NET Web service. This web service retrieves the data from ...
- Web Service 中返回DataSet结果大小改进
http://www.cnblogs.com/scottckt/archive/2012/11/10/2764496.html Web Service 中返回DataSet结果方法: 1)直接返回Da ...
- Dynamics AX 2012 R2 安装Reporting Services 扩展
今天Reinhard在VS中部署SSRS报表时,接到以下错误: 部署因错误而被取消.在报表服务器上,验证:-SQL Server Reporting Services 服务是否正在运行. 接着,Rei ...
- Dynamics AX 2012 R2 配置报表服务器
今天Reinhard在使用报表的过程中,发现以下错误: The default Report Server Configuration ID could not be found in the SRS ...
- AX 2012 EP服务器配置多个环境
AX 2012 如何在一台服务器配置不同环境的EP站点 安装完EP后,修改对应站点的web.config文件,指定需要连接的客户端配置文件路径即可,如下图: ` ``````````````````` ...
随机推荐
- python3读取chrome浏览器cookies
好几年前我在做一些自动化的脚本时,脑子里也闪过这样的想法:能不能直接把浏览器的cookies取出来用呢? 直到昨天看到代码<python模拟发送动弹>,想起来当年我也曾经有类似的想法没能完 ...
- (转)深入理解JavaScript 模块模式
深入理解JavaScript 模块模式 (原文)http://www.cnblogs.com/starweb/archive/2013/02/17/2914023.html 英文:http://www ...
- 黑马程序员——【Java基础】——网络编程
---------- android培训.java培训.期待与您交流! ---------- 一.网络模型概述 网络模型示意图: 说明: (1)数据的传输:在用户端,应用层的数据,经过层层封包,最后到 ...
- SCC(强连通分量)
1.定义: 在有向图G中,如果两个顶点间至少存在一条路径,称两个顶点强连通(SC---strongly connected). 有向图中的极大强连通子图,成为强连通分量(SCC---strongly ...
- 【LeetCode OJ】Binary Tree Level Order Traversal II
Problem Link: https://oj.leetcode.com/problems/binary-tree-level-order-traversal-ii/ Use BFS from th ...
- 【LeetCode OJ】Balanced Binary Tree
Problem Link: http://oj.leetcode.com/problems/balanced-binary-tree/ We use a recursive auxilar funct ...
- webmin-1.810 安装
Installing the tar.gz file Before downloading Webmin, you must already have Perl 5 installed on your ...
- ssh连接linux服务器只显示-bash-4.1#不显示路径解决方法
ssh连接linux服务器只显示-bash-4.1#不显示路径时,我们只需要修改 ~/.bash_profile文件,如果不存在这个文件,那么新建一个,增加内容 export PS1='[\u@\ ...
- Xml Schema:C#访问在complextype中插入新元素
最近用c#写Xml Schema代码,找了很久也找不到如何在已有的complextype中插入新的element,最后我充分发挥自己的聪明才智,哈哈,终于从...中找到了灵感. XmlSchemaSe ...
- M2: XAML Controls(2)
在前小节中,我们在Card程序的主界面中加入了简单的XAML控件, 本小节将在其基础上进行优化,使界面看上去更加美观.本小节用到了Grid Control, Border Control,以及XAML ...