Calling CRMOD ContactDetail page? is it possible? using JAVA JSP?

Hi to all,
I am new to CRMOD itegration. Just want to know if it is possible to call the ContactDetail page of CRMOD automatically. So far I am able
to query data using WSDL, anybody have a sample code on how to call ContactDetail Page.
public static void main(String[] args) {
String jsessionid, jsessionid_full;
String endpoint;
try {
CRMOD crmod = new CRMOD();
System.out.println("Loggin In");
jsessionid_full =
crmod.logon("https://secure-vmsomxlta.crmondemand.com/Services/Integration", "xxxxxxxx-zz","jeraiya");
jsessionid = getSessionId(jsessionid_full);
System.out.println(jsessionid);
endpoint = "https://secure-vmsomxlta.crmondemand.com/Services/Integration" + ";jsessionid=" + jsessionid;
URL urlAddr = new java.net.URL( endpoint);
crmondemand.ws.contact.Contact service = new crmondemand.ws.contact.ContactLocator();
crmondemand.ws.contact.Default_Binding_Contact stub = service.getDefault(urlAddr);
crmondemand.ws.contact.ContactWS_ContactQueryPage_Input contactlist = new
crmondemand.ws.contact.ContactWS_ContactQueryPage_Input();
crmondemand.ws.contact.ContactWS_ContactQueryPage_Output outlist = new
crmondemand.ws.contact.ContactWS_ContactQueryPage_Output();
crmondemand.xml.contact.Contact[] contacts = new crmondemand.xml.contact.Contact[1];
crmondemand.xml.contact.Contact contact = new crmondemand.xml.contact.Contact();
crmondemand.xml.contact.Activity[] activities = new crmondemand.xml.contact.Activity[1];
crmondemand.xml.contact.Activity activity = new crmondemand.xml.contact.Activity();
activity.setSubject("");
activity.setType("");
activity.setRowStatusOld("");
activities[0] = activity;
contact.setContactLastName("='Bucio'");
contact.setContactFirstName("");
contact.setContactId("");
contact.setListOfActivity(activities);
contacts[0] = contact;
contactlist.setPageSize("10");
contactlist.setUseChildAnd("false");
contactlist.setStartRowNum("0");
contactlist.setListOfContact(contacts);
outlist = stub.contactQueryPage(contactlist);
crmondemand.xml.contact.Contact[] results = new crmondemand.xml.contact.Contact[1];
results = outlist.getListOfContact();
crmondemand.xml.contact.Activity[] activitiesout = new crmondemand.xml.contact.Activity[1];
int lenC = results.length;
if (lenC > 0) {
for (int i = 0; i < lenC; i++) {
System.out.println(results.getContactFirstName());
System.out.println(results[i].getContactLastName());
System.out.println(results[i].getContactId());
int lenA = results[i].getListOfActivity().length;
if (lenA > 0) {
for (int j = 0; j < lenA; j++) {
activitiesout = results[i].getListOfActivity();
System.out.println(" " + activitiesout[j].getSubject() + ", " + activitiesout[j].getType());
crmod.logoff("https://secure-vmsomxlta.crmondemand.com/Services/Integration", jsessionid_full);
System.out.println("Loggin Out");
} catch (Exception e) {
System.out.println(e);
Please if it is possible please post a sample.tnx

How about adding a use case? You may find an alternative approach.

Similar Messages

  • N:1 Mapping Possible using Java Mapping?

    All,
    Is it possible to do a N:1 mapping using Java Mapping?
    If yes , how?
    Reason for this question is that the execute() of the Java Mapping is going to take the source / request message as the InputStream . In the case of N:1 mapping , as we have multiple messages , how will they be send to the InputStream? Will both the messages be sent combined into the InputStream? Will the MESSAGES tag be embedded into the input stream?
    Regards,
    Bhavesh

    Hi @ll;
    i try the same.
    to conduct a java mapping with 2 input structures that fills one target structure.
    This mapping is part of a Integrationprocess.
    I tested the mapping at the Integration Repository (Interface mapping) with the structure given by henrique and it works fine without any error.
    At runtime this structure looks like this (different prefix)
    <?xml version="1.0" encoding="UTF-8"?>
    <sxi:Messages xmlns:sxi="http://sap.com/xi/XI/SplitAndMerge">
         <sxi:Message1>
              <YOURXML1>...</YOURXML1>
         </sxi:Message1>
         <sxi:Message2>
              <YOURXML2>...</YOURXML2>
         </sxi:Message2>
    </sxi:Messages>
    As I put it in the Integrationprocess unfortunately a strange error arises.
    The trace Workflow-Protocoll shows following error.
    <Trace level="2" type="T">Call method execute of the application Java mapping com.endress.infoserve.xi.mapping.MergeConfigStore_IdocOrder </Trace>
    <Trace level="2" type="T">Java mapping com/endress/infoserve/xi/mapping/MergeConfigStore_IdocOrder completed. (executeStep() of com.endress.infoserve.xi.mapping.MergeConfigStore_IdocOrder </Trace>
    <Trace level="1" type="T">Parsing error after multi mapping.Expected Message<i> instead of IDOC </Trace>
    I can't make head nor tail of it.
    what´s the mistake?
    can anybody please help me?
    Thanks in advance
    Kind regards

  • Calling Operating System Commands from PL/SQL using java

    Calling Operating System Commands from PL/SQL - The Java Way
    wlth help of given thread link,
    Calling OS Commands from Plsql
    but i had user privilege problem
    Declare
    x Varchar2(2000);
    Begin
    x := OSCommand_Run('/tmp/sri/GROUP_ho.sh');
    DBMS_OUTPUT.Put_Line(x);
    End;
    o/p;
    can't exec: /tmp/sri/GROUP_ho.sh lacks user privilege
    i done the grant privillage also
    part
    dbms_java.grant_permission('abcd', 'SYS:java.lang.RuntimePermission', 'writeFileDescriptor', '');
    dbms_java.grant_permission('abcd', 'SYS:java.lang.RuntimePermission', 'readFileDescriptor', '');
    dbms_java.grant_permission('
    abcd', 'SYS:java.io.FilePermission','<<ALL FILES>>', 'execute');
    again
    get
    can't exec: /tmp/sri/GROUP_ho.sh lacks user privilege
    same error;

    Process management at the OS level should prevent execution continuing in the calling code until the command has completed (either successfully or with error).
    If the low level java code were to spawn child process threads then execution could continue, but I'm guessing the Java function your talking about doesn't do that and just calls the operating system to execute the command and waits for the returning code to come back.

  • Storing pdf document as pages in oracle 9i using java

    hi
    When pdf doc is gets uploaded it needs to be saved to the db by pages
    (Ex. if a doc. has 2 pages 2 records need to be saved to db).
    Client should be able to download several documents at once or several pages of the certain document.

    And your question is?
    http://www.lowagie.com/iText/
    http://java.sun.com/docs/books/tutorial/jdbc/index.html

  • I regularly upload pages to a wensite using Java, even though Java is enabled in preferences the notification that Java is disabled when I try to connect. This is using Apple's latest Java update and Firefox 5.0

    Uploading PDFs via Java to external service. Unable to connect because Firefox reports Java disabled even though it is ticked as enabled in preferences

    Uploading PDFs via Java to external service. Unable to connect because Firefox reports Java disabled even though it is ticked as enabled in preferences

  • Is this possible with java/JSP iview?

    I am trying to dynamically create a number of gridLayoutCells/textviews.
    I am having a problem creating the strings in my JAVA code. For example: <i>hbj1 = "<hbj:";</i>.
    This returns "".
    Can you not use certain characters in strings???
    It seems like I cannot make a string with the '<' character in it.
    I have a JSP.
    The code is, for example,...
    <hbj:content id="myContext" >
      <hbj:page title="myPage">
       <hbj:form id="myFormId" method="post" action="">
         <hbj:gridLayout id="myGridLayout">
           <b><%=MyBean.getReportList() %></b>
         </hbj:gridLayout>
       </hbj:form>
      </hbj:page>
    </hbj:content>
    My JAVA code builds a string -
    hbjFull = "";
    count = 1;
    DO
    hbj1 = "<hbj:gridLayoutCell id='myGLC3x" + Integer.toString(count) + "x2' ";
    hbj2 = " horizontalAlignment='LEFT' rowIndex=" + Integer.toString(count) + " columnIndex='2'>";
    hbj3 = "<hbj:textView id='tvReportNm" + Integer.toString(count) + "' design='STANDARD' width='250' wrapping='TRUE' encode='false' text='" + itemKey + "' /></hbj:gridLayoutCell>";
    hbjFull = hbjFull + hbj1 + hbj2 + hbj3;
    count = count + 1;
    WHILE
    <b>myBean.setReportList(hbjFull);</b>
    <i>itemKey is populated from the results of a RFC to SAP BW database.</i>

    Thanks to all...
    I really should better clarify my question.
    I am not trying to dynamically create the gridlayout/textviews. Not as in "on-the-fly".
    I want to create the layout in my doInitialization java method. Just a one time thing.
    Basically, I need a textview (gridrow) for each row that I have returned in a result set.
    Therefore...shouldn't my original idea work?
    My string is being set to my bean just fine.
    So, now I need the JSP to retrieve the value from the bean.
    My JSP code basically looks like this...
    <hbj:gridLayout id="myGridLayout2" columnSize="3" cellSpacing="5">
       <%=MyBean.getReportList() %>
    </hbj:gridLayout>
    where MyBean.getReportList() should be the value from the bean.
    I did create a javascript function that pops up an alert that shows that the value in the bean is correct. This value is:
    <hbj:gridLayoutCell id="myGridLayoutCell2x4x2" horizontalAlignment="LEFT" rowIndex="5" columnIndex="2" colSpan="80">
             <hbj:textView id="tv4" design="HEADER2" width="250" wrapping="TRUE" encode="false" text="Report 1" />      
           </hbj:gridLayoutCell>
    <hbj:gridLayoutCell id="myGridLayoutCell2x5x2" horizontalAlignment="LEFT" rowIndex="5" columnIndex="2" colSpan="80">
             <hbj:textView id="tv5" design="HEADER2" width="250" wrapping="TRUE" encode="false" text="Report 2" />      
           </hbj:gridLayoutCell>
    I guess I am just not sure how to use the value from the bean.

  • Using Java/JSp on ISP machine (Any Ideas Please)

    Tomcat works fine on my ISP Host the problem however is that you usually do not have control over classpath for all the jar files.
    + Can any one please suggest alternative ways to use jar file
    + Example of what I want to solve is my isp does not have jdbc-odbc
    it comes up with this error
    java.sql.SQLException: [unixODBC][Driver Manager]Data source name not found, and no default driver specified
    Therefore I want to just insert the jar file for the bridge and use it to connect in my jsp or java bean file.
    Any ideas please
    Thanks in advance

    Here is the code used to connect
    <%@ page import="java.sql.*" %>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
         <title>Untitled</title>
    </head>
    <body>
    <%
                String username;
                String password;
                username="bbbb";
                password="cccc";
                try {
                Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
                // set this to a MS Access DB you have on your machine
                String filename = application.getRealPath("/data/loger.mdb");
                String database = "jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)};DBQ=";
                database+= filename.trim() + ";DriverID=22;READONLY=true}"; // add on to the end
                // now we can get the connection from the DriverManager
                Connection con = DriverManager.getConnection( database ,"","");
                Statement s = con.createStatement();
                int i=0;
    System.out.println(i);           
    //        s.execute("create table MyCustomers (CustomerID integer , ContactFirstName varchar(15),  ContactLastName varchar(20))"); // create a table
    System.out.println(i+=1);           
    System.out.println(i+=1);    
            String query = "SELECT * FROM Customers WHERE username='"+username+"' AND password='"+password+"'";      
            s.executeQuery(query); // select the data from the table
    System.out.println(i+=1);          
            ResultSet rs = s.getResultSet(); // get any ResultSet that came from our query
                if (rs != null) {
                    out.println("Customer Data: <br>");
                    while ( rs.next() )
                        out.println(rs.getString(3));                       
                        out.println(rs.getString(4)+"<BR>");                       
                        session.setAttribute("userId", rs.getString(1));
                        session.setAttribute("userName", rs.getString(17));
                out.println("Database connected");
            s.close(); // close the Statement to let the database know we're done with it
            con.close(); // close the Connection to let the database know we're done with it
                out.println("Database Disconnected");
                catch (Exception e) {
                    out.print(e);
    %>
    </body>
    </html>

  • Import CSV/Excel data into Flex Datagrid using Java/JSP

    Hi,
    Is there any way we can import excel/csv data into flex datagrid component.
    I see that is been done using php in this site. http://code.google.com/p/as3xls/
    Any help would be appreciated.
    Thanks in advance

    You can store the list of data from the Excel sheet that you have read already into an ArrayList
    Then go through the JDBC tutorial, and learn how to insert a single record into the table.
    After you understand how to insert a single record, you can iterate through the ArrayList of data and insert them into the table in the database.
    If you know JDBC, see if you can use OR Mapping frameworks like Hibernate or iBatis, they make it very easy to manage database in Java.

  • Conversion of Vedio file to FLV using Java/JSP/Servlets/Struts

    Hi all,
    This is N.Sridhar and I am working on file transcoding.Does any one have any idea about video conversion tools/API which can be used to programitically with JSP/Servlets/Struts or Java to convert any video file to FLV so that it can be viewed in the Web Browser.Kindly let me know if any one of u have worked on it.You can also get me at [email protected]
    Thank you all
    Sridhar.N

    Hi all,
    This is N.Sridhar and I am working on file transcoding.Does any one have any idea about video conversion tools/API which can be used to programitically with JSP/Servlets/Struts or Java to convert any video file to FLV so that it can be viewed in the Web Browser.Kindly let me know if any one of u have worked on it.You can also get me at [email protected].
    Thank you all
    Sridhar.N

  • Connecting unix server using java/jsp

    Hi ALL,
    Could you please give me solution ,I want to connect unix server from jsp and I want to run one .ksp file from jsp file

    Define "connect".
    Define "run".

  • Is it possible to execute a transaction by calling a irpt page?

    Hi,
    Is it possible to execute a transaction by calling a irpt page?
    If possible, is there a sample code (.irpt code) for MII 12.1?
    Thanks.

    You can use a SERVLET Tag in your irpt to execute an xacute query.
    Here is the help file from 11.5 but this works in all the versions.
    [http://help.sap.com/saphelp_xmii115/helpdata/en/Advanced_Topics/Report_Generation.htm|http://help.sap.com/saphelp_xmii115/helpdata/en/Advanced_Topics/Report_Generation.htm]

  • Using Java 5, how to develop customizable web-pages  like iGoogle ?

    Is it possible to develop customizable web-pages like iGoogle does, using Java 5 ( simply using JSPs, servlets, JSFs, AJAX etc. and without using portals) ?
    A simple example explaining how to provide 3-4 header graphics options ( like igoogle does) will be helpful. (iGoogle seems to create a cookie, which appears to be used to render the selected header-graphics).
    TIA
    Edited by: DevelopingJava2005 on Jul 7, 2008 9:36 AM

    Without using portals?
    Google uses RSS feeds to compile their mashups on iGoogle. The positioning of those boxes are managed with AJAX and upon placement are saved into a session so they stay there for each visit after.
    Please be a little more clear as to what you are looking for. Yes, it is possible to develop web pages using the technologies you specified to simulate something like iGoogle, so give us some more details on what exactly you're looking for.
    Code wouldn't hurt either.

  • Adding Page to Workset using Java

    i am trying to add a page to a Workset using java. Can any one help me do this.
    Also how can i retrieve the Worksets attached to a Role.

    I am to create a workset in the fashion mentioned below.
    IRoleService rSrv = (IRoleService)PortalRuntime.getRuntimeResources().getService("com.sap.portal.pcd.roleservice.roles");
    IWorksetDescriptor worksetDescriptor = rSrv.getWorksetDescriptor(env);
    parentCtx.bind(worksetName, worksetDescriptor);
    IPortalWorkset workset = (IPortalWorkset)parentCtx.lookup(worksetName);
    But adding pages to the workset is still not resolved.
    Do Pass on any info regarding this.

  • Possible to manage Windows processes using Java

    Hi,
    I'm looking to develop a standalone application that will be able to kill certain Windows processes...is such a thing possible using Java? If not, could someone point me in the direction of a technology that can achieve this?
    Thanks

    [LEARN HOW TO RESEARCH YOURSELF!!! THEN ASK QUESTIONS LATER|http://tinyurl.com/yllkh3v]
    Mel

  • How to change InputField background color using Java Code

    Hi,
    In my application use will enter some set of Cost Centers in a table and submits request.
    In return i will get a list of invalid cost centers which i need to display in a table with input field
    In that table all cost centers will displayed, but invalid cost centers should be highlighted or background color should some other color. like red or yellow.
    Is it possible using java code to change a input field color.
    Please help me.
    Thanks

    Hi,
        declare a error message in message pool and declare a method say "checkCostCenters " and in this method, u can check whether it is a valid cost center .. if it is invalid cost center , then throw the erro message using the below code :
    wdComponentAPI.getMessageManager().reportContextAttributeMessage(
                        inputfieldattibutePointer, IMessageProgramPlanComp.ur error message,
                        new Object[] );
    for getting pointer and label use the below code:
    IWDAttributePointer inputfieldPointer = URNODEELEMENTElement
                        .getAttributePointer(URNODEELEMENT.ATTRIBUTENAME);
              String inputfieldLabel = wdContext.nodeURVALUENODE.getNodeInfo()
                        .getAttribute(URNODELEMENT.ATTRIBUTE).getSimpleType()
                        .getFieldLabel();
    hope it helps..
    Thanks and Regards

Maybe you are looking for

  • How do you sign out of an iTunes or App Store account on your iPhone???

    I use a US and UK account, I can easily sign in between the two on my laptop, but cannot find a way to sign out of an account on my iPhone??!! Do I need to sync the iPhone with my laptop while iTunes is logged in as the other account to kick it out o

  • How I can change this query, so I can display the name and scores in one r

    How I can change this query, so I can add the ID from the table SPRIDEN as of now is giving me what I want: 1,543     A05     24     A01     24     BAC     24     BAE     24     A02     20     BAM     20in one line but I would like to add the id and

  • EBP - SUS integration

    Hi experts,      I m new to SRM5.0.  Can any one explain me abt EBP-SUS integration? Wt is the need of this integration? wt r the prerequisites to this? I m using EBP4.0 and SRM5.0. Kindly help me on this. Regards Raaams.

  • Cannot install Flash Player on Mac running Yosemite

    No matter what I do, following all of adobe's installation suggestions, gets flash player to install on my macbook pro, running yosemite 10.10.3. Please help. I'm afraid I may have to do something desperate! Thank you very much.

  • What app can I use to upload pdf documents that cane read in ibooks?

    Previously, with MobileMe, I have uploaded pdf files to iDisk and then opened them in iBooks on my iPad2.  Worked great.  Moving to iCloud, I can no longer upload to iDisk and must use (?) Pages, which will not open a pdf or allow me to move it to iB