Creation of Reference Object in Complaints

Hi,
I want to create Ibase component as reference object for Complaint . I debugged through the Order_maintain and tried to fill as like that.
Please find the  code :
DATA: lt_refobj_com TYPE  crmt_srv_refobj_comt.
DATA: ls_refobj_com TYPE crmt_srv_refobj_com.
DATA: lt_input_field  TYPE  crmt_input_field_tab.
DATA: ls_input_field TYPE crmt_input_field.
DATA: lt_field_names  TYPE crmt_input_field_names_tab.
DATA: ls_field_names TYPE crmt_input_field_names.
DATA: lt_service_os TYPE  crmt_srv_osset_comt,
      ls_service_os TYPE  crmt_srv_osset_com.
DATA: lt_crmt_srv_osset_comt1 TYPE crmt_srv_osset_comt1,
      ls_crmt_srv_osset_com1 TYPE crmt_srv_osset_com1.
DATA: lv_guid_16  TYPE  guid_16.
**ls_refobj_com-ref_guid  =  '4C43086918AE56A9E1000000AC1447B6' .
**ls_refobj_com-ref_kind  = 'A' .
*ls_refobj_com-ib_instance = '566' .
**ls_refobj_com-ext_refobj = '10000608'.
**ls_refobj_com-profile_type = 'A'.
*ls_refobj_com-product_id = '10000608'.
**ls_refobj_com-guid =  '4C43086918AE56A9E1000000AC1447B6' .
*ls_refobj_com-mode = 'A' .
*APPEND ls_refobj_com TO lt_refobj_com.
ls_service_os-ref_handle = '0000000000' .
ls_service_os-ref_guid  =  '4C43086918AE56A9E1000000AC1447B6' . ....
ls_service_os-ref_kind  = 'A' .
*ls_service_os-mode = 'C' .
ls_crmt_srv_osset_com1-ref_handle = '0000000000' .
ls_crmt_srv_osset_com1-ref_guid = '4C4308AF18AE56A9E1000000AC1447B6'.........
ls_crmt_srv_osset_com1-subject_profile = 'ZSRVCAL'.
ls_crmt_srv_osset_com1-profile_type = 'A' .
*ls_crmt_srv_osset_com1-mode = 'C' .
CALL FUNCTION 'GUID_CREATE'   " *is it necessary? else what guid needs to giv here*
IMPORTING
   ev_guid_16       = lv_guid_16
*   EV_GUID_22       =
*   EV_GUID_32       =
ls_refobj_com-ref_handle = '0000000000' .
ls_refobj_com-ref_guid  =  lv_guid_16 .  " 4C56A479560967D6E1000000AC1447B6' .
*ls_refobj_com-ref_kind  = 'A' .
ls_refobj_com-ib_instance = '566' .
*ls_refobj_com-ext_refobj = '10000608'.
*ls_refobj_com-profile_type = 'A'.
*ls_refobj_com-product_id = '10000608'.
*ls_refobj_com-guid =  '4C43086918AE56A9E1000000AC1447B6' .
ls_refobj_com-mode = 'A' .
ls_refobj_com-main_object = 'X' .
APPEND ls_refobj_com TO lt_refobj_com.
ls_crmt_srv_osset_com1-refobject  = lt_refobj_com.
APPEND ls_crmt_srv_osset_com1 TO lt_crmt_srv_osset_comt1.
ls_service_os-osset = lt_crmt_srv_osset_comt1.
APPEND ls_service_os TO lt_service_os.
ls_input_field-ref_handle = '0000000000' .
ls_input_field-ref_guid   = '4C43086918AE56A9E1000000AC1447B6' .
ls_input_field-ref_kind  = 'A' .
ls_input_field-objectname = 'SERVICE_OS' .
ls_field_names-fieldname = 'IB_INSTANCE' .
APPEND ls_field_names TO lt_field_names.
APPEND ls_input_field TO lt_input_field.
CALL FUNCTION 'CRM_ORDER_MAINTAIN'
  EXPORTING
    it_service_os   = lt_service_os
  CHANGING
    ct_input_fields = lt_input_field.
