Guide on how to modify Java code for Syclo

Hi All,
I have ZS4SAPSM-3.0.0.0 jar file in Installed Agentry server's Java folder.
I want to modify some code in Java. I imported that file in Eclipse and modified it and tried to run it. It was calling some JCO client etc.
Can someone guide me to know the procedure to modify Java code?
Regards
-prit
Tags edited by: Michael Appleby

How-to Build an Agentry based mobile app from scratch connecting to an SAP back-end Part1
Pls Read this document. It was very helpful to me to built the app from scratch.
I think you will understand the idea of Java and it will help to solve you problem.
If you have more questions pls attach the examples here.

Similar Messages

  • How to convert these java codes (for a feedback) to javabean?

    Can anyone please help me to convert these java codes (for feedback) to javabean using the MVC Model-View-Controller pattern design?
    <%
    //instantiate variables
    Connection con = null;
    Statement stmt = null;
    Statement stmt2 = null;
    ResultSet rs = null;
    String queryString;
    int newInBoxMsg = 0;
    int newSentMsg = 0;
    int newSavedMsg = 0;
    int newTrashCanMsg = 0;
    String currentUserID = 1+"";
    String adminID = 1+""; //change this ID to your adminID in the db
    try
    //Load the JDBC driver
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver").newInstance();
    //Get the connection getConnection("access driver", "userID", "password")
    con = DriverManager.getConnection("jdbc:odbc:FREN_DB","","");
    stmt = con.createStatement();
    //sql statements: create, update, query
    Calendar cl = Calendar.getInstance();
    %>
    <%
    if(request.getMethod()=="POST"){
                   int y = stmt.executeUpdate("INSERT into Feedback(`whom`, `msg`, `date`)"
                   +" values ('"+currentUserID+"', '"+request.getParameter("date")+"', '"
                   request.getParameter("msg")"')");
                   int x = stmt.executeUpdate("INSERT into MailBox(`whom`, `who`, `mailheader`, `mailbody`, `date`)"
                   +" values ('"+adminID+"', '"+currentUserID+"', 'Feedback', 'We have received your feedback and we will respond to you as soon as possible', '"+request.getParameter("date")+"')");
                   out.println("Feedback Sent!");
    else {
    %>
    <form name="compose" method="POST" action="Feedback.jsp">
    <input name="date" type="hidden" value="<% out.println(cl.get(cl.DAY_OF_MONTH)+"/"+cl.get(cl.MONTH)+"/"+cl.get(cl.YEAR)); %>" maxlength="20">
    <p>Your Feedback</p>
    <p>
    <textarea name="msg" cols="50" rows="10"></textarea>
    </p>
    <p>
    <input type="submit" name="Submit" value="Submit">
    </p>
    </form>
    <%
    }catch(Exception e) {
    System.out.println(e);
    %>

    Okay, first suggestion is to never create database connections in JSP/Servlet. SInce you mentioned MVC, JSP is the View, and a servlet can be the controller to process requests and redirect accordingly.
    This piece of code should be in a class invoked from the model layer (business logic components) preferably with some abstraction. Maybe you should search around for DAO pattern. That might give you an idea.

  • How to write a code for  open new txt file in swing

    hai all,
    now i do one project in java.that project's GUI is Swing. But i don't known swing (basic).So how to write a code for open new txt file and "Open window " in menu item on swing.that means when i click the "New" on menu that time open a new txt file. open also like that type.
    plz give me that code ! very urgent
    Advance Thanks !
    RSK

    Swing Tutorial:
    http://java.sun.com/docs/books/tutorial/uiswing/index.html
    Since you don't know the basic of swing read the tutorial, it is for your own good because it is useless if we provide you with a code you don't even understand and how it works.
    If you want a menu read the tutorial about using menus and for opening a file read using JFileChooser.
    note: don't use the word urgent because it implies that your problem is more important than others.

  • Creating Java code for the function module

    Hi Colleagues,
    I have a fuction module in ABAP system. Now I want to Generate java code for the FM.
    I cam to know that we can achive that using AXIS, By getting the XML file for the fuction module and generate Java
    Class file using that XML file.
    Can any one tell me how to achive it.
    Or any other way to do that?
    Please provide you valid suggestions.
    Regards,
    Sathya

    Hi,
    You can integrate axis2 in eclipse. I think you have to find the plugin for that.
    After that you can let axis generate the jave code (stubs and proxies) for your web service via the wsdl file.
    Kind Regards,
    Robin

  • java code for intrusion detection system

    hi
    how can i write a java code for intrusion detection system wireless network (steps)
    help please whith any documentation , exemples , name of packages thank you

    hi
    anyone have code source java projet of an IDS intrusion detection system for VANET and thank you

  • Weblogic 6.0 (SP2) generates incorrect java code for JSP with response.sendRedirect()

              Hi,
              Here are the steps to reproduce the problem with the examplesWebApp application
              bundled with wlserver6.0(sp2):
              Product: Weblogic server 6.0 (sp2)
              Browser: IE 5.0
              1. Add index.jsp as the welcome file in WEB-INF/web.xml
              2. Create index.jsp as below:
              <%
              response.sendRedirect("index.html");
              return;
              %>
              <html>
              <head>
              <title>Index JSP file</title>
              </head>
              <body>
              <font color="red">This is index.jsp file </font>
              </body>
              </html>
              3. Create index.html as below:
              <html>
              <head>
              <title>Index HTML file</title>
              </head>
              <body>
              <font color="red">This is index.html file </font>
              </body>
              </html>
              4. Run the examples server and make sure examplesWebApp is deployed on the examples
              server using the console
              5. Access the URL http://localhost:7001/examplesWebApp
              The page will display a compilation error as below:
              C:\bea\wlserver6.0\config\examples\applications\examplesWebApp\WEB-INF\_tmp_war_examplesServer_examplesServer_examplesWebApp\jsp_servlet\_index.java:89:
              unreachable statement
              out.print("\r\n<html>\r\n<head>\r\n<title>Simple html</title>\r\n</head>\r\n<body>\r\n<font
              color=\"red\">This is index.jsp page</font>\r\n</body>\r\n</html>\r\n");
              ^
              and a look at the generated java code for index.jsp (_index.java) will reveal
              the erroneous code snippet below in the jsp service method:
              try { // error page try block
              //[ /index.jsp; Line: 1]
              response.sendRedirect("index.html"); //[ /index.jsp; Line: 2]
              return; //[ /index.jsp; Line: 3]
              out.print("\r\n<html>\r\n<head>\r\n<title>Simple html</title>\r\n</head>\r\n<body>\r\n<font
              color=\"red\">This is index.jsp page</font>\r\n</body>\r\n</html>\r\n");
              } catch (Exception __ee) {
              while (out != null && out != _originalOut) out = pageContext.popBody();
              pageContext.handlePageException(__ee);
              The above web application works fine in Tomcat 3.2.X environment. The Weblogic
              server 6.0 servlet engine should not generate the "out.println()" corresponding
              to the html section of index.jsp. The moment it sees the "return", it should stop
              processing further.
              Can someone from Weblogic support team please verify this and let me know when
              this bug will be fixed?
              One interesting thing I noticed was when we last tried weblogic 6.0 at its beta
              stage, it worked fine after we put in a special patch jar file called "redirectfix.jar"
              we received from weblogic team but somehow it got re-introduced by the time it
              was released!!
              We are planning to migrate our product from tomcat 3.2.x to weblogic 6.0. Our
              product has a lot of pages with such conditional {response.sendRdirect("page.jsp");return;}
              blocks. We would really appreciate a faster response form weblogic team.
              Thanks in advance.
              sam...
              Sam Palanisamy
              Senior Software Engineer
              Manage.com
              2345 N. First Street First Floor
              San Jose CA 95131
              

    Why should it stop when it sees a return? Is that in the spec?
              Peace,
              Cameron Purdy
              Tangosol Inc.
              << Tangosol Server: How Weblogic applications are customized >>
              << Download now from http://www.tangosol.com/download.jsp >>
              "Sam Palanisamy" <[email protected]> wrote in message
              news:[email protected]...
              >
              > Hi,
              >
              > Here are the steps to reproduce the problem with the examplesWebApp
              application
              > bundled with wlserver6.0(sp2):
              >
              > Product: Weblogic server 6.0 (sp2)
              > Browser: IE 5.0
              >
              > 1. Add index.jsp as the welcome file in WEB-INF/web.xml
              >
              > 2. Create index.jsp as below:
              > <%
              > response.sendRedirect("index.html");
              > return;
              > %>
              > <html>
              > <head>
              > <title>Index JSP file</title>
              > </head>
              > <body>
              > <font color="red">This is index.jsp file </font>
              > </body>
              > </html>
              >
              > 3. Create index.html as below:
              > <html>
              > <head>
              > <title>Index HTML file</title>
              > </head>
              > <body>
              > <font color="red">This is index.html file </font>
              > </body>
              > </html>
              >
              > 4. Run the examples server and make sure examplesWebApp is deployed on the
              examples
              > server using the console
              >
              > 5. Access the URL http://localhost:7001/examplesWebApp
              >
              > The page will display a compilation error as below:
              >
              C:\bea\wlserver6.0\config\examples\applications\examplesWebApp\WEB-INF\_tmp_
              war_examplesServer_examplesServer_examplesWebApp\jsp_servlet\_index.java:89:
              > unreachable statement
              > out.print("\r\n<html>\r\n<head>\r\n<title>Simple
              html</title>\r\n</head>\r\n<body>\r\n<font
              > color=\"red\">This is index.jsp page</font>\r\n</body>\r\n</html>\r\n");
              > ^
              >
              > and a look at the generated java code for index.jsp (_index.java) will
              reveal
              > the erroneous code snippet below in the jsp service method:
              >
              > try { // error page try block
              >
              > //[ /index.jsp; Line: 1]
              > response.sendRedirect("index.html"); //[ /index.jsp; Line: 2]
              > return; //[ /index.jsp; Line: 3]
              > out.print("\r\n<html>\r\n<head>\r\n<title>Simple
              html</title>\r\n</head>\r\n<body>\r\n<font
              > color=\"red\">This is index.jsp page</font>\r\n</body>\r\n</html>\r\n");
              > } catch (Exception __ee) {
              > while (out != null && out != _originalOut) out =
              pageContext.popBody();
              > pageContext.handlePageException(__ee);
              > }
              >
              > The above web application works fine in Tomcat 3.2.X environment. The
              Weblogic
              > server 6.0 servlet engine should not generate the "out.println()"
              corresponding
              > to the html section of index.jsp. The moment it sees the "return", it
              should stop
              > processing further.
              >
              > Can someone from Weblogic support team please verify this and let me know
              when
              > this bug will be fixed?
              >
              > One interesting thing I noticed was when we last tried weblogic 6.0 at its
              beta
              > stage, it worked fine after we put in a special patch jar file called
              "redirectfix.jar"
              > we received from weblogic team but somehow it got re-introduced by the
              time it
              > was released!!
              >
              > We are planning to migrate our product from tomcat 3.2.x to weblogic 6.0.
              Our
              > product has a lot of pages with such conditional
              {response.sendRdirect("page.jsp");return;}
              > blocks. We would really appreciate a faster response form weblogic team.
              >
              > Thanks in advance.
              > sam...
              > Sam Palanisamy
              > Senior Software Engineer
              > Manage.com
              > 2345 N. First Street First Floor
              > San Jose CA 95131
              >
              >
              

  • Can someone please tell me on how to modify this code so that I dont have to enter the file name at all?

    Hello
    can someone please tell me how to modify this code so that I dont have to enter the file path at all? When i give the same file path constants to both the read and write VIs I'm getting an error message.
    Attachments:
    read and write.vi ‏11 KB

    Yup use the low level File I/O opening the reference once, and closing it once.  
    As for the path selection you have an unwired input which is the path to use.  Programatically set that and you won't be prompted to select a path.  Usually this is done with a path constant to a folder, then using the Build Path, to set the file name in that folder.
    Unofficial Forum Rules and Guidelines - Hooovahh - LabVIEW Overlord
    If 10 out of 10 experts in any field say something is bad, you should probably take their opinion seriously.

  • How to give t-code for Query in SQVI

    Hi
    how to assign t-code for the query written in SQVI
    Regards
    Smitha

    Hi Smitha
    1>go to SQVI t code and  enter your query name and press enter
    2>In the menu path select Quick view--> additional functions-->Generate Program
    3>After Generating the program In the menu path select Quick view--> additional functions-->Display report Name
    4>Now in se38 enter the report name in Program field and execute
    5>You will get the Initial Selection screen of the report . Go to Menu of System -->Status
    6> Note down the Program name and Screen number
    7>Go to SE93 and Create a Z tcode for the query, Enter the description  and importantly you have to select the 2nd Option radio Button Program and Selection Screen (Report Transaction) and Press enter
    8>In the next screen enter the Report name In Program field and enter the screen number
    9>In the classification Section select Professional user  Transaction
    10>In GUI support section select all the options  i.e SAPGUI for HTML,Java,Windows
    and save
    the system will ask for Package select your package if not there then select local object
    now execute the Z tcode your report will run sucessfully
    Regards
    Vijay hebbal

  • How to modify source code on website

    I would like to view and modify source code for my website on the iphone. I have an app that allows me to FTP the files to my server. But, I don't know how to view code in Safari and be able to modify it. Can you tell me how to do that?
    Thanks!

    See also:
    *Firefox > (Web) Developer > Page Source
    *Tools > Web Developer > Page Source (Ctrl+U)
    *right-click on a web page and select View Page Source in the context menu

  • How to find function code for buttons on toolbar in oops alv

    Hi experts,
    I want to remove some buttons from toolbar in oops alv, i know the procedure like get function code and pass the value in a table and pass that table to IT_TOOLBAR_EXCLUDING of
    method set_table_for_first_display but I WANT TO KNOW HOW TO FIND FUNCTION CODE FOR BUTTONS ON TOOLBAR IN OOPS ALV

    Hi Prakash,
    -->First you have to set the pf status in your alv program by,
    {FORM pf_status USING rt_extab TYPE slis_t_extab.
      SET PF-STATUS 'FIRST'.
    ENDFORM.                    "PF_STATUS}
    -->Pass this Subroutine name in the Function module, Reuse_alv_grid_display's parameters i.e,
          i_callback_pf_status_set          = 'PF_STATUS'}
    *-->Then doble click on that pf status,
    From the menu bar, select Extras->Adjust Template->List Viewer,
    This will give you the existing statndard gui status of the program*
    ->Then catch that function codes in the User command Parameter of the Function module Reuse.. i.e,
          i_callback_user_command           = 'COMM'
    And make a subroutine of the name 'COMM'i.e,
    FORM comm USING ucomm LIKE sy-ucomm selfield TYPE slis_selfield.
      DATA: okcode TYPE sy-ucomm.
      okcode = ucomm.
      CASE okcode.
        WHEN 'REF'.
        CALL FUNCTION 'POPUP_TO_INFORM'
          EXPORTING
            titel         = 'MANSI'
            txt1          = 'CREATED BY'
            txt2          = SY-UNAME
          TXT3          = ' '
          TXT4          = ' '
    endcase.
    Hope it helps you
    Regrds
    Mansi

  • How to print claim code for envy 5530 without connecting to internet?

    how to print claim code for hp envy 5530 without connecting to internet. We do not have wireless internet and we are trying to set up the eprint app for our samsun android phones and ipad. We need to print off the claim code from the printer but it seems we need to have internet for that. is there any way around that?
    Thanks

    Hi,
    You have to, without connecting to the internet, the claim code (if you can get one) is useless.
    Regards.
    BH
    **Click the KUDOS thumb up on the left to say 'Thanks'**
    Make it easier for other people to find solutions by marking a Reply 'Accept as Solution' if it solves your problem.

  • How to create transaction code for a Z-table

    How to create transaction code for a Z-table?
    Se93 --> then which radio button to be selected? and what is the program nam e to  be given

    Hi Sam,
    <b>Procedure to create a TCODE for ZTABLE:</b>
    Create a table maintainance/View for the Z* Table.
    Once you create the view goto SE93>Select Parameter transaction and give the short desc.>
    Give the transaction as SM30(Skip the first screen-optional)>Check all check boxes under GUI support>In the default values(grid)section first row give the VIEWNAME as you created initially and the second row UPDATE as X.
    <u><i>Se93 --> then which radio button to be selected</i></u>
    Select the parameter transaction as a radio button.
    <u><i>what is the program nam e to be given</i></u>
    no need to give any program name. Instead you have to give the transaction code name as SM30.
    Pls mark the helpful answers.
    Thanks
    Eswar

  • How to create transaction code for maintenance view

    hai friends,
    i hope every thing goes good.
    i have doubt, how to create transaction code for maintenance view. I created view for tranperant table and now i want to create transaction code for the view.
    i tried and i donot know the screen number and program name and where can i give the view name.
    if any one know please post in details.
    thanks in advance.

    Hi Elam,
    You need to create a "Parameter Transaction".
    What this means is that you will have a transaction (let's call it "ZMAINT") which calls "SM30" and passes in your table name.
    Go to transaction SE93 and enter your new transaction code. Enter in the Tcode description and choose "Transaction with Parameters" (it shouldbe the last radio button).
    Enter in the default transaction "SM30" and tick the "Skip Initial Screen" check box. Hit Enter.
    Now scroll to the bottom of the screen and you will see a Table Control where you will need to enter in the values to the SM30 selection screen.
    Because you hit ENTER, the program will have loaded in the Selection Screen parameters into it's memory. Hit the drop down for "Name of Screen Field" and select "VIEWNAME" and then enter in your Z Table in the "Value" column.
    Now go to the next line and hit the drop down and select "UPDATE" in the "Name of Screen Field". Enter in a "X" in the value column.
    Now save the transaction and there you have it.
    Hope this helps.
    Cheers,
    Pat.
    PS. Kindly assign Reward Points to the posts you find helpful.

  • How can install java sdk for mac os x 10.6.8

    How can install java sdk for mac os x 10.6.8?

    Deanwdd wrote:
    I mean to update Quicktime for Mac Os X 10.6.8...
    If you're running 10.6.8, Apple menu > Software Update. What version of QT do you have?

  • I Need Java code for following Algorithm

    * I Need Java code for following algorithm. Kindly any one help.
    1. Read the contents (ideas and its corresponding scores) from two files named as 'a' and 'b'.
    2. Stored the file 'a' contents in array a[].
    3. Stored the file 'b' contents in array b[].
    4. compare both files like
    if(a.equals(b[j])
    Writing the common idea and add the score from file 'a' and 'b'.
    else
    write the uncommon idea and its score..
    For example :
    Form Agents.txt
    action,65
    architecture,85
    eco-,15
    essay,30
    form,85
    form,85
    link,40
    tangent,25
    Form Agents1.txt
    Black holes,69
    essay,78
    Herewith i have above mentioned two files named as Form Agents and Form Agents1.
    Form Agents has eight fields
    Form Agents1 has two fields
    --> 'essay' is common in two files, so store the idea 'essay' and add the score from Form Agents score is '30' and Form Agents1 has 78 (essay 108).
    Finally it stores idea in another file with uncommon fields also.
    Please help us.

    We have tried with following code.
    But we cant add the scores.
    For Example:
    Form Agents.txt --> has "essay,30"
    Form Agents1.txt --> has "essay,78"
    Result is: essay,108
    Finally it stores idea in another file with uncommon fields also.
    So Any one pls correct the following code.
    try
    DataOutputStream o1=new DataOutputStream(new
    FileOutputStream("C:\\Interfaces\\interfaces\\temp\\BlackBoard\\My Design
    World\\Project\\Material\\art\\System Agents\\Form Agents\\CandidateResponses\\Form
    Agents.txt"));
    //Reading the contents of the files
    BufferedReader br= new BufferedReader(new InputStreamReader(new
    FileInputStream("C:\\Interfaces\\interfaces\\temp\\BlackBoard\\My Design
    World\\Project\\Material\\art\\System Agents\\Form Agents\\Ideological\\Form
    Agents.txt")));
    BufferedReader br1= new BufferedReader(new InputStreamReader(new
    FileInputStream("C:\\Interfaces\\interfaces\\temp\\BlackBoard\\My Design
    World\\Project\\Material\\art\\System Agents\\Form Agents\\Related\\Form
    Agents.txt")));
    while((s=br.readLine())!=null)
    s1+=s+"\n";
    while((s2=br1.readLine())!=null)
    s3+=s2+"\n";
    int numTokens = 0;
    StringTokenizer st = new StringTokenizer(s1);
    String[] a = new String[10000];
    String[] br_n=new String[10000];
    int i=0;
    while (st.hasMoreTokens())
    s2 = st.nextToken();
    a=s2.substring(0,s2.length()-3);
    s6=s2.substring(s2.length()-2);
    br_n[i]=s6;
    i++;
    numTokens++;
    int numTokens1 = 0;
    StringTokenizer st1 = new StringTokenizer (s3);
    String[] b = new String[10000];
    String[] br1_n=new String[1000];
    int j=0;
    while (st1.hasMoreTokens())
    s4 = st1.nextToken();
    b[j]=s4.substring(0,s4.length()-3);
    s7=s4.substring(s4.length()-2);
    br1_n[j]=s7;
    j++;
    numTokens1++;
    int x=0;
    for(int m=0;m<a.length;m++)
    for(int n=0;n<b.length;n++)
    if(a[m].equalsIgnoreCase(b[n])){
    int sc=Integer.parseInt(br_n[m]);
         int sc1=Integer.parseInt(br1_n[n]);
    int score=sc+sc1;
         o.writeBytes(a[m]+","+score+"\n");
    break;
    else
    o.writeBytes(a[m]+","+br_n[m]+"\n");
    break;
    }catch(Exception e){}

Maybe you are looking for

  • File Deletion from PL/SQL using Java

    I'm able to delete a file on the OS from PL/SQL by calling a java class. But there is a problem if I am trying to delete any file located on any machine othere than the one on which the Database is hosted. Can anyone tell me how delete a file which i

  • How to create web service for database application

    Hi everyone Is it possible to create a web service for an apex database application page which has reports and radio fields and dialog boxes and validations in it. IF it is possible to create, pls help me with example or step by step procedure. I hav

  • Regarding sd module modification in va01/va02/va03

    as per we can configure the screen of <u><b>mm01,mm02,mm03</b></u> in spro by modifying the datascreen and assining the data screen to <b><u>mm01/mm02/mm03</u></b>.teis requirement i executed. but now i need to modify th screen of <u><b>va01/va02/va0

  • Add alarm in LMS 4.0

    Hi, I would like add an alarm to LMS when a power supply of some device goes down. For instance, when the power supply fails LMS send an email or something like that. How can do it? Thanks in advance

  • Latest version of Firefox (4.0) no longer displays images on over-blog sites; previous version worked fine.

    <blockquote>Locking duplicate thread.<br> Please continue here: [/questions/812641]</blockquote><br> Prior to the update, the images displayed fine. They also display on IE.