Create lead via reference to campaign using custom code

I'm looking for an easy way via custom code to create a lead transaction and include a reference to a campaign object in my system.  I'm having no luck with the XIF doc flow segment for the lead creation and would like to look for other methods to update this link.
Any suggestiosn on how to code this would be great.  Yes I know that I could do ELM, but then I would need to rewrite my entire program, my leads create properly minus the campaign link.
As always help will be acknowledge and correct answers given here, will be put in the CRM wiki for future reference.
Thank you,
Stephen

Okay this actually will work via XIF adapter, the trick was proper settings of the related type attribute.  When SAP inserts new doc flow for relations to campaigns it is done via "space" option.  The LV_GUID needs to be GUID of the campaign in question.
  LS_DOC_FLOW-RELATION_TYPE   = 'VONA'.
  LS_DOC_FLOW-RELOBJ_ROLETYPE = 'VORGAENGER'.  "Role A
  LS_DOC_FLOW-RELOBJ_OBJKEY   = LV_GUID.
  LS_DOC_FLOW-RELOBJ_TYPE     = 'BUS2010020'.
  LS_DOC_FLOW-OBJECT_TASK     = 'I'.
  LS_DOC_FLOW-RELATION_TYPE_ATTR = space.
  LS_DOC_FLOW-INPUT_FIELDS-RELOBJ_ROLETYPE = 'X'.
  LS_DOC_FLOW-INPUT_FIELDS-RELATION_TYPE   = 'X'.
  LS_DOC_FLOW-INPUT_FIELDS-RELOBJ_OBJKEY   = 'X'.
  LS_DOC_FLOW-INPUT_FIELDS-RELOBJ_TYPE     = 'X'.
  LS_DOC_FLOW-INPUT_FIELDS-RELATION_TYPE_ATTR = 'X'.
  INSERT LS_DOC_FLOW INTO TABLE LT_DOC_FLOW_XIF_DATA.
Yep this will need to end up in the wiki once my I'm finished up with the full program/conversion.  I guess I will keep my title as "pied piper"  of the XIF adapter for now.
Take care,
Stephen

