on 07-06-2009 2:23 PM
Hello Sir,
I have used SAPRFC with single IMPORT and EXPORT parameter.
Could anybody give me an example in I can use IMPORT/EXPORT as structure and TABLE parameter as input?
of course from/to PHP.
Regards,
RH
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Check this...
[SBWP and PHP|https://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/3659] [original link is broken];
On SBWP.php look for function Send_New_Message
function Send_New_Message($User,$RFC_Me,$Title,$Recievers,$Content)
{
$this->fce = saprfc_function_discover($RFC_Me, "ZSO_OBJECT_SEND");
IF (! $this->fce )
{
ECHO "The function module ZSO_OBJECT_SEND had failed.";
EXIT;
}
$User = STRTOUPPER($User);
$Lines = split("\n",$Content);
$Num_Lines = sizeof($Lines);
for($i=0;$i<$Num_Lines;$i++)
{
$Contents .= $Lines[$i] . "/";
}
$Recievers = str_replace(";","/",$Recievers);
saprfc_import ($this->fce,"OWNER",$User);
saprfc_import ($this->fce,"TITLE",$Title);
saprfc_import ($this->fce,"CONTENT",$Content);
saprfc_import ($this->fce,"RECIEVERS",$Recievers);
$rfc_rc = "";
$rfc_rc = saprfc_call_and_receive ($this->fce);
if ($rfc_rc != SAPRFC_OK)
{
if ($rfc == SAPRFC_EXCEPTION )
echo ("Exception raised: ".saprfc_exception($this->fce));
else
echo ("Call error: ".saprfc_error($this->fce));
exit;
}
}
}
Greetings,
Blag.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.