oFunc.Imports("I_PROGRAMA"
oFunc.Imports("I_PROGRAMA"
Main Topics
Browse All TopicsDear Friends
I need help to translate the VB code into VFP code
My problem is how to add value to Exports properties in the code bellow!
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Your code in VFP seems to be rather different from VB...
VB: Set oFunction = CreateObject("SAP.Function
VFP: objBapiControl =CREATEOBJECT("SAP.Functio
VB: Set oFunction.Connection = g_oConnection ... here you are STORING existing connection
VFP: objconnection=objBapiContr
VB: Set oFunc = oFunction.Add("Z_EXEC_INTE
VFP: oFunc=objBapiControl.add("
VB: oFunc.Exports("I_PROGRAMA"
VFP: oFunc.Imports("I_PROGRAMA"
Neither oFunc.Imports("I_PROGRAMA"
This code below works since the RFC to be a atbel if the RFC is a structure the message error appear.
oFunc=objBapiControl.add("
oFunc.Exports("I_PROGRAMA"
oFunc.Exports("I_ORIGEM") = 'imp_origem'
The problem is hw do I call a RFC pass parameters to BAPI in structure?
Z_EXEC_INTERFACES like a table works, but if is a structure does not work, How do I call a RFC pass parameters?
I would say the above code works if there are just single parameters in oFunc.Exports. Tables work also but you need to fill oFunc.Tables. We have been testing structures but they are implemented just for Imports but not for Exports. If I remember well, structures used as input parameters did not work correctly for us so all RFC inputs were changed to single parameters or to tables.
I have no access to SAP function which requires input structure so I cannot test it now.
BTW, you have been asking "how to translate a VB code into VFP Visual FoxPro code objets". Where are above mentioned structures in your VB code?
I would suggest to close this question because it was answered already and ask the new question where you should attach your VB code containing input structures. It could help with conversion to VFP.
You should also ask similar question in SAP zone: http://www.experts-exchang
Business Accounts
Answer for Membership
by: ramromPosted on 2009-09-08 at 17:25:25ID: 25287348
"does not work" is pretty vague. How do you know it does not work? What is the error message?