Calling a C program as an RFC from SAP : VERY URGENT
Hi All,
I have got a SAP program which is trying to call a C program on the UNIX server of the SAP system. I have created the RFC destination in SM59 and have tested the connection to be working fine. inside the C program , a code has been written to create a sample file on the server. Now when i am executing the SAP program, though the file gets created, but i am getting an Exception of "SYSTEM ERROR" at the SAP side.
Can anybody help on this regard why I am getting that error?
Its very URGENT
Hi Priyanth,
I am not sure but check this out
If you are using any commands , check if that command is configured in SM69
Similar Messages
-
Importing parameters RFC from SAP
Hi,
I read that is possible call a RFC from SAP using 'call fm destination xx in background'. But, how can i get importing parameters if the fm is asynchronous?
I'll apreciated any helps! thanks,
Alexandre!
Message was edited by: Reiner Hille-Doering (marked as question)Hi Alexandre,
I guess you should use the refernce fields when you indicate them ref. you can access the parameters, These will extra memory so it is better if you include whenever they are necessary
Regards
ram -
Import RFC from SAP System to XI
Hi
It is taking more time ( 5 to 10 mins) to list the RFC from SAPsystem ,When i try to Import RFC from SAP System to XI.
Please let me know your ideas on the same
Regards
Madhan DHi,
Could you pls check the following sap notes..
SAP Notes 718320,767091 and 212011 for a better idea on difference in performance while extracting data from R/3 backend.
Regards,
Madhu -
How to get standard program ,script,smartforms all from sap
hi friends
how to get standard program ,script,smartforms all from sap.
thanks®ards
BabasishHi,
reports:
goto se38
all programs not starting with y or z will be sap std programs only
same for se71 scripts
samse for smartforms
but the use of those will be known when you see the documentation
for each programme
for std programs there will be documentation available so that you can understand
why they have developed that object
thanks & regards,
Venkatesh -
I need to call a java program and pass parameters from C#
I'm new to C# and was given a project to rewrite some of my old VB.net programs to C# to help me learn. These VB programs call quite a few .bat files that have calls to java programs in them. I'm doing okay converting my VB code, but I've been
stumped for days trying to figure out how to call java from C#.
Does anyone here know how to do this? I really should've had this figured out by now and my back is to the wall. Ugh :(
This is the line from the .bat file that I need to convert to C#.
call jvbat production_r115.Automotive m:\data\MK115mn.100 m:\data\MK115mn.101 %6
There is one parameters being passed, %6
I would be forever grateful if someone can show me how to do this!Hi Joni,
Do you mean call a bat file that it is a Java program from C#? If so, there is an article talking about it.
If that's not what you're trying to do, please be more specific about what you're trying to do.
http://www.c-sharpcorner.com/UploadFile/maheswararao/CallingJavaProgramfromCS12062005233321PM/CallingJavaProgramfromCS.aspx
Now the next issue is pass some parameters from C#.
The above article tells using Process.Start() method to call java program. Also in this class, you could specify them all in the
Arguments property:
var p = new Process();
p.StartInfo.Arguments = string.Format("{0} {1}", argument1, argument2);
For more detailed information, please refer to
C# Passing Multiple Arguments to BAT File
Note: This response contains a reference to a third party World Wide Web site. Microsoft is providing this information as a convenience to you. Microsoft does not control
these sites and has not tested any software or information found on these sites;
Therefore, Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information
found there. There are inherent dangers in the use of any software found on the Internet, and Microsoft cautions you to make sure that you completely understand the risk before retrieving any software from the Internet.
Best regards,
Kristin
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey. -
Call to Web Sevice in external system from SAP CRM
Hi,
I have to make a call to External system from SAP CRM 5.0 system. The external system will provide a sample webservice which SAP will try to initiate
Can you please tell me:
1. What settings/object needs to be maintained in SAP in order to make this call.
2. how I can make a call to this Web-Service from a BADI and pass the values to web service and also capture the returning value.
Please explain in detail
Thanks,
MikeMike,
You should honestly search the SDN site for consuming web services with ABAP. There are some good examples.
However the general procedure is easy:
1. Generate an ABAP proxy using the WSDL provided to you by the external program
2. Configure an HTTP destination for the server of the web services (needed for HTTPS calls)
3. Configure the logical port for the web service using lpconfig
4. Write the abap code to call the webservice via the proxy. Works very similar to FM call in my opinion.
To expose a webservice(bapi being called from outside) you need to do a little more work
1. Create a web services for the RFC enabled function module via SE80
2. Use wsadmin and wsconfig to make the service available
3. Publish the service out to the UDDI as needed.
Once again this code is pretty well documented in the standard help and SDN. Do a simple search on ABAP proxies and you will find what you need.
Take care,
Stephen -
Extract program to extract data from SAP into multiple worksheets of excel
Hi , I am currently facing an issue.
Extracting the data during data extraction, conversion into an excel and also into multiple worksheets withing a excel file.
What is the function which can help me. Also how do you give refernce to multiple worksheets to be created withing a excel file (which is the destination)
Any sample program extracting data from SAP tables into a excel with multiple worksheet will be of immense help
Please respond. Appreciate it.
Rgds
MadhuHi Madhu,
Here is the program for creating the excel file and creating the multiple worksheets.
*& Report ZEXCEL_UPLOAD2
REPORT ZEXCEL_UPLOAD2.
INCLUDE ole2incl.
DATA: application TYPE ole2_object,
workbook TYPE ole2_object,
sheet TYPE ole2_object,
cells TYPE ole2_object.
CONSTANTS: row_max TYPE i VALUE 256.
DATA index TYPE i.
DATA: BEGIN OF itab1 OCCURS 0, first_name(10), END OF itab1.
DATA: BEGIN OF itab2 OCCURS 0, last_name(10), END OF itab2.
DATA: BEGIN OF itab3 OCCURS 0, formula(50), END OF itab3.
*START-OF-SELECTION
START-OF-SELECTION.
APPEND: 'Peter' TO itab1, 'Ivanov' TO itab2,
'=Sheet1!A1 & " " & Sheet2!A1' TO itab3,
'John' TO itab1, 'Smith' TO itab2,
'=Sheet1!A2 & " " & Sheet2!A2' TO itab3.
CREATE OBJECT application 'excel.application'.
SET PROPERTY OF application 'visible' = 0.
CALL METHOD OF application 'Workbooks' = workbook.
CALL METHOD OF workbook 'Add'.
Create first Excel Sheet
CALL METHOD OF application 'Worksheets' = sheet
EXPORTING #1 = 1.
CALL METHOD OF sheet 'Activate'.
SET PROPERTY OF sheet 'Name' = 'Sheet1'.
LOOP AT itab1.
index = row_max * ( sy-tabix - 1 ) + 1. " 1 - column name
CALL METHOD OF sheet 'Cells' = cells EXPORTING #1 = index.
SET PROPERTY OF cells 'Value' = itab1-first_name.
ENDLOOP.
Create second Excel sheet
CALL METHOD OF application 'Worksheets' = sheet
EXPORTING #1 = 2.
SET PROPERTY OF sheet 'Name' = 'Sheet2'.
CALL METHOD OF sheet 'Activate'.
LOOP AT itab2.
index = row_max * ( sy-tabix - 1 ) + 1. " 1 - column name
CALL METHOD OF sheet 'Cells' = cells EXPORTING #1 = index.
SET PROPERTY OF cells 'Value' = itab2-last_name.
ENDLOOP.
Create third Excel sheet
CALL METHOD OF application 'Worksheets' = sheet
EXPORTING #1 = 3.
SET PROPERTY OF sheet 'Name' = 'Sheet3'.
CALL METHOD OF sheet 'Activate'.
LOOP AT itab3.
index = row_max * ( sy-tabix - 1 ) + 1. " 1 - column name
CALL METHOD OF sheet 'Cells' = cells EXPORTING #1 = index.
SET PROPERTY OF cells 'Formula' = itab3-formula.
SET PROPERTY OF cells 'Value' = itab3-formula.
ENDLOOP.
Save excel speadsheet to particular filename
CALL METHOD OF sheet 'SaveAs'
EXPORTING #1 = 'c:\temp\exceldoc1.xls' "filename
#2 = 1. "fileFormat
Closes excel window, data is lost if not saved
SET PROPERTY OF application 'visible' = 0.
**Quick guide to some of the OLE statements for OLE processing in this program as well as a few other ones.
Save Excel speadsheet to particular filename
CALL METHOD OF sheet 'SaveAs'
EXPORTING #1 = 'C:\Users\dprasad\Desktop\excel_sheet.xls' "filename
#2 = 1. "fileFormat
Save Excel document
CALL METHOD OF sheet 'SAVE'.
Quits out of Excel document
CALL METHOD OF sheet 'QUIT'.
Closes visible Excel window, data is lost if not saved
SET PROPERTY OF application 'visible' = 0. -
RFC from Sap R/3 to IBM Mainframe...
I should create an RFC from R/3 based on Unix sistem/Oracle to a Mainframe system.....
Any advise on that ?
I never created rfc like that....
thanks and regardsHi Mauro,
Below is the steps to connect to an external MS-SQL server from ABAP... similarly, you can explore connecting to a mainframe...
Regards,
Raj
Connecting to an External database from SAP
<b>Step 1</b>: Create an entry for the External database in DBCON table using Trxn: DBCA.
Table: DBCON (Description of Database Connections)
Field Name Description Value (For: E.g.:)
CON_NAME Logical name for a RAJ
database connection
DBMS Database system MSS
USER_NAME Database user <username>
PASSWORD Password for setting up the connection to the database <pwd>/<pwd>
CON_ENV Database-specific information for a database connection MSSQL_SERVER=depotserver MSSQL_DBNAME=HOF_INDORE
DB_RECO Availability type for an open database connect
<b>Step 2</b>: Now you can write code to connect to the external database
<b>Your Sample code can be something like this </b>
FUNCTION-POOL z_houston. "MESSAGE-ID ..
DATA: BEGIN OF wa,
c_locid(3),
c_locname(50),
c_locstate(5),
END OF wa.
FUNCTION z_houston_connect.
""Local interface:
EXEC SQL.
CONNECT TO 'RAJ' AS 'V'
ENDEXEC.
EXEC SQL.
SET CONNECTION 'V'
ENDEXEC.
*- Get the data from MS-SQL Server
EXEC SQL.
open C1 for
select
loc_id,
loc_name,
loc_state
from ho_loc_mast
ENDEXEC.
DO.
EXEC SQL.
FETCH NEXT C1 into :wa-c_locid, :wa-c_locname, :wa-c_locstate
ENDEXEC.
IF sy-subrc = 0.
PERFORM loop_output.
ELSE.
EXIT.
ENDIF.
ENDDO.
EXEC SQL.
CLOSE C1
ENDEXEC.
ENDFUNCTION.
*& Form LOOP_OUTPUT
Output
FORM loop_output .
WRITE: /5 wa-c_locid, 10 wa-c_locname, 65 wa-c_locstate.
CLEAR wa.
ENDFORM. " LOOP_OUTPUT -
ABAP program to output data from SAP table to an XML format file?
hello ABAP experts,
Does anyone know how to output data from SAP table to an XML format file? Would be appreciated if someone show the detailed sample codes and we will give you reward points!
Thanks!Edited by: Jose Hugo De la cruz on Aug 19, 2009 8:23 PM
-
Blank PAge when Launching WEB IC from Portal--Very Urgent
Hi,
We are using CRM 5.0 EIC scenario
We have just configured new application server (adding one more to existing servers), when we lauch EIC (interaction centre) from this new server, it shows nothing, it just displays blank page,
Need very very urgently
MAx points would be awarded
RIn CRM 5.0 does t-code CRM_IC launch the page for you correctly? if yes then I think you need to have your portal admin check this as it would seem portal related.
-
Calling one java program (with main method) from another
Hello,
How can I start another java program from one? Lets
say I want Second.java to start by calling it from
First.java. How do I do it? The two programs are given
below. Any help is appreciated.
Thanks,
Amanda
First.java
import java.io.*;
import java.lang.reflect.*;
public class First
public static void main(String[] args)
Process theProcess=null;
System.out.println("Hello World from First.java!");
String second=new String("Second.java");
//System.load(second);
//Runtime.getRuntime().load(second);
try
theProcess=Runtime.getRuntime().exec( "Second.java"
System.out.println("after exec");
catch (IOException ioe)
System.out.println(">>IOException thrown in
First.java while calling
Second.java."+ioe.getMessage());
Second.java
public class Second
public static void main(String[] args)
System.out.println("Hello World from Second.java!");
}Stop posting here. The crosspost remark was to alert others that there is a duplicate topic - all answers should be centralized in one so as to not waste people's time duplicating answers when they don't see both topics and the answers therein.
-
Call several .exe program via one RFC destination
Hi,
We use a RFC destination (one for each connected user) to communicate between SAP R/3 (4.6c) and an AS400 application via RFC server in .NET.
We need to call some .NET functions (for transactionnal purpose) and we wish not to mix functions refering to AS400 and .NET.
Is it possible to use one RFC destination to call functions in at least 2 .NET program ?
If not, is there other ways to make those communications work ?Hi
It is not possible. I don't think of any other way to resolve this.
Thanks & Regards,
Govind. -
Calling a remote program on the server from the client
Hi, I'm new to Java/Jdeveloper/Oracle I'm writing a small app in
Jdeveloper 3.2 running on Windows that connects to an Oracle
8.1.6 on a Redhat Linux. I have a few programs writen in C that
run on the server, and would like to call them from the client
machine with a few parameters. is there a way of doing that?
it's just like calling "ls -la filename" from the remote
client. BTW, I don't need to get a response from the server, I
just need to initiate the call.
Thanks for any help.
JohnJDeveloper is an IDE not a platform. what sort of app are you
writing: client server application, applet, JSP?
APC -
Calling an application written in C/C++ from SAP
Hi
I have a need to call an application written in C/C++ language in external system from RFC.Can anyone guide me how to do it.Try something like this:
CALL FUNCTION 'WS_EXECUTE'
EXPORTING
DOCUMENT = ' '
cd = 'c:\temp '
COMMANDLINE = ' '
INFORM = ' '
program = 'c:\temp\YourProgHere.exe'
STAT = ' '
WINID = ' '
OSMAC_SCRIPT = ' '
OSMAC_CREATOR = ' '
WIN16_EXT = ' '
EXEC_RC = ' '
IMPORTING
RBUFF =
EXCEPTIONS
frontend_error = 1
no_batch = 2
prog_not_found = 3
illegal_option = 4
gui_refuse_execute = 5
OTHERS = 6 -
How to trigger automatically an IDOC and RFC from SAP R/3 system?
Hi ,
lets say if we are implementing IDOC to FILE &RFC to FILE scenario ,how can we trigger on timely basis(schedules)
1)standard IDOCs and BAPIs?
2)customized Idocs and Customized Bapis?
3)Master Idocs and transactiona Idocs?I think we need to use change pointers for master Idocs and donno about Transactional Idocs.
please explain ,
thank you very much for your help.
regards,
Babusorryfor the late reply, I was busy with my work.thank you for your posts.
so all of you say just run the RSEOUT00 no matter what interface we use in XI like Master ,transactional Idocs,standard or customized BAPIs?
And I think we use RSNASTED if we have on recieving side right?
<b>then when we would use a report of format below to trigger an RFC,is this format for Asunc RFC ?</b>
REPORT Z_SEND_DATA_TO_XI.
parameters: dest like rfcdes-rfcdest default '(RFC Destination you defined in SM59)'.
<<your other variable declaration and ABAP Code here>>
call function 'ZXI_SEND_DATA'
in background task
destination dest
exporting
Name = John
City = Smith. (The values to pass to XI)
commit work.
<<Any Write statements or sy-subrc statements here>>
6) Save and Activate your ABAP program.
6) After all these steps, execute your ABAP Program to send the data to file via XI.
Maybe you are looking for
-
BB Storm2 Error 523 & Error 200 Please help
Dear Folks ! I recently ought a BB Storm2 9550 for couple of days it was working well but i got some connection problem so I was told to change the software which i did successfuly but there was still sone problem in browsing the internet. then again
-
How to correct my Account name ?
Hi, My account name has %20 between the first word and the second word of my last name. Is there a way I can remove this %20 ? I have looked in the Profiles region but don't see any way to change it. Thanks for your help, Peter
-
HEY EVERYONE...HOPE SOMEONE CAN HELP ME. WHEN I AM TYPING I HAVE TO STOP AND WAIT UNTIL MY COMPUTOR CATCHES UP WITH MY TYPING. IT HAS NEVER DONE THIS BEFORE...LIKE I WILL TYPE LETS SAY BEST BUY...I HAVE TO STOP AND WAIT FOR IT TO CATCH UP....ANY ID
-
Spotlight searching for mailing list archives
I need to make spotlight searches available for individual Mailman/Pipermail mailing lists' web archives. How can I do it? So far, the only way I've found is to make a copy of the mailing list's web archives somewhere inside a web site's hierarchy, t
-
Looking for Camcorder to interface with IMAC 10.6.8
I'm trying to choose the right camcorder. The main focus of this camcorder is to make an instructional video to be sold on the internet.(not u-tube) It will be on a tripod the whole time. Would like to use an SD card of some kind for storage.My comp