HOW TO WRITE ABAP PROGRAMMING IN JAVA BY USING NETWEAVER
HI,
i am working with bapi(mean is calling bapis in my java programs).
please tell me the how to write abap programs in nwds
Thanqqqqqqqqq
Guru
Hi,
Refer the following links..
http://manuals.sybase.com/onlinebooks/group-iaw/iag0203e/iadgen2/@Generic__BookTextView/24685
and this blog
/people/kathirvel.balakrishnan2/blog/2005/07/26/remote-enable-your-rfchosttoip-to-return-host-ip-to-jco
Regards,
Uma
Similar Messages
-
I want to write ABAP Program in web dynpro Using se80 tra.code
hi
I want to write ABAP Program in web dynpro Using se80 tra.code and to Create URL for the same.
Please let me know the steps to do.
ThanksHi Shiva,
I understood , you want to create a Webdynpro Applicaiton and run it.
this will help you
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/cb243c45-0801-0010-eb9c-88669007f130
Regards
Abhimanyu -
Hello All,
My requirement is related to process chain 1 . I have one process chain in that i have to put abap program in middle of that chain . This program will check the status of one another process chain 2 status ( whether it was completed or it is going on). if it is completed then continue the Process chain 1 to further activity else wait to complete Process chain 2 .
Here i have to use process chain 2 as a parameter.
Kindly provide me solution .
Regards
SaurabhHi Saurabh,
You need to create ABAP program in which you check the values for required process chain in
following table
RSPCLOGCHAIN (Feilds ANALYZED_STATUS LOG_ID)
Depend on values you can trigger next process or you can wait unitil this process chain complete.you need to check status from table using ABAP.
If you are not aware about how to write ABAP program then take help from ABAP Team.
Regards,
Ganesh Bothe -
How to write a program that runs on a port like a deamon or service?
hi,
how to write a program in java that runs on a port like a deamon or service, accepts requests from client, process the request and gives responce.
for ex. tomcat runs on 8080 port as deamon or service.
is it socket programming? if yes please give me a simple program which runs on a specific port.
ex. a program running on a port talking two integers and return the total.
thanks and regards,
moses.I suggest you read
[http://java.sun.com/docs/books/tutorial/networking/sockets/clientServer.html]
For more
[http://www.google.co.uk/search?q=serversocket+tutorial] -
Really need help on how to write this program some 1 plz help me out here.
i am new to java and i confused on how to be writing this program.
i have completed the Part 1 but i am stuck on Part 2 & 3 so it would would be really great if any 1 could help me out on how to write the program.
Part I
An algorithm describes how a problem is solved in terms of the actions to be executed, and it specifies the order in which the actions should be executed. An algorithm must be detailed enough so that you can "walk" through the algorithm with test data. This means the algorithm must include all the necessary calculations.
Here is an algorithm that calculates the cost of a rectangular window. The
total cost of a window is based on two prices; the cost of the glass plus the cost of the metal frame around the glass. The glass is 50 cents per
square inch (area) and the metal frame is 75 cents per inch (perimeter).
The length and width of the window will be entered by the user. The
output of the program should be the length and width (entered by the user)
and the total cost of the window.
FORMULAS:
area = length times width perimeter = 2 times (length plus width)
Here is the corresponding algorithm:
read in the length of the window in inches
read in the width of the window in inches
compute the area
compute the cost of the glass (area times 50 cents)
compute the perimeter
compute the cost of the frame (perimeter times 75 cents)
compute the total cost of the window (cost of glass plus cost of frame)
display the length, width and total cost
The next step would be to "desk check" the algorithm. First you would need to make up the "test data". For this algorithm, the test data would involve making up a length and a width, and then calculating the cost of the window based on those values. The results are computing by hand or using a calculator. The results of your test data are always calculated before translating your algorithm into a programming language. Here is an example of the test data for the problem given:
length = 10
width = 20
area = 200, glass cost= 100.00 (area times 50 cents)
perimeter = 60, frame cost = 45.00 (perimeter times 75 cents)
total cost =145.00
Once the test data is chosen, you should "walk" through the algorithm using the test data to see if the algorithm produces the same answers that you obtained from your calculations.
If the results are the same, then you would begin translating your algorithm into a programming language. If the results are not the same, then you would attempt to find out what part of the algorithm is incorrect and correct it. It is also
necessary to re-check your hand calculations.
Each time you revise your algorithm, you should walk through it with your test data again. You keep revising your algorithm until it produces the same answers as your test data.
?Now write and submit a Java program that will calculate the cost of a rectangular window according to the algorithm explained. Be sure to prompt for input and label your output.?
Part II
Write, compile and execute a Java program that displays the following prompts:
Enter an integer.
Enter a second integer
Enter a third integer.
Enter a fourth integer.
After each prompt is displayed, your program should use the nextint method of the Scanner class to accept a number from the keyboard for the displayed
prompt. After the fourth integer has been entered, your program should calculate and display the average of the four integers and the value of the first integer entered raised to the power of the second integer entered. The average and result of raising to a power should be included in an appropriate messages
(labels).
Sample Test Data:
Set 1: 100 100 100 100
Set 2: 100 0 100 0
Be sure to write an algorithm first before attempting to write the Java code. Walk through your algorithm with test data to be sure it works as anticipated.
Part III
Repeat Part lI but only calculate the average, not the power. This time, make sure to use the same variable name, number, for each of the four numbers input. Also use the variable sum for the sum of the numbers. (Hint: To do this, you may use the statement sum = sum + number after each number is read.)
For Part 1 this is what i got
import java.util.Scanner;
public class Window
public static void main(String[] args)
double length, width, glass_cost, perimeter, frame_cost, area, total;
Scanner keyboard = new Scanner (System.in);
System.out.println("Enter the length of the window in inches");
length = keyboard.nextInt();
System.out.println("Enter the width of the window in inches");
width = keyboard.nextInt();
area = length * width;
glass_cost = area * .5;
perimeter = 2 * (length + width);
frame_cost = perimeter * .75;
total = glass_cost + frame_cost;
System.out.println("The Length of the window is " + length + "inches");
System.out.println("The Width of the window is " + length + "inches");
System.out.println("The total cost of the window is $ " + total);
Enter the length of the window in inches
5
Enter the width of the window in inches
8
The Length of the window is 5.0inches
The Width of the window is 5.0inches
The total cost of the window is $ 39.5
Press any key to continue . . .
Edited by: Adhi on Feb 24, 2008 10:33 AMAdhi wrote:
i am new to java and i confused on how to be writing this program.
i have completed the Part 1 but i am stuck on Part 2 & 3 so it would would be really great if any 1 could help me out on how to write the program.Looks like homework to me.
What have you written so far? Post it.
Part I
An algorithm describes how a problem is solved in terms of the actions to be executed, and it specifies the order in which the actions should be executed. An algorithm must be detailed enough so that you can "walk" through the algorithm with test data. This means the algorithm must include all the necessary calculations.
Here is an algorithm that calculates the cost of a rectangular window. The
total cost of a window is based on two prices; the cost of the glass plus the cost of the metal frame around the glass. The glass is 50 cents per
square inch (area) and the metal frame is 75 cents per inch (perimeter).
The length and width of the window will be entered by the user. The
output of the program should be the length and width (entered by the user)
and the total cost of the window.
FORMULAS:
area = length times width perimeter = 2 times (length plus width)
Here is the corresponding algorithm:
read in the length of the window in inches
read in the width of the window in inches
compute the area
compute the cost of the glass (area times 50 cents)
compute the perimeter
compute the cost of the frame (perimeter times 75 cents)
compute the total cost of the window (cost of glass plus cost of frame)
display the length, width and total cost
The next step would be to "desk check" the algorithm. First you would need to make up the "test data". For this algorithm, the test data would involve making up a length and a width, and then calculating the cost of the window based on those values. The results are computing by hand or using a calculator. The results of your test data are always calculated before translating your algorithm into a programming language. Here is an example of the test data for the problem given:
length = 10
width = 20
area = 200, glass cost= 100.00 (area times 50 cents)
perimeter = 60, frame cost = 45.00 (perimeter times 75 cents)
total cost =145.00
Once the test data is chosen, you should "walk" through the algorithm using the test data to see if the algorithm produces the same answers that you obtained from your calculations.
If the results are the same, then you would begin translating your algorithm into a programming language. If the results are not the same, then you would attempt to find out what part of the algorithm is incorrect and correct it. It is also
necessary to re-check your hand calculations.
Each time you revise your algorithm, you should walk through it with your test data again. You keep revising your algorithm until it produces the same answers as your test data.
“Now write and submit a Java program that will calculate the cost of a rectangular window according to the algorithm explained. Be sure to prompt for input and label your output.”
Part II
Write, compile and execute a Java program that displays the following prompts:
Enter an integer.
Enter a second integer
Enter a third integer.
Enter a fourth integer.
After each prompt is displayed, your program should use the nextint method of the Scanner class to accept a number from the keyboard for the displayed
prompt. After the fourth integer has been entered, your program should calculate and display the average of the four integers and the value of the first integer entered raised to the power of the second integer entered. The average and result of raising to a power should be included in an appropriate messages
(labels).
Sample Test Data:
Set 1: 100 100 100 100
Set 2: 100 0 100 0
Be sure to write an algorithm first before attempting to write the Java code. Walk through your algorithm with test data to be sure it works as anticipated.So this is where you actually have to do something. My guess is that you've done nothing so far.
Part III
Repeat Part lI but only calculate the average, not the power. This time, make sure to use the same variable name, number, for each of the four numbers input. Also use the variable sum for the sum of the numbers. (Hint: To do this, you may use the statement sum = sum + number after each number is read.)Man, this specification writes itself. Sit down and start coding.
One bit of advice: Nobody here takes kindly to lazy, stupid students who are just trying to con somebody into doing their homework for them. If that's you, better have your asbestos underpants on.
% -
How to write CRM Program.........
Dear Frnds,
I am familiar with ABAP but now i want to go with CRM but i have no idea about how to write simple program.
Is it with scripting and abap code for run simple program..
which are the transaction code to write program and execute. pls make me familiar with it.
Regards,CRM code is written in same way as ABAP code but tables are different as compared to R/3.
here oops concept is used in crm-pcui.
crm middleware is used to connect diff systems like crm and r/3.
so go thru the transaction crmd_order.
regards
dheeraj -
How to run native program with Java program?
Hello
I've got following problem. I'd like to write file browser which would work for Linux and
Windows. Most of this program would be independent of the system but running programs not. How to run Linux program from Java program (or applet) and how to do it in Windows?.
CheersTry this:
Runtime rt = Runtime.getRuntime();
Process proc = rt.exec("ls -l");
InputStream stream = proc.getInputStream();
InputStreamReader isr = new InputStreamReader(stream);
BufferedReader br = new BufferedReader(isr);
String line = null;
while ( (line = br.readLine()) != null) .....
"if the program you launch produces output or expects input, ensure that you process the input and output streams" (http://www.javaworld.com/javaworld/jw-12-2000/jw-1229-traps.html) -
How to write ABAP HR reports in ABAP web dynapro
Hi All,
How to write ABAP HR reports in ABAP web dynapro? We can add HR REPORT CATEGORY in ABAP HR using logical database like PNP.How to add HR REPORT CATEGORY in ABAP Webdynapro ?
Thanks.You can't use legacy concepts like logical databases directly in Web Dynpro ABAP. Even if you could do so, you shouldn't. Web Dynpro ABAP should always follow MVC - meaning that your business logic (the model) should be separated from WD as much as possible. This means calling function modules or class methods to consume the business logic and data. So in general there should be no difference between building HR reports or any other type of report in WDA - since from the WDA side you are calling other objects to consume the data.
This probably does mean that you will need to create classes to expose the HR data that you want in your WDA. -
It is possible to write abap programming lines in text element
Hi experts,
Can we write abap programming lines(loop command etc....) in text element in smart forms.
Thanks in adavnce,
Nag.
Moderator message: please search for available information/documentation.
Edited by: Thomas Zloch on May 17, 2011 11:44 AMThe lines on the DIO port respond to trhe MOMO (Must On, Must Off) protocol which is a tri state protocol. This allows each line on the DIO ports to be used individually. The lines, however, are by default static DIO which means that if you want to create a pulse train in them you must do it through a software routine where you change the states every time the set dio port momo call is executed. Another option is to use the PWM ouptut lines available on this port. You can use the lines specified as PWM outputs (check the 7344 hardware manual for this) so that in MAX you can generate a continous pulse train and then you can use NI-Motion's PWM fucntions to control the frequency and duty cycle of the train.
-
Can any one please tell me how to write labview program for data logging in electric motor bike. I am going to use CompactRIO for getting wide range of data from various sensors in bike. I need to write labview program for data logging of temperature, voltage and speed of the bike. Can any one help me?
Yes, we can.
I think the best place for you to start for this is the NI Developer Zone. I recommend beginning with these tutorials I found by searching on "data log rio". There were more than just these few that might be relevant to your project but I'll leave that for you to decide.
NI Compact RIO Setup and Services -> http://zone.ni.com/devzone/cda/tut/p/id/11394
Getting Started with CompactRIO - Logging Data to Disk -> http://zone.ni.com/devzone/cda/tut/p/id/11198
Getting Started with CompactRIO - Performing Basic Control -> http://zone.ni.com/devzone/cda/tut/p/id/11197
These will probably give you links to more topics/tutorials/examples that can help you design and implement your target system.
Jason
Wire Warrior
Behold the power of LabVIEW as my army of Roomba minions streaks across the floor! -
How To Read RTF file in JAVA? Using iText?
How To Read RTF file in JAVA? Using iText?.....
import java.io.*;
import com.lowagie.text.*;
import com.lowagie.text.rtf.*;
public class RTF3 {
public static void main(String[] args) {
// System.out.println("This example generate a RTF file name Sample.rtf");
// Create Document object
Document myDoc = new Document();
try {
// Create writer to listen document object
// and directs RTF Stream to the file Sample.rtf
RtfWriter2.getInstance(myDoc, new FileOutputStream("Sample.rtf"));
// open the document object
myDoc.open();
// Create a paragraph
Paragraph p = new Paragraph();
p.add("Helloworld in Rtf file..amazing isn't");
// Add the paragraph to document object
myDoc.add(p);
catch(Exception e) {
System.out.println(e);
//close the document
myDoc.close();
Exception in thread "main" java.lang.NoSuchMethodError: com.lowagie.text.Rectangle.width()F
at com.lowagie.text.rtf.document.RtfPageSetting.rectEquals(RtfPageSetting.java:433)
at com.lowagie.text.rtf.document.RtfPageSetting.guessFormat(RtfPageSetting.java:362)
at com.lowagie.text.rtf.document.RtfPageSetting.setPageSize(RtfPageSetting.java:341)
at com.lowagie.text.rtf.RtfWriter2.setPageSize(RtfWriter2.java:248)
at com.lowagie.text.Document.open(Unknown Source)
at view.RTF3.main(RTF3.java:23)
CAN you HELP me?import com.lowagie.text.Document;
import com.lowagie.text.rtf.parser.RtfParser;
import java.io.FileInputStream;
String inputFile = "sample.rtf";
Document document = new Document();
document.open();
RtfParser parser = new RtfParser(null);
parser.convertRtfDocument(new FileInputStream(inputFile), document); -
How to make a program for backgroung processing used servlet
how to make a program for backgroung processing used servlet
well i need the coding part written in servlet ,in which servlet is always ready for accepting a client request.
-
How to write a program to read any texts in any ABAP program?
Hi Experts,
How can I write a program to read specific coding section or any texts in any ABAP program?
For example, I want to wirte a program to count how many 'LOOP' and 'ENDLOOP' are in any other program.
Thanks!
Best regards,
HaoHi,
Follow the given below URL for the program to read another Program into an internal Table.
http://abap4.tripod.com/Upload_and_Download_ABAP_Source_Code.html
Once the Code is there in the Internal Table , you can do the necessary string search. -
How to Write C Program in Eclipse
Hi,
I write a Java Program in MyEclipse 5.0.in that i wrote System.load("");to load a dll file of C program.But i dont no How to write a C program in Eclipse 5.0 verson.Can any one Pleace Help me to Write a C program in Eclipse 5.0.RaghuChowdary_kolikineni wrote:
I have MyEclipse 5.0 version on my System.i want to write a java Program.in that i want to access the C functionality Using System.load("");so i write another program for C.So i want to write both Java and C programs are Same Eclipse version.how to write and which version is supported for that purpose.pleace spcify the steps to write the programs in that version u will toldTry asking in an Eclipse forum or in a MyEclipse forum. -
How to write print program for smartforms
Hi all
I need to develop new smartform and its print program.
But Im not experience in writing print program for smartform.
Ive gone through the simple print program sample that use only one table as input and one table for output.
But my smartforms require few tables for input and output.
How should I define the Data?
Can anyone guide me on how to write it.
Thanks & Regards
azTransaction code SMARTFORMS
Create new smartforms call ZSMART
2. Define looping process for internal table
Pages and windows
First Page -> Header Window (Cursor at First Page then click Edit -> Node -> Create)
Here, you can specify your title and page numbering
&SFSY-PAGE& (Page 1) of &SFSY-FORMPAGES(Z4.0)& (Total Page)
Main windows -> TABLE -> DATA
In the Loop section, tick Internal table and fill in
ITAB1 (table in ABAP SMARTFORM calling function) INTO ITAB2
3. Define table in smartforms
Global settings :
Form interface
Variable name Type assignment Reference type
ITAB1 TYPE Table Structure
Global definitions
Variable name Type assignment Reference type
ITAB2 TYPE Table Structure
4. To display the data in the form
Make used of the Table Painter and declare the Line Type in Tabstrips Table
e.g. HD_GEN for printing header details,
IT_GEN for printing data details.
You have to specify the Line Type in your Text elements in the Tabstrips Output options.
Tick the New Line and specify the Line Type for outputting the data.
Declare your output fields in Text elements
Tabstrips - Output Options
For different fonts use this Style : IDWTCERTSTYLE
For Quantity or Amout you can used this variable &GS_ITAB-AMOUNT(12.2)&
5. Calling SMARTFORMS from your ABAP program
REPORT ZSMARTFORM.
Calling SMARTFORMS from your ABAP program.
Collecting all the table data in your program, and pass once to SMARTFORMS
SMARTFORMS
Declare your table type in :-
Global Settings -> Form Interface
Global Definintions -> Global Data
Main Window -> Table -> DATA
Written by : SAP Hints and Tips on Configuration and ABAP/4 Programming
http://sapr3.tripod.com
TABLES: MKPF.
DATA: FM_NAME TYPE RS38L_FNAM.
DATA: BEGIN OF INT_MKPF OCCURS 0.
INCLUDE STRUCTURE MKPF.
DATA: END OF INT_MKPF.
SELECT-OPTIONS S_MBLNR FOR MKPF-MBLNR MEMORY ID 001.
SELECT * FROM MKPF WHERE MBLNR IN S_MBLNR.
MOVE-CORRESPONDING MKPF TO INT_MKPF.
APPEND INT_MKPF.
ENDSELECT.
At the end of your program.
Passing data to SMARTFORMS
call function 'SSF_FUNCTION_MODULE_NAME'
exporting
formname = 'ZSMARTFORM'
VARIANT = ' '
DIRECT_CALL = ' '
IMPORTING
FM_NAME = FM_NAME
EXCEPTIONS
NO_FORM = 1
NO_FUNCTION_MODULE = 2
OTHERS = 3.
if sy-subrc 0.
WRITE: / 'ERROR 1'.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
endif.
call function FM_NAME
EXPORTING
ARCHIVE_INDEX =
ARCHIVE_INDEX_TAB =
ARCHIVE_PARAMETERS =
CONTROL_PARAMETERS =
MAIL_APPL_OBJ =
MAIL_RECIPIENT =
MAIL_SENDER =
OUTPUT_OPTIONS =
USER_SETTINGS = 'X'
IMPORTING
DOCUMENT_OUTPUT_INFO =
JOB_OUTPUT_INFO =
JOB_OUTPUT_OPTIONS =
TABLES
GS_MKPF = INT_MKPF
EXCEPTIONS
FORMATTING_ERROR = 1
INTERNAL_ERROR = 2
SEND_ERROR = 3
USER_CANCELED = 4
OTHERS = 5.
if sy-subrc 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
Reward points...
Maybe you are looking for
-
I have successfully changed my apple ID and password, but cannot get my Mac computer to change it on iCloud. I have accessed system preferences, iCloud and sign out. But now I do not know how to sign in using my new id and password. I would like i
-
Running Reports 10g on Apps Server
We have a Windows 2003 apps server running Oracle Forms and Reports 10g. We are having a problem running reports in Oracle 10g, and believe it to be something to do with the configuration files. Currently, we can run the test report through Enterpris
-
Proxy to webservice error while posting
Dear Experts, I have a asynchronous Proxy to Webservice scenario. I am getting an error in receiver communication channel. 1> ......Message processing started 2> .......request entering 3>........call completed 4> .......error in response 5> ......
-
How does work Azure web sites with custom domain?
I am new in Azure. I am going to create a website or cloud service in Azure. Then I would like client to access them from custom domain, such as myweb.mydomain.com actually will map to real site/service in Azure. In this case, will client see the rea
-
IPhone randomly stops playing sound out of iPod docks?
I recently plugged my iPhone 4 iOS6.0.1 (the new update recently put out by apple) and it has stopped playing sound out of any iPod dock I plug it into. It plays sound normally out of the speakers and charges while on the dock. Has anyone had any pro