*CALL FUNCTION 'CRM_REFOBJ_MAINTAIN_OW'
*  EXPORTING
*    it_refobj_com          = lt_refobj_com
**   IV_EXTERNAL_CALL       = FALSE
*  CHANGING
*    ct_input_field         = lt_input_field
** EXCEPTIONS
**   ERROR_OCCURRED         = 1
**   OTHERS                 = 2
*IF sy-subrc <> 0.
** MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
**         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
*ENDIF.
DATA: lt_obj TYPE crmt_object_guid_tab,
      lv_obj TYPE crmt_object_guid.
lv_obj = '4C43086918AE56A9E1000000AC1447B6' .
APPEND lv_obj TO lt_obj.
CALL FUNCTION 'CRM_ORDER_SAVE'
  EXPORTING
    it_objects_to_save         = lt_obj
*   IV_UPDATE_TASK_LOCAL       = FALSE
*   IV_SAVE_FRAME_LOG          = FALSE
*   IV_NO_BDOC_SEND            = FALSE
*   IT_ACTIVE_SWITCH           =
* IMPORTING
*   ET_SAVED_OBJECTS           =
*   ET_EXCEPTION               =
*   ET_OBJECTS_NOT_SAVED       =
* CHANGING
*   CV_LOG_HANDLE              =
* EXCEPTIONS
*   DOCUMENT_NOT_SAVED         = 1
*   OTHERS                     = 2
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
* EXPORTING
*   WAIT          =
* IMPORTING
*   RETURN        =
COMMIT WORK.
Please let me know, where I made mistake?
Sushant
Edited by: Sushantbm on Aug 9, 2010 8:15 AM
Edited by: Sushantbm on Aug 9, 2010 8:17 AM

has anybody worked on adding referene objects to compliants programmatically?
Thanks,
Sushant

