未解析的外部 SAP NetWeaver RFC SDK 7.1 客户端示例 Visual Studio 2010

unresolved externals SAP NetWeaver RFC SDK 7.1 client example Visual Studio 2010

提问人:Attila Horváth 提问时间:3/21/2013 最后编辑:Sandra RossiAttila Horváth 更新时间:6/24/2023 访问量:995

问:

我正在尝试在 Visual Studio 2010 项目中编译 companyClient.c,但即使我正确地链接到库,我仍然会得到几个未解析的外部问题:sapnwrfc.lib

Error  1   error LNK2019: unresolved external symbol _RfcCloseConnection@8 referenced in function _errorHandling   C:\Users\Attila\Desktop\SAP_NWR_RFC\SAP_NWR_RFC\companyClient.obj   SAP_NWR_RFC
Error  2   error LNK2019: unresolved external symbol _RfcSAPUCToUTF8@24 referenced in function _nlsui_main C:\Users\Attila\Desktop\SAP_NWR_RFC\SAP_NWR_RFC\companyClient.obj   SAP_NWR_RFC
Error  3   error LNK2019: unresolved external symbol _RfcDestroyFunction@8 referenced in function _nlsui_main  C:\Users\Attila\Desktop\SAP_NWR_RFC\SAP_NWR_RFC\companyClient.obj   SAP_NWR_RFC
Error  4   error LNK2019: unresolved external symbol _RfcGetString@24 referenced in function _nlsui_main   C:\Users\Attila\Desktop\SAP_NWR_RFC\SAP_NWR_RFC\companyClient.obj   SAP_NWR_RFC
Error  5   error LNK2019: unresolved external symbol _RfcGetStructure@16 referenced in function _nlsui_main    C:\Users\Attila\Desktop\SAP_NWR_RFC\SAP_NWR_RFC\companyClient.obj   SAP_NWR_RFC
Error  6   error LNK2019: unresolved external symbol _RfcInvoke@12 referenced in function _nlsui_main  C:\Users\Attila\Desktop\SAP_NWR_RFC\SAP_NWR_RFC\companyClient.obj   SAP_NWR_RFC
Error  7   error LNK2019: unresolved external symbol _RfcSetChars@20 referenced in function _nlsui_main    C:\Users\Attila\Desktop\SAP_NWR_RFC\SAP_NWR_RFC\companyClient.obj   SAP_NWR_RFC
Error  8   error LNK2019: unresolved external symbol _RfcCreateFunction@8 referenced in function _nlsui_main   C:\Users\Attila\Desktop\SAP_NWR_RFC\SAP_NWR_RFC\companyClient.obj   SAP_NWR_RFC
Error  9   error LNK2019: unresolved external symbol _RfcGetFunctionDesc@12 referenced in function _nlsui_main C:\Users\Attila\Desktop\SAP_NWR_RFC\SAP_NWR_RFC\companyClient.obj   SAP_NWR_RFC
Error  10  error LNK2019: unresolved external symbol _RfcOpenConnection@12 referenced in function _nlsui_main  C:\Users\Attila\Desktop\SAP_NWR_RFC\SAP_NWR_RFC\companyClient.obj   SAP_NWR_RFC
Error  11  error LNK1120: 10 unresolved externals      C:\Users\Attila\Desktop\SAP_NWR_RFC\Debug\SAP_NWR_RFC.exe   SAP_NWR_RFC

你能告诉我我在这里是否遗漏了什么吗?

我按照pdf文档中的指南进行了操作,并且还阅读了以下内容: (http://help.sap.com/saphelp_nwpi71/helpdata/en/22/0430ba488911d189490000e829fbbd/frameset.htm) / NetWeaver RFC SDK/使用 NW RFC API 编程/使用 NW RFC SDK 文件

我将不胜感激任何形式的帮助。

visual-studio-2010 visual-c ++ 未解析的外部 saprfc netweaver

评论

1赞 Jared 3/22/2013
我有一个建议的SAP堆栈交换,用于解决这样的问题。试图让它进入 BETA 阶段。看看 area51.stackexchange.com/proposals/41621/...

答:

3赞 Brad 4/11/2013 #1

我有同样的问题。确保您编译的是操作系统,而不是芯片。如果操作系统是 32 位,请使用此处找到的 32 位编译/链接选项,如果芯片和操作系统是 64 位,请按照 64 位条目的说明进行操作:

https://websmp230.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=1056696