Similar Messages

  • Update Power View reports properties using custom code

    Is there any way to update power view reports uploaded in SharePoint 2013 shared data source link using custom code?
    Best Regards,
    Sameer Salunke
    MCTS-Please remember to click "Mark As Answer" if a post solves your problem or "Vote As Helpful" if it was useful.

    Someone out here must have an answer????   I know that SharePoint 2013 saves the view created in Power View therefore the metadata must be accessible somehow?  Can someone explain
    how to find that metadata in the SQL tables maybe?  I would be surprised to find out I am the only one who needs this?
    Ken Craig

  • How to query a dataset using custom code in report builder 3.0

    Hi,
    Can anyone please suggest whether it is possible to query a dataset by using custom code in report builder 3.0.
    Thanks in advance.

    Hi Purbasha,
    please see below similar thread:
    https://social.msdn.microsoft.com/Forums/sqlserver/en-US/9af8f39a-9dc5-49ab-91af-2f64198c8477/ssrs-2008-custom-code-for-database-query
    https://social.msdn.microsoft.com/Forums/sqlserver/en-US/440ff5de-1c21-47de-95d8-e4212d6cef6d/dataset-in-custom-code-in-sql-server-reporting-services?forum=sqlreportingservices
    swallow

  • Creating "Payables Account Transaction" using custom code

    Hi Gurus,
    I need a help. I have a requirement that I have to create "Payables Account Transaction" using custom PL/SQL code. Kindly could you advise me as to which API or Package should i use to get this done. Currently I am in 11.5.10.2.
    Pls help me on this.
    Thanks,
    Genoo

    Hi Genoo,
    As mentioned I would reverse the standard journals coming from Payables, that way you can still see what the original journals were and drill back using them. So you don't do anything in the subledger.
    Alternatively if you wanted to get more risky, when you run the Payables transfer to GL, you could choose not to submit journal import and then you could manipulate the AP Journal records while they are still in the GL_INTERFACE (as they also go through that table) prior to going to GL, then you could do whatever you want - and if you don't delete them (but update / copy them) they will still retain the drilldown links back to AP.
    Regards,
    Gareth

  • Create new survey data for opportunity using abap code

    Hello to all,
    I have one requirement.
    create survey data for given opportunity ID using abap code. or copy survey data from one opportunity to another opportunity using abap.
    any ideas..
    many thanks
    Babu

    Hello Babu,
    You can do this through the CRM_ORDER_MAINTAIN FM, this is the generic FM to edit any transaction in CRM.
    The FM contains an internal table IT_SURVEY that must be filled. Actually, this table will only contain a reference to the (completed) survey, it doesn't store the data of the survey itself.
    For some example coding, take a look at the SrvTSurvey.do controller. If you want to see what data is stored in the IT_SURVEY table, create a transaction and attach a completed survey to it (you can easily do it in the standard views of the webclient) and take a look at the survey structure in the CRM_ORDER_READ FM/Report.
    Let me know if you need more guidance,
    Reward points if useful,
    Regards,
    Joost

  • How to create a table in the file using java code.?

    HI,
    I should export the data from the view objects to a word document. I have done that but I should
    display the data in the form of a table.
    Kindly come up with the necessary information on how to create a table in the file using java.
    Thanks,
    Phani

    Hi, Thank you for responding to my query.
    The below are the details of my code.
    DCBindingContainer dcBindings =
    (DCBindingContainer)BindingContext.getCurrent().getCurrentBindingsEntry();
    DCIteratorBinding StudentDetailsContent =
    (DCIteratorBinding)dcBindings.get("StudentView1Iterator");
    OutputStreamWriter w = new OutputStreamWriter(outputStream, "UTF-8");
    Row currentRow =
    StudentDetailsContent.getRowSetIterator().first();
    Object a[]= currentRow.getAttributeValues();
    int i;
    for(i=0 ;i<=a.length;i++){
    w.write(a.toString());
    w.write(" ");
    w.flush();
    I am usning this coding to achieve the task of exporting data to file.
    I need to display this information in the table that is where I need help from you people.
    Thanks,

  • Creating a folder in current workspace using java code

    Hi Experts,
    I need to create a folder and some file in the workspace of NWDS user. Can someone please suggest how can i find out the workspace of user using JAVA code.
    IWorkspaceRoot is not working in NWDS.
    Regards
    Pranav

    Hi Pranav,
    Tell me if you want to create this folder at run time or in NWDS while developing application.
    If you want to create it at the time of development just change your perspective to Java perspective and from there you can see the entire project structure and from there you can create desired files / folders.
    Ninad

  • File upload in KM using custom code

    Hi All,
    We do keep on getting requests to  frequently upload versions of file in KM for our users, Is there a way where a customised iview can be developed to pick up a file from desktop and upload it in KM ? I think this can be done using Webdynpro Abap or Webdynpro Java not very sure .
    Please guide me with pre-requisites and steps as I am new to such kind of development in portal.
    Regards,
    Jalpa Shukla

    Hi Jalpa Shukla,
    Not sure what you mean by "getting requests to frequently upload versions of file". If you are trying to write some custom code through which you can upload a file in KM (and maintain the document versions). Check [this|http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/3095f14c-29c5-2b10-f69e-edcb6f0f1367?QuickLink=index&overridelayout=true] link.
    Hope it helps!
    Thanks, Ansar.

  • Using custom code in SSRS PDF rendering

    Hi,
    I have a written some custom code ( a simple function to maintain a counter ) in SSRS Report properties.
    Everything works fine when I render the report in Report Viewer, but the custom code is not recognized when I render the report to PDF.
    What is wrong with my code?
    There is no error reported. The custom code is just getting skipped when I render to PDF.
    My custom code is as follows..
    Public Shared Dim iCounter AS Integer = 1
    Public Function IncrementCounter(SomeValue As Boolean) As Boolean
    iCounter = iCounter + 1
    Return SomeValue
    End Function
    Public Function GetCounter() As Integer
    Return iCounter
    End Function
    and my call to the custom code is..
    =code.GetCounter()

    Hi ha_emp,
    From your description, it seems that custom code work well when you preview the report. While it would be skipped when the report is exported to PDF. After testing the custom code in my environment,I find that the custom code will run again when exporting
    the report, so when we run the report on Report Server and export it to PDF, the custom code will be run twice, the value will be counted twice.
    Based on my research, I find that we can delete the “Shared” in the first row of the custom code to fix this issue. Then the custom code will works well on Report Server.
    If there are any misunderstanding, please elaborate the issue for further investigation.
    Thanks, 
    Katherine Xiong
    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.

  • Create Lead with Oracle BPEL process using Siebel CRMOD web service

    I'm trying to create a lead in the siebel OD (hosted) with a oracle BPEL process and using the siebel web service (2.0). In my bpel process I've been able to
    1. Login to OD and get a session id
    2. create the partner link using Siebel OD (version 2.0) wsdl for Lead
    3. Assign the session id to the partner link
    4. Assign the inputs (lastname, firstname, leadowner, viewMode=Personal, lovLanguageMode=LDC) to lead
    5. Call the leadInsert operation on the partner link
    However, when I deploy and execute the bpel process it breaks after calling the leadInsert with the following error message:
    +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    <remoteFault xmlns="http://schemas.oracle.com/bpel/extension"><part name="code"><code>Server</code>
    </part><part name="summary"><summary>The record with search specification '' in business component 'Lead' (integration component 'Lead') has been deleted by another user since it was retrieved.(SBL-EAI-04289)</summary>
    </part><part name="detail"><detail>&lt;detail>
    &lt;siebelf:siebdetail xmlns:siebelf="http://www.siebel.com/ws/fault" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
    &lt;siebelf:logfilename xmlns:siebelf="http://www.siebel.com/ws/fault" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">OnDemandServicesObjMgr_enu_138636.log&lt;/siebelf:logfilename>
    &lt;siebelf:errorstack xmlns:siebelf="http://www.siebel.com/ws/fault" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
    &lt;siebelf:error xmlns:siebelf="http://www.siebel.com/ws/fault" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
    &lt;siebelf:errorcode xmlns:siebelf="http://www.siebel.com/ws/fault" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">(SBL-DAT-00494)&lt;/siebelf:errorcode>
    &lt;siebelf:errorsymbol xmlns:siebelf="http://www.siebel.com/ws/fault" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"/>
    &lt;siebelf:errormsg xmlns:siebelf="http://www.siebel.com/ws/fault" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">The record with search specification '' in business component 'Lead' (integration component 'Lead') has been deleted by another user since it was retrieved.(SBL-EAI-04289)&lt;/siebelf:errormsg>
    &lt;/siebelf:error>
    &lt;/siebelf:errorstack>
    &lt;/siebelf:siebdetail>
    &lt;/detail>
    </detail>
    </part></remoteFault>
    +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    Any feedback as to what I'm doing worng woull be greatly appreciated.
    Thanks,
    --manoj                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    Hi,
    We are also using BPEL to send data out to SIEBEL CRMOD.
    I've created a proxy that deals with authentication and session management.
    All you have to do is to deploy the proxy as a war file and refrence it as the end-point of your partner link.
    Code is here:
    http://another-soa-blog.blogspot.com/2010/02/oracle-siebel-on-demand-session-and.html
    Regards,
    Fred.

  • Creating drop down menus in JSP using custom tags

    Hi, i am working on a JSP which has custom tags for displaying menubar and menus, now i want to have these menus converted into drop down menus, and the submenus displayed onmouseover event. I am getting solutions with pure html page calling javascript functions.But i dont need this, i want the work done by my TagHandler class which sends the output to output stream, which in turn is transformed in to actual HTML by a XSLT embedded in my JSP.
    Please help as i am new to custom tags, and desperately in need of help.
    If possible give some sample code or useful links.
    I will be highly grateful.
    Thankx in advance

    that's fine, but the tag has to, ultimately, generate the HTML/Javascript stuff like you've already seen.

  • How to move to next record of the databank file using custom code

    hi,
    can someone please tell me how to move to next or the previous record the Databank file. i found a funtion setcurrentdatabankrecord(), but i am not able to use it.
    thanks in advance...

    Hi,
    I recently had the same problem, here's my solution:
    "setCurrentDataBankRecord" is available only to External Program Control.
    I used the VB of an empty Word2002 Document.
    1. you have to reference the webAnlyst.exe in the object-catalogue
    2. create a module via the menue
    3. type in the code
    This is the code I used - some of the code is just for control
    Private Sub TestSetDBRec()
    Dim pdtest As webanlst.ProgT
    Set pdtest = New webanlst.ProgT
    Dim currDBI, numRecsCurrDB As String
    ' Workspace öffnen
    pdtest.play.OpenWorkspace "VBTest"
    ' Script öffnen
    pdtest.play.openScript "BM2B_VK_Änderung"
    ' DB-Abfragen
    numRecsCurrDB = CStr(pdtest.play.getDataBankSize)
    currDBI = pdtest.play.currentDatabankIndex
    pdtest.play.setCurrentDataBankRecord (2)
    currDBI = pdtest.play.currentDatabankIndex
    ' jetzt das Script abspielen
    pdtest.play.doScript "BM2B_VK_Änderung"
    End Sub
    This works! You can also looping through the database by getting the current value and set the value back increased by e.g. one
    Hope it is helpful!

  • Displaying a Content Area using custom code

    Hello list,
    Is it possible to display the contents of
    a content area as a custom portlet so that I
    don't have to expose the content area as a
    portlet and I can add custom formatting etc ?
    Any tips ?
    Sanjay

    A number of SQL views are provided for retrieving information
    from content areas. These views are documented in the PDK. For
    folders, use the view WWSBR_ALL_FOLDERS.
    Regards,
    Jerry

  • How to load a XML into Checkpoint in UFT API using custom code

    I am automating a webservice using UFT-12. In which I am trying to load a xml into the checkpoint at run time. but I am not able to find out a way of doing it.Can any1 help me on this?

    @piyu_sh_arm 
    ‎Thank you for using HP Support Forum. I have brought your issue to the appropriate team within HP. They will likely request information from you in order to look up your case details or product serial number. Please look for a private message from an identified HP contact. Additionally, keep in mind not to publicly post ( serial numbers and case details).
    If you are unfamiliar with the Forum's private messaging please click here to learn more.
    Thank you,
    Omar
    I Work for HP

  • Setting Default values for field using custom.pll

    Hi All,
    I have an rquirement to set the default values on Meterial Tranasction screen for some condition
    I tried it in both ways via Form Personalization and using custom.pll
    i m using the following code in custom.pll
    form_name      varchar2(30):= name_in('system.current_form');
    block_name varchar2(30):= name_in('system.cursor_block');
    trx_type           varchar2(30);
    subinv                varchar2(30);
    begin
    if form_name='WIPTXMAT' and block_name ='MTL_TRX_LINE' then
    if event_name ='WHEN-VALIDATE-RECORD' then
         trx_type:=name_in('WIPTXMAT.TRANSACTION_TYPE');
    if trx_type ='WIP Return' THEN
         copy(10,'MTL_TRX_LINE.TRANSACTION_QUANTITY');
              copy(10,'MTL_TRX_LINE.NUMBER_OF_LOTS_ENTERED');
              sinv:=trim(name_in('MTL_TRX_LINE.SUBINVENTORY_CODE'));
              if sinv is null then
                   copy(subinv,'MTL_TRX_LINE.SUBINVENTORY_CODE');
                   copy(fr_locator,'MTL_TRX_LINE.LOCATOR');
                   FND_MESSAGE.SET_STRING(sinv);
                   FND_MESSAGE.SHOW;
              end if;
         end if;
    end if;
    end if;
    end event;
    Problem is that default values are getting set but not for all rows . if there are 4 records then values are set for only first 2 rows and if there are 2 rows then defaults are set for 1st row only.
    Same behaviour happens when i do it via form personalization
    i couldn't understand the behaviour of WHILE-VALIDATE-RECORD event..
    Please provide some suggestion on it. its really urgent.
    Thanks in Advance
    Renu

    Works Now...

Maybe you are looking for

  • How can I get a more visible cursor on my MBP?

    I'm using Reflector to display my iPad on my MBP so I can display on a wall with a classroom projector.  I would like to use a large bright cursor on the MBP to point out tools on the iPad. Anyone know how I can change the cursor? Tx, Stacey

  • Lightroom 4 on a MAC and Fujifilm X-Pro1 - can't read the RAF files

    When I open the import dialogue the thumbnails are greyed out with "preview unavailable for this file".  I continue with the import, which fails, and the message that comes up is a list of the files and "The files are form a camera which is not recog

  • Lacie d2 drive not ejecting disc

    I have an odd problem with my Lacie d2 drive, when I put in a disc, any type of disc ... It seems as if the mechanical eject button on the face of the lacie is disabled forcing me to use my disc utility to eject the mounted disc. This is a new drive

  • Maven Ant Tasks

    I have a build file as shown below (AFTER THE ERROR). When I try to run it I get the following error: Buildfile: build.xml BUILD FAILED /Users/abder-rahmanali/Desktop/Hibernate/build.xml:13: The following error occurred while executing this line: jar

  • Awaiting 4  Ur Help...

    Hello Friends, I've Landed Up in an Odd Problem.... Wat I need is to Get a List of Column Names And their types In a database... Without Using ResultMetaData.. My problem is that.... By following in traditional approach of executing a query "SELECT *