General information
Category:
Coding, syntax & commands
Title:
Execute a function to SAP/R3 in it from VFP
I need to know how can I connect to SAP/R3, an then how excecute a function in it from Visual FoxPro.
* Code
1.- Connection with Sap ( Achieved )
&& FUNCTION OF THE OBJECT
FuncControl=CREATEOBJECT("SAP.FUNCTIONS")
FuncControl.LogFileName="c:\tmp\Table+viewlog.txt"
FuncControl.LogLevel=8
&& CREATION OF THE CONNECTION OBJECT
conexion=FuncControl.Connection
&& PARAMETER OF CONNECTION
conexion.Client="025"
conexion.Language="E"
conexion.TraceLevel=6
conexion.System="CUB"
conexion.ApplicationServer="" && IP APLICATION SERVER
conexion.SystemNumber="00"
conexion.User="" && USER
conexion.Password="" && PASSWORD
IF conexion.Logon()=.T.
&& You Connects SAP
resultado=FuncControl.Z_NOMINA_ETECSA(Exeption,fec_doc:="30122003",;
fec_con:="30122003",soc:="ETCS",peri:="12",moneda:="CUP",;
Group:="LUIS",nom_file:="LUIS.TXT",path:="C:\")
ENDIF
&& THE CALL TO THE FUNCTION Z_NOMINA_ETECSA, ( WORKS WELL STA ) IN VB
&& BUT IN VFP NOT
? AS MAKING THIS CALL IN VISUAL FOXPRO ?
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only