资源简介
里面所有用到的有头文件、动态库。还有个连接用的DEMO... SAP项目必备~ VS下的开发包。里面所有用到的有头文件、动态库
代码片段和文件信息
#include
#include
#include “sapnwrfc.h“
void errorHandling(RFC_RC rc SAP_UC* description RFC_ERROR_INFO* errorInfo RFC_CONNECTION_HANDLE connection){
printfU(cU(“%s: %d\n“) description rc);
printfU(cU(“%s: %s\n“) errorInfo->key errorInfo->message);
// It‘s better to close the TCP/IP connection cleanly than to just let the
// backend get a “Connection reset by peer“ error...
if (connection != NULL) RfcCloseConnection(connection errorInfo);
exit(1);
}
//usage: companyClient
int mainU(int argc SAP_UC** argv){
RFC_RC rc = RFC_OK;
RFC_CONNECTION_PARAMETER loginParams[6];
RFC_ERROR_INFO errorInfo;
RFC_CONNECTION_HANDLE connection;
RFC_FUNCTION_DESC_HANDLE bapiCompanyDesc;
RFC_FUNCTION_HANDLE bapiCompany;
RFC_STRUCTURE_HANDLE returnStructure;
SAP_UC message[221] = iU(““);
RFC_BYTE buffer[1105];
unsigned utf8Len = 1105 resultLen;
FILE* outFile;
loginParams[0].name = cU(“ashost“); loginParams[0].value = argc > 1 ? argv[1] : cU(“hostname“);
loginParams[1].name = cU(“sysnr“); loginParams[1].value = argc > 2 ? argv[2] : cU(“05“);
loginParams[2].name = cU(“client“); loginParams[2].value = argc > 3 ? argv[3] : cU(“800“);
loginParams[3].name = cU(“user“); loginParams[3].value = argc > 4 ? argv[4] : cU(“user“);
loginParams[4].name = cU(“passwd“); loginParams[4].value = argc > 5 ? argv[5] : cU(“*****“);
loginParams[5].name = cU(“lang“); loginParams[5].value = argc > 6 ? argv[6] : cU(“JA“);
connection = RfcOpenConnection(loginParams 6 &errorInfo);
if (connection == NULL) errorHandling(rc cU(“Error during logon“) &errorInfo NULL);
bapiCompanyDesc = RfcGetFunctionDesc(connection cU(“BAPI_COMPANY_GETDETAIL“) &errorInfo);
if (bapiCompanyDesc == NULL) errorHandling(rc cU(“Error during metadata lookup“) &errorInfo connection);
bapiCompany = RfcCreateFunction(bapiCompanyDesc &errorInfo);
// Use a company ID that does not exit. 000007 should not exist in most systems.
RfcSetChars(bapiCompany cU(“COMPANYID“) cU(“000007“) 6 &errorInfo);
rc = RfcInvoke(connection bapiCompany &errorInfo);
if (rc != RFC_OK) errorHandling(rc cU(“Error calling BAPI_COMPANY_GETDETAIL“) &errorInfo connection);
RfcGetStructure(bapiCompany cU(“RETURN“) &returnStructure &errorInfo);
RfcGetString(returnStructure cU(“MESSAGE“) message 221 &resultLen &errorInfo);
RfcDestroyFunction(bapiCompany &errorInfo);
RfcCloseConnection(connection NULL);
// On Windows you can use the following function from windows.h toconvert to UTF-8:
// utf8Len = WideCharToMultiByte(CP_UTF8 0 message strlenU(message) buffer 1105 NULL NULL);
// It will have a slightly better performance than RfcSAPUCToUTF8().
// On ‘system i‘ with Japanese double byte characters using the ASCII LIBSAPNRFC the
// message string does not contain UNICODE but JIS encoded data. The call to the
// following
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 25600 2017-11-23 17:51 nwrfcsdk\bin\rfcexec.exe
文件 14336 2017-11-23 17:51 nwrfcsdk\bin\startrfc.exe
文件 3974 2017-08-14 15:26 nwrfcsdk\demo\companyClient.c
文件 1377 2017-08-14 15:26 nwrfcsdk\demo\readme.txt
文件 29360 2017-08-14 15:26 nwrfcsdk\demo\rfcexec.cpp
文件 1081 2017-08-14 15:26 nwrfcsdk\demo\rfcexec.h
文件 21298 2017-10-26 02:05 nwrfcsdk\demo\sapnwrfc.ini
文件 13656 2017-08-14 15:26 nwrfcsdk\demo\sflightClient.c
文件 6617 2017-08-14 15:26 nwrfcsdk\demo\sso2sample.c
文件 10371 2017-08-14 15:26 nwrfcsdk\demo\startrfc.cpp
文件 769 2017-08-14 15:26 nwrfcsdk\demo\startrfc.h
文件 10169 2017-08-14 15:26 nwrfcsdk\demo\stfcDeepTableServer.c
文件 54195 2017-08-14 15:22 nwrfcsdk\include\sapdecf.h
文件 227325 2017-11-23 04:11 nwrfcsdk\include\sapnwrfc.h
文件 193566 2017-10-19 02:07 nwrfcsdk\include\sapuc.h
文件 21625 2017-08-14 15:22 nwrfcsdk\include\sapucx.h
文件 8847360 2017-11-23 05:26 nwrfcsdk\lib\icudt34.dll
文件 843776 2017-11-23 05:26 nwrfcsdk\lib\icuin34.dll
文件 946176 2017-11-23 05:26 nwrfcsdk\lib\icuuc34.dll
文件 65536 2017-11-23 05:30 nwrfcsdk\lib\libicudecnumber.dll
文件 180224 2017-11-23 05:29 nwrfcsdk\lib\libsapucum.dll
文件 25040 2017-11-23 05:29 nwrfcsdk\lib\libsapucum.lib
文件 246144 2017-11-23 05:30 nwrfcsdk\lib\sapdecfICUlib.lib
文件 4444160 2017-11-23 17:51 nwrfcsdk\lib\sapnwrfc.dll
文件 49672 2017-11-23 17:50 nwrfcsdk\lib\sapnwrfc.lib
文件 0 2018-01-11 11:27 nwrfcsdk\SIGNATURE.SMF
目录 0 2018-01-11 11:27 nwrfcsdk\bin
目录 0 2018-01-11 11:27 nwrfcsdk\demo
目录 0 2018-01-11 11:27 nwrfcsdk\doc
目录 0 2018-01-11 11:27 nwrfcsdk\include
............此处省略5个文件信息
- 上一篇:mcgs的介绍
- 下一篇:MODBUS电压电流表程序+上位机
相关资源
- CleanWipe14.0.3752
- SAP 异步接口创建步骤、PI配置MB PI 九
- SAP PI配置流程完整版ecc端发布RFC服务
- Openwind_x86_x64风资源评估、风机自动优
- openwrt x86
- 某公司SAP_HR全套操作手册V1.0
- KENWOOD(健伍)TK-8100(C6)车台(中文
- CSAPP课件-中科大
- 三元达WPB-5000-I-T-GN-27P无线AP编程器固
- SAPNetWeaver安装详细手册
- SAP SRM 介绍
- openwrt-18.06.4-ramips-mt7621-hc5962-squashfs-
- hikvision-isapi
- 磊科nw736刷海蜘蛛营销固件编程器固件
- 0508-openwrt-ramips-rt305x-hg255d-squashfs-By_
- RFC 6241 (Network Configuration Protocol (
- CleanWipe (1).zip
-
SAP Businessob
jects Web Intelligence 用户指 - WR703N不拆机TTL强刷openwrt工具包
- RFC中文文档
- avaya TSAPI编程文档
- SAP业务蓝图:理解供应链管理:第2版
- sap b1开发文档
- openwind64bit
- DXperienceUniversal 9.3.3 part132010年2月1日版
- RFCTCP/IP网络协议文档
- SAP PS标准培训教材,内容详细
- 深入理解计算机系统 (第三版) 英文
- openwind风力机排布自动优化软件
- SAP Connector 3.0 x64
评论
共有 条评论