Link IDoc to FI document using Object Services

We are using a custom IDoc to post financial documents to the R/3 system. There is a requirement to determine the IDoc number that created the accounting document as happens automatically with Incoming Invoices (object type BUS2081).
I'd like to form the link between the IDoc and the Financial document using Generic Object Services so that the Relationships functionality in transaction FB03 can be used. Does anyone know how I can form the link between the IDoc and the Accounting document when posting the document? We use BAPI_ACC_DOCUMENT_POST to post the Accounting document.
Thanks in advance for any help.
Regards,
JB

call function 'BDS_BUSINESSDOCUMENT_CREA_URL'
      exporting
        logical_system = logical_system
        classname      = classname_select
        classtype      = classtype_select
        client         = sy-mandt
        object_key     = objkey_select
      tables
        uris           = i_uris
      exceptions
        error_kpro     = 1
        internal_error = 2
        others         = 3.
    if sy-subrc <> 0.
      message id sy-msgid type sy-msgty number sy-msgno
              with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    endif.
for logical_system use FM OWN_LOGICAL_SYSTEM_GET to get your logical system name.
class name= BKPF
classtype = BO
object_key = <companycode><doc number><year> e.g 011000001234562007
in uris talbe pass the urls to be created.
Raja

Similar Messages

  • Attaching documents using object services

    Hello,
    Are there any performance/sizing guidelines for utilizing the object services function to attach documents to service orders, notification, equipment, etc?
    Our users would like to do this, and I am concerned about performance.
    chris

    Hi Chris,
    from the document point of view I do not know any restrictions which lead to a loss in performance if you attach more documents to a service order or something else.
    Best regards,
    Christoph

  • Storing documents using Object Services

    Hello,
    Does anybody know how to activate the Menu Entry 'Store Business Document' ?
    Thank you ,
    Aranka

    Hi Chris,
    from the document point of view I do not know any restrictions which lead to a loss in performance if you attach more documents to a service order or something else.
    Best regards,
    Christoph

  • How to Upload documents using Gateway Service in SAP UI5?

    Hi Team,
    How to upload documents using Gateway Service in UI5 app.
    This is Attachment Functionality.using Gateway Service in Controller.JS/View.JS.
    Thanks in Advance.
    Regards,
    Satya

    Hi,
    I suggest you use the search function on scn/google...
    Anyways, here are some usefull links:
    How To Upload and Download Files Using SAP NW Gateway SP06
    Uploading files to SAP using HTML5 /AJAX/Gateway media links with real-time progress bar
    Kind regards,
    RW

  • How do I edit a scanned document using Adobe services?

    how do I edit a scanned document using Adobe services?

    To edit a document you will need Acrobat Pro.

  • How to I set an internal link in a PDF document using Preview?  After setting a link under the Tools/Annotations menu, the link doesn't work and no detailed instructions are provided.

    How to I set an internal link in a PDF document using Preview?  After setting a link under the Tools/Annotations menu, the link doesn't work and no detailed instructions are provided via the Help menu other than it showing the pull-down menu selection to make.

    No.  I am able to use the other features such as underlining, highlighting, adding rectangles and oval and save those changes.

  • How do I keep the source document open when linking to a target document using the destination option in Adobe X?

    How do I keep the source document open when linking to a target document using the destination option in Adobe X? Have several links to create in the source document and want to keep the source document and target document open at the same time.

    Go to Edit - Preferences - Documents and un-tick "Open cross-document links
    in the same window".

  • Authorization Object for using Object Services

    Can you tell me how to limit a users authorization to create or delete attachements using the object services functionality?  We'd like to control the addition and deletion of the attachments.  Is there a specific authorization object for this functionality?
    Thank you, Julie

    Hi julie;
    I hope that following are the solution for you problem. Check wheather this is helpful to you or not.
    Authorization Object C_DRAW_BGR (Authorization Group)
    The following table shows authorization object C_DRAW_BGR. This authorization object allows you to limit access to individual documents.
    Fields      Possible Values      Description
    BEGRU (Authorization group)      0000 - ZZZZ      Used to restrict the authorizations for document maintenance further.
    Authorization object C_DRAW_BGR can be used to restrict access to individual documents. It works like a simple on/off switch. If the check of object C_DRAW_BGR is fine, the user's authorization can be further restricted by checking C_DRAW_TCD (check only based on the document type) or C_DRAW_TCS (check of the
    combination of document type and status). At the fifth level there is a BADI called DOCUMENT_AUTH01, which you can use to design your own authority check.
    Authorization Object C_DRAW_DOK (Document Access)
    The following table shows authorization object C_DRAW_DOK. This authorization object controls which original data of a specific document type there are access authorizations for.
    Fields      Possible Values      Description
    ACTVT (Activity)      52 53 54 55 56 57      Change application start Display application start Display archive application Change archive application Display archive Store archive
    DOKAR (Document type)            Here you enter the document type that access to original data is allowed for.
    Authorization Object C_DRAD_OBJ (Object Link)
    The following table shows authorization object C_DRAD_OBJ. This object controls which users can process which document info records, based on a combination of activity, object, and status.
    Fields      Possible Values      Description
    ACTVT (Activity)      01 02 03 06      Create Change Display Delete
    DOKOB (Object)            You must enter the data base table for the objects here (for example, MARA for material record).
    STATUS (Document status)
    if useful rewards points.           
    Regards,
    nitin
    Edited by: nitin bhagat on Feb 18, 2008 6:23 AM

  • Issues in IDOC to File scenario using bussiness service

    Hi Team
    I found a blog which explains about the IDOC to FILE scenario by using bussinss services. I followed the steps and finally i am getting a error message while posting an idoc in we19 (ie IDOC 09878 was saved but cannot or should not be sent).  The setting which have done on SAP side are as below
    SAP SIDE CONFIGURATIONS
    1. Created RFC destination : RFC_XI_SYSTEM
    2. Created port : PORT_TEST
    3. created logical system: IDOC2FILE
    4. created partner profiles: IDOC2FILE
    XI side configurations
    1. Created RFC destination: RFC_SAP_SYSTEM
    2. Created port : by using IDX1 t-code
    DOUBT: here it is asking for PORT, CLIENT,Description and RFC destination, please let me know what values i need to put here, please find the SAP and XI system details below and suggest accordingly.
    3. metadata: by using idx2.
    DOUBT: here it is asking for IDOC type and source port,  i can give the idoc name but i am not getting what i need to give to source prort field, please check and let me know,  please find the SAP and XI system details below and suggest accordingly.
    SAP system details
    Client: 800
    User name: sapuser
    system id: DEV
    system number:10
    XI system details
    Client:100
    username:xisuper
    system id: SXI
    system numebr: 00
    I request you to please check and help to successfullly completion of this scenario. I request you to please provide me the screen shots of the pre-requiste settings and suggest me the steps to debug the scenario.
    Thanks in advance.
    Raju

    To complete your scenario successfully with better understanding of Idoc adapter
    read http://help.sap.com/saphelp_nw70/helpdata/en/ab/bdb13b00ae793be10000000a11402f/content.htm.
    for troubleshooting refer http://help.sap.com/saphelp_nw70/helpdata/en/6a/e6194119d8f323e10000000a155106/content.htm

  • Unable to checkin a document using 'CHECKIN_UNIVERSAL" service through java

    Hi All,
    I am trying to checkin a document through java code and following is my code part for the same( UCM 11g)
    But whenever i run this code part, it throws the following exception
    intradoc.common.ServiceException:csUnableToCheckin,<null>!csUnabletoExecMethod,populateMissingDocumentValues
    Can anyone help me with this?
    Code part
    private void checkinDoc()
    File f=new File("D:/testfolder/BPEL.pdf");
    System.out.println(" absolute path :"+f.getAbsolutePath());
    String filePath = f.getAbsolutePath().replace("\\", "/");
    checkedOutDataBinder.putLocal("IdcService", "CHECKIN_UNIVERSAL");
    checkedOutDataBinder.putLocal("dDocTitle","test");
    checkedOutDataBinder.putLocal("dDocAuthor", "weblogic");
    checkedOutDataBinder.putLocal("dDocType","Document");
    checkedOutDataBinder.putLocal("dSecurityGroup","public");
    checkedOutDataBinder.putLocal("doFileCopy", "1");
    checkedOutDataBinder.putLocal("primaryFile", filePath);
    checkedOutDataBinder.putLocal("xCollectionID", "425180507509000004");
    checkedOutDataBinder = executeService(checkedOutDataBinder,
    "weblogic");
    private DataBinder executeService(final DataBinder binder,
    final String userName) throws DataException, ServiceException
    // obtain a connection to the database
    Workspace workspace = getSystemWorkspace();
    // check for an IdcService value
    String cmd = binder.getLocal("IdcService");
    if (cmd == null)
    throw new DataException("!csIdcServiceMissing");
    // obtain the service definition
    ServiceData serviceData = ServiceManager.getFullService(cmd);
    if (serviceData == null)
    throw new DataException(LocaleUtils.encodeMessage(
    "!csNoServiceDefined", null, cmd));
    // create the service object for this service
    Service service = ServiceManager.createService(serviceData.m_classID,
    workspace, null, binder, serviceData);
    // obtain the full user data for this user
    UserData fullUserData = getFullUserData(userName, service, workspace);
    service.setUserData(fullUserData);
    // binder.m_environment.put(REMOTE_USER, userName);
    ServiceException error = null;
    try
    // init the service to not send HTML back
    service.setSendFlags(true, true);
    // create all the ServiceHandlers and implementors
    service.initDelegatedObjects();
    // do a security check
    service.globalSecurityCheck();
    // prepare for the service
    service.preActions();
    // execute the service
    service.doActions();
    // do any cleanup
    service.postActions();
    // store any new personalization data
    // service.updateSubjectInformation(true);
    //service.updateTopicInformation(binder);
    catch (ServiceException e)
    error = e;
    e.printStackTrace();
    finally
    // Remove all the temp files.
    service.cleanUp(true);
    workspace.releaseConnection();
    // handle any error
    if (error != null)
    // throw new ServiceException(error.m_errorCode, error
    // .getMessage());
    return binder;
    }

    I have been running into the same exception, albeit with UCM 10g:
    Content item 'xxx' was not successfully checked in. Unable to execute service method 'populateMissingDocumentValues'. (System Error: Runtime error: java.lang.NullPointerException
    at collections.CollectionMetaHandler.validateMetaDataDates(CollectionMetaHandler.java:771)
    at collections.CollectionMetaHandler.fillInUndefinedMeta(CollectionMetaHandler.java:806)
    at collections.CollectionUserHandler.setUndefinedMetaData(CollectionUserHandler.java:1353)
    at collections.CollectionUserHandler.populateMissingDocumentValues(CollectionUserHandler.java:1275)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at intradoc.common.IdcMethodHolder.invokeMethod(ClassHelperUtils.java:617)
    at intradoc.common.ClassHelperUtils.executeMethodReportStatus(ClassHelperUtils.java:293)
    at intradoc.server.ServiceHandler.executeAction(ServiceHandler.java:79)
    at intradoc.server.Service.doCodeEx(Service.java:490)
    at intradoc.server.Service.doCode(Service.java:472)
    at intradoc.server.ServiceRequestImplementor.doAction(ServiceRequestImplementor.java:1360)
    at intradoc.server.Service.doAction(Service.java:452)
    at intradoc.server.ServiceRequestImplementor.doActions(ServiceRequestImplementor.java:1201)
    at intradoc.server.Service.doActions(Service.java:447)
    it seems to have something to do with the xCollectionID.
    If I don't set this, it works fine (checking in and out, checking in new revision). If I set it I can check in a new item using CHECKIN_NEW but I am unable to use CHECKIN_UNIVERSAL to check in a new revision.
    Any pointers would be appreciated.
    Edited by: Jaap on 6-jun-2011 2:41
    Edited by: Jaap on 6-jun-2011 3:09

  • Prinitng iwork document using objective c

    Please help in order to resolve the printing issue that i am facing while coding in objective c.
    I want to print any file like (*.pages,*.numbers,*.keynote)
    but i am not able to print these files using PMPrinterPrintWithFile function of objective c
    I am able to print other files like *.txt,*.jpeg,*.png, *.pdf.
    when I try to print iwork document like *.pages file with PMPrinterPRintWithFile, it returns a status as 1028
    when I am printing other files like *.pdf,*.txt it is printed easily with status 0
    and one more point I am not able to find out the MimeType of files like *.pages,*.number,*.keynote
    the MIMETYPE object gets NULL value when i fetch it using the below code.
    The Code I am using :
        #import "Cocoa/Cocoa.h"
        int main(int argc, char *argv[])
        NSPrintInfo *printInfo = [[NSPrintInfo alloc] init];
        PMPrintSession myPrintSession= (PMPrintSession)[printInfo PMPrintSession];
        PMPrintSettings printSetting= (PMPrintSettings)[printInfo PMPrintSettings];
        PMPageFormat pageFormat=(PMPageFormat)[printInfo PMPageFormat];
        OSStatus err = PMCreateSession(&myPrintSession);
        OSStatus status;
        CFURLRef fileURL =(CFURLRef) [NSURL fileURLWithPath:@"filename example *.*"];
        NSString* filePath=@"filename ex *.*";
        NSString* FullPath=[filePath stringByExpandingTildeInPath];
        NSURL * url= [NSURL fileURLWithPath:FullPath];
        NSURLRequest* fileUrlRequest = [[NSURLRequest alloc] initWithURL:url];
        NSError* error = nil;
        NSURLResponse* response = nil;
        NSData* fileData = [NSURLConnection sendSynchronousRequest:fileUrlRequest
        returningResponse:&response error:&error];
        NSString * MIMETYPE= [response MIMEType];
        [fileUrlRequest release];
        NSLog(@"MIMETYPE %@",MIMETYPE);
        PMPrinter thisPrinter= "printername";
        status = PMPrinterGetMimeTypes(thisPrinter, printSetting,&mimeTypes);
        if(status==noErr)
              status= PMPrinterPrintWithFile(thisPrinter, printSetting, pageFormat,     
            (CFStringRef)MIMETYPE, fileURL);
              NSLog(@" value :%@",MIMETYPE);
              NSLog(@"%i",status);
              NSLog(@"=======Printer %@=======", PMPrinterGetName( thisPrinter) );
              [printInfo release];
          return 0;
        return NSApplicationMain(argc,  (const char **) argv);

    Thank you for your reply. This code helps me to open my local document
    MicrosoftWordDocument *activeWordDoc= [wordApp activeDocument];
    [activeWordDoc openFileName:@"file://localhost/Users/ramesh/Desktop/test.doc"
                         confirmConversions: FALSE
                                   readOnly: FALSE
                           addToRecentFiles: FALSE
                           passwordDocument: @""
                           passwordTemplate: @""
                                     Revert: FALSE
                              writePassword: @""
                      writePasswordTemplate: @""
                              fileConverter:MicrosoftWordE162OpenFormatDocument97];
    Can you please tell me how to observe when user saves that document

  • Trigger idoc for returns document using transaction O3O_RT01, O3O_RT02.

    Hi All,
    There is an requirement to trigger an IDOC with the details of returns documents.
    I am building a custom IDOC for this purpose. But the problem is i need to trigger the IDOC when i click on 'RETURN' button in the transactions O3O_RT01, O3O_RT02.
    Kdly help in as to is there any BADI or exit or and event available  to trigger a code when i click on that button, else  let me know how to go about it.

  • How to trigger a workflow using generic object services?

    Hi Experts,
    Let me know on how to trigger a workflow using generic object services.
    My requirement is to trigger the FI document reversal document using Object services.
    Any info or docs relevant to this, please share with me..
    Thanks,
    Dinesh.

    Dinesh,
    First of you need to check if the transaction has a BO (in released status) published to use the GOS.
    These are the pre-requisites for GOS
    http://help.sap.com/saphelp_46c/helpdata/en/94/aa532cddd511d289860000e8216438/content.htm
    Once done.. check that you have valid workflow linkages active for this BO.
    Now when you click on the 'start workflow' the system will show all relevant workflows for the BO to choose from and to start.

  • Object Services - What are the space restrictions?

    Hi experts -
    Our finance team wants to start saving documents in Object Services.  Can you tell me the space restrictions, if any? 
    Many thanks!
    Mark

    Hi Mark
    If they are using Create Attachment as a storage area, I would strongly suggest they look at configuring ArchiveLink (it should be a greyed out area called Store Business Document in object services) so they can store securely. The GOS create attachment option is not recognised as a secure document storage area and its just designed for adhoc working documents. Its also an area that can be deleted by basis as part of the system cleanup if they run a specific transaction.
    They are no hardcoded limitations, but in our experience, the limitations kick in with individual files sizes in excess of 100MB however this will be dependent on the SAP architecture, bandwidth as its largely to do with the file size being so large that the file times out before it can be completed copied to the server.
    Regards,
    Athol

  • Object Services - Adopting attachment from Req to PO

    Hi All,
    After adding an attachment to a requisition using Object Services, I'd like to bring the attachment forward to the PO during the 'Adopt' process. I know I can add the attachment to the PO using the same process, but is there an automated way? Some configuration?
    Thanks!

    Hi Anil,
    Thank you for your response. Any idea when this will happen? Is it contained in a support pack?
    Regards,
    - Kathy

Maybe you are looking for

  • Open items can not be cleared FZ326

    Hello, I arrived on a project and learnt a former member who left created a huge issue in production. As he deleted a parallel currency depreciation area and the parallel currency type 30 in FI itself, we are currently unable to clear any open item i

  • I'm getting Error messages when I open FF4 and when I close it.

    When I open FF4 I get the following message: "TypeError: Components.classes [componentid] is undefined." I click on "OK" and FF opens up with no problem. When I close it I get this message: "ReferenceError: m_caFXTBobj is not defined". I click on "OK

  • AED CALCULATION -IMPORT PO

    hIII When I am capturing excise invoice of import purchase order 1) AED value is not getting captured.system is displaying BED + Ecess 2) In the Excise item tab system is displaying excise duty but in header tab the duty is showing duty multiplied by

  • My Mac mini with my samsung screen, Problem is it not windscreen ?

    My Mac mini with my samsung screen, Problem is it not windscreen ? Help me

  • Testing the Interface

    Hi Team i have to test an interface. In my scenario there is no IR Part involved, no mapping , only ID part is involved. i am using two adapters, sender is JMS and receiver is IDOC, for this scenario i have to test whether the interafce is working fi