Similar Messages

  • Quality notification - more reference objects

    Hello,
    business need is to have quality notification with possibility to refer either production order or purchase order under one notification type.
    By standard this seems not possible as:
    Complaint Against Vendor references to Purchase order
    Internal Problem Report references to Production order.
    But in section "User-specific notification" is mentioned
    A user-specific notification type has the same basic structure as the standard, predefined notification types. The screen layouts, reference objects, and tab indexes, however, may differ from those in the predefined notification types, depending on how you customize the user-specific notification type.
    But I have not found a way in customizing to enable this.
    Advice appreciated.
    Br, Jan

    Thanks for the asnwer, but I think this does not solve my problem.
    In the configuaration for "Notification Header and Screen Areas" I do have
    - notification header screen H500
    - customized screen O550 (BADI)
    and both are needed.
    The BADI is used to customize refernce object screen, not reference documents screen. But my idea was to change reference document screen area in a way, that both purhcasing and production reference documents are visible in there.
    I only managed to get the vendor screen by adding screen area 037 to "Extended View: Tabstrips and Screen Areas" But adding purhcase document as reference to Reference documents remains my problem.
    I am kind of able to make the vendor screen visible by e.g. adding screen area 037 Partner overview screen (table control).But creating a new pop-up window for notification reference, where both options (pur ord, prod ord) would be available with copying functionality - in my opinion this requiers completely custom coding.

  • Appraisals EHP4 - multiple reference objects not working in the same TAB

    Dear SAP Experts,
    I am working on MBO Performance Mgmt EHP4. I have created an appraisal template and testing this in MSS.
    Now the structure of the template has a VB object called u201CMy Developmentu201D.
    Within this VB Object I have created two other VB objects in the following order called
    u201CSuccess Profilesu201D and
    u201CAdditional Areas of Developmentu201D
    The business requirement is to
    a)     within success profiles have the requirements of the position of the appraisee to be defaulted
    b)     then have the ability for the Manager to select one of the requirements and select the ADD functionality to add another element which has 4 customs columns to then be completed by the Manager
    c)     Within u201CAdditional Areas of Development, the Manager needs to be able to have an ADD button to create the 5 custom columns to be completed by the Manager.
    The good newsu2026u2026..I have created the structure ok, with custom columns and have used fixed enhancement for defaulting the requirements of the appraiseeu2019s position and then having the reference object to each one of these requirements to then create 4 additional fields when the Manger selects the ADD button next to each requirement.
    I have also used a separate set of reference objects to have an ADD button against the VB object u201CAdditional Areas of Developmentu201D which is in the sequence after the VB object Success Profiles, then this will allow the creation of the 5 columns ok and works fine.
    I have also used the reference object for the Success Profiles which would expect to  show the ADD function to add the new element with 4 fields. Also the ADD function for the u201CAdditional Areas of Developmentu201D appears.
    I have created the config to display the My Development as a tab and have both the u201CSuccess Profilesu201D and the u201CAdditional Areas of Developmentu201D within this tab.
    The bad newsu2026.. When I select the ADD button against the VB object u201CSuccess Profilesu201D nothing happensu2026u2026u2026
    The defaulting of the requirements of the appraiseeu2019s position into the appraisal document under the Success profiles ONLY works if the VB object u201CAdditional Areas of Developmentu201D is DELETED from the appraisal document.
    However, when I delete the VB object u201CAdditional Areas of Developmentu201D the ADD of the VB object for Success Profile now works
    So it only seems to work if I delete the u201CAdditional Areas of Developmentu201D VB in the document which seems wrong to me.
    Please can someone advise
    Thanks
    Oliver

    Hi SAP experts,
    does anyone have an answer to my question above.
    Much appreciated it
    Not sure how to get screenshots stored in SDN f someone could explian.......
    Thanks
    Oliver

  • Reference object in Notification

    Dear All,
    I am new person in  the SAP-PM module but I need to work on it. I have a quarry, what is reference object and reference object key in notification creation, in which table I need to see the values of the same.
    Thanks and regards,
    Krish....

    Hi
       Notification we create with reference to some object.
    whch means it is refering some functional location , equipment etc.
    So it is address some object against wihc notification is creating.
    check  table QMFE
    regards
    Krishna

  • Factory calendar attached to reference objects

    Hi,
    While creating date types and date duration we can attach reference objects to them. But where do we see the time zones and the factory calendar settings maintained against a reference object?
    Regards,
    -Sweta

    Hi Sweta
    If you want to add company holiday to take in account while calculating End date then config for Factory calendar / Holiday
    SAP Implementation Guide> SAP Web Application Server>General Settings-->Maintain calendar
    Once u done with config, use FM BUSINESS_DATE_CREATE for End date creation.
    I am still finding how to attach the FC to Reference object. If i get will post u again.
    hope you able to get your result.
    Thanks,
    Deven
    Do not forget to allocate points.............

  • Po Creation With Reference to contract

    Dear Experts
                       We are creating the purchase order with reference to contract the contract quantity not copied to po. it is asking to enter the qty. but it should copy the contract quantity. the same contract price also not copied to po. it is copying from the info record price.
    my scenario is at the time of po creation with reference to contract it should copy the contract qty and price any copy control assignment is there or any other settings required.
    Please help
    Regards
    Anand

    Hi,
    If a contract with one of your principal vendors exists for a material, you can create purchase orders referencing this contract. Purchase orders created in this way are called contract release orders.
    The price, vendor data,  terms of payment, delivery costs, and any instructions to the vendor are adopted from the contract automatically.
    If  you have created the contract & info records is also exists  then system will give priority to contract to determine the conditions.
    Please check the source list ,whether contract is maintained over there or not.
    Thanks,
    AMIT

  • Notification: Set priority and dates, based on the reference object

    Hello,
    I'm searching for an idea/solution, to set the priority of a notification automatically, depending on the entered reference object (F/L or equi).
    I.e. I want to classify the F/Ls and equis with a priority (e.g. via the classification, or F/L / equi master data). When the user creates a notification, and enters a F/L or equi, the priority should be selected from the object and set automatically.
    Thanks for your answers!
    Best regards
    Stephan

    Hello Pete,
    thank you for your answer. Unfortunatelly both user-exits seem not to work for my problem.
    QQMA0025: Default values when adding a notification
    Priority and dates can be modified, but in this step you don't have the functional location. I thought, I can send a popup in this user-exit, to ask for the functional location, but the functional location is deleted in a later step (before the 1st display of the notification header), i.e. the user has to enter it again.
    QQMA0018: Deadline setting based on entered priority
    Here you can only modify the dates / times, but not the priority.
    Another show stopper is, that the exits will only be processed once, i.e. in both cases, a change of the functional location doesn't adjust the dates/times.
    It seems, that exit "Before saving the notification" (as far as I remember QQMA0014) could be a solution.
    I see 2 problems ->
    1. the user enters the F/L or equi and nothing happens to the priority / dates -> sending a popup in the saving process to inform the user about the changes, could be a solution.
    2. What to do, when the user has already maintained priority and/or dates/times?
    I will have a look, if there are enhancement spots in the notification program. Perhaps this can help me (or better - my boss ).
    Best regards
    Stephan

  • Restrict Item Category Item Creation using Reference Only

    Hi All
    Here is the scenario, I want  "Restrict Item Category Item Creation using Reference Only"
    a.Retrieve document number VBELN from sales order header table VBAK for the current order. Check if the sales order is of type ‘ZAB’ referencing field AUART in table VBAK.
    note : Any changes to existing sales order "ZAB" will be performed in thesame sales order type(ZAB) in VA02 transaction.
    b.If step a is passed, check internal table structure for sales order item level as XVBAP-PSTYV for possible item category values of 'ZDEF' for the entered line item and document number (XVBAP-VBELN).
    c.If the cancel/change item category values are found on the line item, check internal table structure for document flow (XVBFA) if the cancel/change item category was created as reference:
    i.Check if entry exists in XVBFA for the preceding document number field VBELV with value equal to value in the subsequent document number field VBELN. This value must equal the current sales document number VBELN in table VBAK.
    ii.The above check must be done in conjunction with the following check:
                1.Check if entry exists in XVBFA for the preceding document type field VBTYP_V with value ‘C’ equals subsequent document type field VBTYP_N with value of ‘C’.
    d.Once the above checks are passed, collect the item number from internal table XVBAP (Field: POSNR) for the change/cancel item category line item added to the sales order.
    e.Check if the item number retrieved in the previous step exists in table VBAP (Field: POSNR) with an item category that is not part of the list of cancel/change item category defined in step b.
    f. Check if the item number collected in the previous step exists in the subsequent item number (Field : POSNN) in internal table XVBFA for the row that passed checks in steps b and c.
    g.If item number exists, check if this subsequent item number field equals the preceding item number field value (Field: POSNV) in table XVBFA.
    h.If step g fails, generate an error message stating that the user needs to the create the cancel/change item category line item with reference to the original line item and do not allow the user to proceed with the transaction.
    i.If step g succeeds, allow the user to proceed with the transaction.
    can any one send me the logic for this scenario.
    Rgds
    Chinna

    Hi Chinna,
      Please use BADI "BADI_SD_SALES_ITEM" to achieve your requirement..
      Let me know if you have further questions..
    BR
    Rakesh

  • Creation of login object failed

    Hi all,
    I've got a problem with the mobile client development.
    We are using the mobile client for many years and we even develop a lot with it, but now i have a problem never seen.
    After extending a bDoc and start testing the application, after the generation and login, system states "Creation of login object failed".
    So i did a full generation. Result the same.
    I debugged the ValidateLogin class and found out, that in the following statement is failing
           BOLOGIN = BusinessRootObject.BusinessFactory.LoadBusinessObject("LOGIN", determineUser)
    BOLOGIN is Nothing at the end. I tried out to create the Object via        BOLOGIN = BusinessRootObject.BusinessFactory.CreateBusinessObject("LOGIN")
    same result. Next i tried to create the BOACTIVITY and it failed as well. One day before everything was fine, even with changing business documents.
    The error in the VB.ERR object says:
    -     err     {Microsoft.VisualBasic.ErrObject}     Microsoft.VisualBasic.ErrObject
         Description     "In der Methode BusinessFactoryCore.LoadBusinessObject ist eine System-Exception aufgetreten"     String
         Erl     0     Integer
         HelpContext     0     Integer
         HelpFile     ""     String
         LastDllError     3     Integer
         Number     5     Integer
         Source     "MTBLLFW"     String
    Can anybody please give a hint.
    We are using CRM 5.0 SP7 and MSA SP7 on MS 2003 Server with local repository. DB is SQL2000.
    Yesterday i was releasing a changelist and now its no longer working at all, what a mess.
    Thanks to all,
    Andreas Rose

    Hi Andreas,
    The problem may be incorrect or corrupt ARSREP.DAT file.
    The reason may be that the BDOCs are not synched from MAS. Once you sync this through MAS you will find the *.bdoc files at the location
    mentioned under the registry key HKLM\SOFTWARE\SAP\MSA\MW\TL\BDocPath
    Usually this would be default as C:\Program Files\SAP\Mobile\tpsfiles.
    After this when you generate the BusinessLibrary the Arsrep.dat file
    will have the *.bdocs incorporated in the Arsrep.dat file.
    Hope this helps.
    Regards, Gervase
    ps. For synching the BDocs refer to SAP Note 942942

  • Getting ORA-20001: Creation of new object is not allowed: !!

    Hi Am getting ORA-20001: Creation of new object is not allowed while enabling constraints after importing the dumps from source to target datbase,can anyone assist me to fix this issue.

    Hi Osama/Mustafa,Thanks for your quick response,can you please explain me the following things-
    1)As i don't have privilege to run the DBA_XX views,am not able to run those queries-
    SELECT OWNER, TRIGGER_NAME, TRIGGER_BODY FROM DBA_TRIGGERS WHERE TRIGGER_TYPE IN ('AFTER EVENT', 'BEFORE EVETN') AND TRIGGERING_EVENT LIKE '%CREATE%';
    can you tell me what output it'll throw,based on this output how will we fix the issue.
    2)SELECT * FROM dba_sys_privs WHERE privilege = 'UNLIMITED TABLESPACE';
    why we need to check this privilege?as i don't have privilege to run this one in my db.
    3)select * from dba_source where upper(text) like upper('%Creation of new object is not allowed%');
    as i don't have privilege to run this one in my db,already i got the object name from my logfile
    and more you have quoted"This is an error of someone that coded purposely on your database, probably dba or a developer who has privilege and again it is in a database event trigger"
    4)can you explain me much more deeper about the root cause and as already sent note to my DBA,can you explain me the solution to fix this issue ?

  • Creation of new object link for DMS

    i have searched a lot  about Creation of new object link for DMS on internet .
    and all replies  focus on that documentation :
    1.     Program two screens for the following module pools for the SAP object that is to be linked additionally:
    u2013 SAPLCV00
    u2013 SAPLCVIN
    The process logic must be according to that of screen 0204 in program SAPLCV00 and must not be changed.
    2.     Create the function module OBJECT_CHECK_XXXX (XXXX = name of the SAP object).
    i need  to know how to implement that  in more detailed step by step
    as  i know DMS and  abap also.

    Hi Reda,
    Hope the below URL will help to understand how the Process of adding a object link works.
    Enhancement Without Modification of the Object Links - Engineering Change Management (LO-ECH) - SAP Library
    Thanks & Regards,
    Seshadri.

  • Error while Debugging MSA  'Creation of Login Object Failed'

    Dear Friends,
    I am working on CRM Mobile Sales 5.0 SP 5.
    I have setup my Mobile Client and Mobile Application Studion On the same machine.
    I have perform the initial generation of the application from Mobile Repository server to my machine.
    it gave me 6 errors and 12 warnings  and took about 4 hrs for generation.
    Now when i tried to debug the generated application,
    i get my login screen and once I enter username and password.
    Error popups up stating "Creation of login object failed".
    and then another error
    "Starting MPPFailed" (MPP is my project name).
    Please suggest me how should i go about to debug the application solving the above errors.
    Awaiting Reply,
    Best Regards,
    Pratik Patel

    Am not sure if you were able to resolve the issue but below are some points:
    a. I think the dlls sfabol and msa are not any more registerable, since they are more of VB.NET components and here assembly is registered and not the dll.
    b. For logging into the application just ensure that you have user id in table SMOUSER and the employee for that user in SMOMITABT table.
    c. If this is fine, then ensure that you have the latest BDOC metadata information on your laptop. I think in 5.0 also you need to use Clientconsole to download this information.
    d. If this is all okay, then try running SQL profiler and check if the query to the ides db is being executed by the framework. If the query is fired then it means application seems to behave properly but the query is not retrieving relevant details.
    For further details feel free to contact me..
    thanks,
    Piyush

  • "Creation of login object failed" after MAS generation

    Hi everybody,
    I am working on CRM Mobile Sales 5.0 SP6. I have performed the initial generation with the .NET Application Studio. It gave me 6 errors and some warnings. Now when I tried to logon my mobile client I 've got following error:
    "Creation of login object failed".
    Visual Studio is installed on partition "C:\Program Files\" and Mobile Sales on "D:\SAP\"
    Has someone any ideas? Thanks in advance,
    Mirko

    Hi Mirko!
    In your app you're calling unknown data structures. While generating the "compiler" read the names and want to create the relevant structures but the necessary data to do this are missing. You have to start fist the client console doing a complete meta data generation. If this runs without error your generation inside the studio will succeed, too.
    BTW: In your first posting you've written "D:SAP..." and in your last the error-message was "D:ProgrammeSAP..."...
    Perhaps different settings?
    Do you have made already a successful generation with the actual installation?
    Good luck,
    Ingo
    Message was edited by:
            Ingo Schmökel

  • BAPI for creation of Authorization Objects in BI 7.0

    Hi BW Gurus,
    Greetings!!!
    Is there any BAPI Available for creation of Authorization Objects in BI 7.0.
    The data will be transferred through flatfiles.
    Kindly provide me the info as earliest as possible.
    Best Regards,
    Priya

    Got the Workaround...
    Priya

  • " Automatic creation of Cost object owners"

    Hello Experts,
    I am working on a rollout project, for "Inter Company Service Invoicing (ICSI)"
    Presently my client requirement is " Automatic creation of Cost object owners"
    First of all i will explain the process
    In ICSI there are two parties one is Service Requestor(SREQ) and other one is Service Provider(SPROV)
    Depending on SREQ requirement SPROV will create a SO and send it to SPROV
    It will reach SREQ contact person, he will updates Cost objects, and send it to SREQ reviewer person, he will check the cost objects and send it to Cost object owner of the SREQ.
    He will approve the SO, once all approvals hasbeen done, then system automatically converts SO to IV, and post entries on both sides automatically ata the same time.
    Here my requirement is on SREQ side the Cost Object Owner should find automatically.
    And we done this proces in Portal itself.
    Your suggestions will be great help to me, and are appreciated.
    Thanks in advance
    Any inputs please...............
    Regards,
    Satya.

    Hello Ajay,
    Thank you for the response.
    But my requirement is not to populate cost objest.
    It is the approval flow. The reviewer person will check and add the cost objects to the service order and send that Service Order for the final approval i.e.. Cost Object Owner.
    So here my requirement is the System has to create that Cost Object Owners Automaticlly
    How can i achieve this?
    Regards,
    Satya

Maybe you are looking for

  • Text and Image component Image placing not working!

    Hi Guys, For some odd reason, when I drop text and image component to the page I do not see the left or right option to place image in "Styles" tab.  The styles tab shows blank and by default paragraph gets placed after image.  This only happens in m

  • HT5312 delete itunes and start over

    How do I delete itunes and completely start over but not lose the money on card?

  • Regarding the clusters  in HR - ABAP

    Hi All,               Anybody is having the documents regarding the clusters. If so can u please share with me…? Thanks & Regards,   Suresh

  • After effects help & adobe air

    i'm in the after effects cs5 application (creative suite production premium) on a power mac 10.5.8 and when i go to the help pull down and click on after effects help, i get the following error message: don't even know what abobe air is. i'm assuming

  • Is there a quick way to replace all the faces in the crowd with those of a few friends' faces?

    I took some photos of the crowd at the fabulous McCartney concert in Phoenix. I would like to replace them with the faces of three people for an article I'm doing about the concert. I was hoping that there was a feature that would automate this someh