Help on how to use BAPI_ACC_DOCUMENT_POST...

Hello experts,
Please help me on how to use the BAPI BAPI_ACC_DOCUMENT_POST. I dont have the time to
record via SHDB and do BDC and I would like to try out the said BAPI. I think this will be faster
I need to fill in the header, line items, etc. Any detailed examples will be highly appreciated.
Thanks a lot guys and take care!

Take a look at the following code :
* IF GL ACCOUNT
*       Accountgl / Compte générale
        ws_accountgl-itemno_acc   = w_compt.
        ws_accountgl-comp_code    = p_bukrs.
        ws_accountgl-pstng_date   = ws_reformat-datecpt.
        ws_accountgl-fisc_year    = ws_reformat-datecpt(4).
        ws_accountgl-fis_period   = ws_reformat-datecpt+4(2).
        ws_accountgl-doc_type     = p_blart.
        ws_accountgl-item_text    = ws_reformat-libel.
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
          EXPORTING
            input  = ws_reformat-cptclf
          IMPORTING
            output = ws_accountgl-gl_account.
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
          EXPORTING
            input  = ws_reformat-kostl
          IMPORTING
            output = ws_accountgl-costcenter.
      ELSE. " ACC. PAYABLE
*       Account Payable /  Compte fournisseur
        ws_accountpayable-itemno_acc   = w_compt.
        ws_accountpayable-comp_code    = p_bukrs.
        ws_accountpayable-item_text    = ws_reformat-libel.
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
          EXPORTING
            input  = ws_reformat-cptclf
          IMPORTING
            output = ws_accountpayable-vendor_no.
        APPEND ws_accountpayable TO accountpayable.
      ENDIF.
*     Currencyamount Struct.
      ws_currencyamount-itemno_acc = w_compt.
      ws_currencyamount-currency = 'EUR'.
*     ws_currencyamount-curr_type = '00'.
      IF ws_reformat-sign EQ 'C'.
        ws_reformat-wrbtr_c = ws_reformat-wrbtr_c * ( - 1 ).
      ENDIF.
      ws_currencyamount-amt_doccur = ws_reformat-wrbtr_c.
      APPEND ws_currencyamount TO currencyamount.
* BAPI
    CALL FUNCTION 'BAPI_ACC_DOCUMENT_POST'
      EXPORTING
        documentheader = documentheader
      TABLES
        accountgl      = accountgl
        accountpayable = accountpayable
        currencyamount = currencyamount
        return         = t_return.
    IF sy-subrc <> 0.
      MESSAGE e999(re) WITH 'Problem occured'.
    ELSE.
        CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'.
    ENDIF.

Similar Messages

  • Need help on how to use conference facility within adobe connect

    I need some help on how to use conference facility within adobe connect?

    I'd recommend you start here: Getting Started with Adobe Connect - Adobe Connect User Community

  • Javascript error on - Help - Learn how to use Numbers with this online...

    I am trying to find out more about Numbers. I am using iTunes 9.1.1 on a Vista PC. I get a Javascript error in Internet Explorer 8 when I try to access:
    Help - Learn how to use Numbers with this online resource.
    http://help.apple.com/numbers/1.0
    The link redirects to the following page:
    http://help.apple.com/iwork/safari/interface/#tan727163ed
    The above page is blank except for boxes for Keynote Help, Pages Help, Numbers help, and a blank input field that seems to do nothing. Here is the Javascript error message from Internet Explorer 8:
    Webpage error details
    User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.30729; .NET CLR 3.0.30729)
    Timestamp: Tue, 1 Jun 2010 20:55:54 UTC
    Message: This command is not supported.
    Line: 1
    Char: 41589
    Code: 0
    URI: http://help.apple.com/iwork/safari/interface/javascript.js

    Link also does not work for me in WIN 7 with IE8. However, it does work in Chrome in WIN 7. It also works in Safari on my G4. Suggest you try Chrome or it may work in another browser like FireFox or Safari in Vista.

  • Where do I find help on how to use a software?

    Recently I've purchased a ZIP software through App Store - (Smart Zipper Pro). I have never used one of these programs and now have a large file to send to a customer. I found no customer support nor directions on the use of it.
    I will appreciate there is someone that could help me understanding how to use this software. I have tried different alternatives but files seems to have the same size as the original. There is no compression.
    Your help on this subject will be greatly appreciated.
    AntaresPower

    have a large file to send to a customer.
    *Some suggestions regarding sending large files:*
    If you both have High-speed connections, the easiest & fastest way is through Dropbox.
    I send all my large/huge files this way instead of using email.
    iChat has the same ability of transferring large files as Dropbox but is slower.
    Adium has file transfers.
    Yahoo Messenger has file transfers.
    If you must use email, check out YouSendIt and TransferBIGFiles for large & small file transfers.
    MediaFire is another file transfer site.
    Care to share which OS you are using? 

  • Help on how to use Skype account?

    anybody can help me ???
    how to use this skype account???
    This post was transferred from its previous location to create its own new topic here; its subject and/or title has been edited to differentiate the post from other inquiries and to reflect the post's content. A link to this post appears where the post was originally added.

    Hi, Guiuan, and welcome to the Community,
    I recommend these two places that have a wealth of information to help you get started:
    https://support.skype.com/en/faq/FA12288/getting-s​tarted-with-skype-for-android-phones
    https://support.skype.com/en/category/SKYPE_FOR_AN​DROID/
    Regards,
    Elaine
    Was your question answered? Please click on the Accept as a Solution link so everyone can quickly find what works! Like a post or want to say, "Thank You" - ?? Click on the Kudos button!
    Trustworthy information: Brian Krebs: 3 Basic Rules for Online Safety and Consumer Reports: Guide to Internet Security Online Safety Tip: Change your passwords often!

  • Help in how to use the controlers in Ze

    I just got the New Zen M and I am having the worse time dealing with the controllers. The worse of all is the tapping I love the mp3 but since I started to play with it (an hour ago) I just feel like throwing it against the floor since is not doing what i want it to do. Please any help or tricks in how to use those controllers I will really appreciate.

    You have to tap the keys gentle . i see you will not have your player long . this is the best out

  • Help! How to use pay_element_link API

    Hi all,
    I am developing HRMS Interface to transfer employee element data from other system into EBS. And I want to use Pay element Link API to implement the requirement.
    The requirement is:
    1.     Using the primary key of NATIONAL_IDENTIFIER_NUMBER (ssn) check to see if the employee exists as an active employee in Oracle.
    2.     Validate that the Element is a valid element and retrieve the Benefit Type from the DFF (ELEMENT_INFORMATION11). If the element is invalid or does not have a Benefit Type defined, flag the record as ‘REJECTED’ and write the error to the log file and move to next record in staging.
    3.     If the employee has another active element assigned for the same Benefit Type, using the API’s terminate the existing element for that Benefit Type.
    4.     Using the API’s add the new element to the employee with the appropriate element entries.
    5.     Flag the status of the record in staging to ‘PROCESSED’.
    The step1 and step2 is logic adjustment. And I have finished them. Next I will finish 3,4 and 5. The fifth step is easy to approach. I can not do 3 and 4 for I do not konw how to use the pay_element_link_API. And I know the 3 wiil use PAY_ELEMENT_LINK_API.update_element_link, the 4 step will use PAY_ELEMENT_LINK_API.CREATE_ELEMENT_LINK. But the most difficult is I do not konw what to pass the parameter to update_element_link and create_element_link. I do not know the meaning of the two procedure's parameter.
    When the element has many entry values, how to import these entry value into the EBS. For example, an element names 'Retirement Plan' and the element has a input value names 'Amount' and the value is 80$. So I want to know how to import the 80$ into EBS by the API. Just means, the 80$ will pass to which one parameter in the create_element_link or update_element_link.
    Please give me some ideas. Thank you so much

    On troubleshooting the HR api's you can use the pyupip logging mechanism . This would allow you to pinpoint what stored procedure section is being executed when the error ocurred.
    set serveroutput on
    spool trace.log
    begin
    hr_utility.set_trace_options ('TRACE_DEST:DBMS_OUTPUT');
    hr_utility.trace_on;
    -- your code here
    hr_utility.trace_off;
    Exception
    when others then
    dbms_output.put_line(sqlerrm);
    hr_utility.trace_off;
    END;
    spool off

  • Help! How to use a custom package (in the format of .JAR) in Forte4Java!

    Dear all,
    I am a beginner with Java. I have downloaded a Java package, jacob.jar, from the Internet. In order to import it in my Java program written under Forte4Java, I did the following stuff:
    1. Mount this JAR to the FileSystem; (this should include this package to the classpath, right?)
    2. Right-clicked the mounted JAR, and from the popup menu choose "Tool | Update Parser Database...";
    Next, I create a new Java project with a main class in it. At the head of this class file, I typed "import" to refer to this package. It turned out that the contextual completion window DOES show my package and all of its classes properly. In the body of this class file, I called some of the public methods defined in this package. The contextual completion window showed those methods properly too. Then I built this project and NO compilation error was reported. But, at run-time, an exception of "java.lang.UnsatisfiedLinkError: no jacob in java.library.path" was thrown at the invocation of the first public method of this package. I don't know what's happening here. Did I install the package the wrong way? If I can't get this problem solved as soon as possible, I will be in big big trouble :-( Please help and thanks in advance....
    FYI:
    the full exception message is as followed:
    java.lang.UnsatisfiedLinkError: no jacob in java.library.path
    at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1312)
    at java.lang.Runtime.loadLibrary0(Runtime.java:749)
    at java.lang.System.loadLibrary(System.java:820)
    at com.jacob.com.Dispatch.<clinit>(Dispatch.java)
    at testjacob.TestJACOB.main(TestJACOB.java:27)
    Exception in thread "main"
    Regards,
    Tracy

    I am not sure how exactly Forte works, so I don't know how useful my reply is, but here it is:
    Try checking the classpath manually that always helps. Your classpath should contain the directory in which the jar file is.
    Which OS are you using?

  • Need Help Understanding How To Use iMessage Between Two iPhones

    I have an iPhone 4 and my wife an iPhone 3GS.  We both have iOS 5, but I have discovered something about iMessage I need to make sure I understand correctly.  As I understand it iMessage can send text even if our voice carrier service is unavailable.  I tend to loose signal inside the building I work in.  I usually can get texts in and out, but sometimes not.  But in testing the two phones sending iMessages, I've noticed is that if I have one of the phones with iMessage turned on and the other with iMessage turned off, the two phones will not be able to exchange text.  Is that how it's supposed to work?  Even though one of these phones can receive an iMessage doesn't mean the other one send one back.  Can't the system detect when one phone is connected and another one not, and the one that is not gets sent SMS messages instead?  I don't want to try to send my wife an iMessage because I can't get a voice signal in my building, but her have iMessages turned off and not able to get any messages from me, iMessage or SMS.  I guess I need help better understanding how this actually works between the two phones so I can always get texts back and forth between my wife and I.  My other misgiving is that this iMessage thing consumes my data limit.  My wife gets unlimited because she had her phone before the limits were imposed, but I got on board after, so I am hesitant to use iMessage all the time because of it.  I have no intention to send picture mail through iMessage, but the thing is if I wanted to switch to SMS to send picture mail to save data, but my wife's phone is set to iMessage, she won't get it.  If this is how this thing is supposed to work, I'm not really impressed.  Some insight would be appreciated

    I think you are making this way too complicated. Why are you turning iMessage off? If you are at your office connect to the WiFi there and send your wife messages that way (unless your office is blocking the port iMessage uses). When possible the two phones will use iMessage but will revert to SMS is iMessage is not available if that option is set that way.
    I would not worry about using up your data plan if you have the 2GB, text iMessages are going to be very small and MMS (picture) ones are not very large either. Unless you are sending hundreds of picture iMessages a day you will have a hard time using up your data.
    If you are near an Apple Store you should explore signing up for an intro iPhone course and have them run through iMessage options.

  • How to Use 'BAPI_ACC_DOCUMENT_POST' in an Inbound IDOC?

    Hi,
    One of the standard IDOC for posting accounts is Message type(ACC_DOCUMENT), and an FM IDOC_INPUT_ACC_DOCUMENT "NOT released'  uses same
    functionality to achieve.
    I created a custom one as standard one is not released yet, My question is how to handle records if number of records in flat file coming from legacy contains more data.
    Example. If number of records exceeds 999.
    Thanks and Regards
    Mohinder

    Hi,
    BAPI_ACC_DOCUMENT_POST can post 999 line items only.
    More than 999 records:
    If the count is 999 don't take the flat file values, take a dummy GL account and assign it as 999 record.
    the amount should be balance amount of 998 records, it may credit or debit.
    Regards,
    Sri

  • How to use BAPI_ACC_DOCUMENT_POST

    Hello ALL.
    I need to update the field AUFNR in database table BSEG, I'm using the BAPI BAPI_ACC_DOCUMENT_POST, the function module execute with out errors, but do not change the field AUFNR.
    Could any one help me?
    Thanks in advance

    Hello Lalit, thanks for your answer.
    We take care about the order number while creating new accounting documents, But the users are creating these documents automatically through transaction code FAGL_FC_VAL (Foreign Currency Valuation).
    This transaction code creates a new accounting document based on another accounting document already created, what I need is, replicate the order number from original accounting document into the new one.
    Best regards.

  • Need Help on How to Use Compressor 3

    We recently upgraded from FCP 4.5 to FCP 6. And boy was I lost when I tried exporting the 45 minute video using Compressor. All I need to do is compress it to Mpeg-2... first I tried converting using QT but cant find format for mpeg-2 (m2v) so I decided to use Compressor. I dont know with you guys but it looks so complicated.
    Can anyone pls give me a walk thru or step by step instructions how to compress my 45 min. video to mpeg-2...
    pleaaaaaaaaaseee....:)

    Here's a step by step guide for the new interface:
    http://www.kenstone.net/fcphomepage/compressor_3_interfacestone.html
    For DVD compression help, check out:
    http://dvdstepbystep.com

  • Please help on how to use variables inside a method call

    Hello guys,
    How's it goin?
    Pardon me if you find my question silly, but I am relatively
    new in ActionScript 2.0 programming.
    I have here a simple problem. It seems I can't use a variable
    inside a method call of an object. Here's the code. Please note of
    the authParams string variable below.
    import AkamaiConnection;
    import mx.services.WebService;
    var GeneratedToken:String;
    var authParams:String;
    // Create a Web Service object
    var TokGenService:WebService = new WebService("
    http://webservice.asmx?wsdl");
    // Call the web service method
    var myToken:Object = TokGenService.GenerateToken();
    // Create an AkamaiConnection object
    var connection:AkamaiConnection = new AkamaiConnection();
    connection.addEventListener("onConnect", this);
    connection.addEventListener("onError", this);
    // If you get a result from the web service, save the result
    in a variable
    myToken.onResult = function(result)
    // If you get a result from the web service, save the result
    in a variable
    myToken.onResult = function(result)
    GeneratedToken = result;
    authParams = GeneratedToken +
    "&aifp=v001&slist=37414/test/Streaming/";
    //Call the Connect method of the AkamaiConnection class
    connection.connect("cp37414.edgefcs.net/ondemand",true,true,5,true,false,"443","rtmpt",
    authParams);
    But then, if I use a hard-coded string value in lieu of the
    variable, the method call works!
    connection.connect("cp37414.edgefcs.net/ondemand",true,true,5,true,false,"443","rtmpt",
    "testStringvalue");
    I don't know what I'm missing or what I'm doing wrong... Can
    somebody help me please? I am using a 30-day trial version of Adobe
    Flash CS3. Also, when I Trace output the variables, the values are
    there. It just that they can't be read or recognize inside the
    method call. Is this a ActionScript limitation?
    Thanks so much in advance!

    The result param is a returned, “Decoded ActionScript
    object version of the XML”. I am not exactly sure what that
    means but I have had issues of returned XML values and their
    datatype. When I did have these issues I had to cast or convert
    into the desired datatype. Try one of the following, assuming the
    problem is related to the code that you have bolded.
    GeneratedToken = result.toString();
    authParams = GeneratedToken +
    "&aifp=v001&slist=37414/test/Streaming/";
    Or
    GeneratedToken = String(result);
    authParams = GeneratedToken +
    "&aifp=v001&slist=37414/test/Streaming/";
    Or
    GeneratedToken = result.toString();
    authParams = String(GeneratedToken +
    "&aifp=v001&slist=37414/test/Streaming/");

  • How to use BAPI_ACC_DOCUMENT_POST for CO-PA Account Assignment

    hi all,
    when i used bapi to posting docment,but for document_type ='DR'(customer invoice), it is related with Profit. Segment.
    it returned following message in return table:
    E RW                   609 Error in document: ZBKPF ZY2005 DEVCLNT230
    E F5                   808 Field Prof.Segmt is a required field for G/L account CN10 50600824
    W KI                   166 Enter a true account assignment object with revenues
    maybe due to i haven't fill parameter:CRITERIA and VALUEFIELD
    but i have no idea about this.
    would you please give some idea, sample code is great .
    thanks.
    helen

    Hi, Qunli
    If you haven't the documentation of the BAPI, you can search in here http://ifr.sap.com/catalog/query.asp
    You can find the BAPI in SAP FI(470 or above). Under the 'Accounting Interface' hierarchy, you can find a 'AcctngBilling' BO, and the Post method of it is the BAPI you're calling. (you can search to demonstrate in Tcode BAPI). There is some explain for the interface, if it is not enough, I have some sample application which call this BAPI.
    Hope it will be helpful.
    Thanks a lot

  • In-App-Purchase-Air-Ios (extension inside, need help on how to use it :P)

    Code examples: http://code.google.com/p/in-app-purchase-air-ios/w/list
    Extension download: http://code.google.com/p/in-app-purchase-air-ios/downloads/list
    How do I use this with my Flash CS5.5 Pro (IDE)?
    They show examples with using ADT command line stuff.

    Hi Saumitra Bhava,
    Nice examples of Native Extensions. I am having an issue when trying to use a block in Objective-c Something as simple as
    - (void) searchForAlbums
        void(^test)(void) = ^{
            NSLog( @"BLOCK CALLED" );           
        test();
    does not work and FlashBuilder reports the following error.
    ld: absolute addressing (perhaps -mdynamic-no-pic) used in -[MobileImagePicker searchForAlbums] from /var/folders/nw/nwjKk-0UFzKXgLSHtcbjxE+++TI/-Tmp-/534267c1-6c13-4a8e-98d6-6c8357d4f355/li buk.co.betadesigns.extension.NativeImagePicker.a(MobileImagePicker.o) not allowed in slidable image. Use '-read_only_relocs suppress' to enable text relocs
    Compilation failed while executing : ld64
    Have you tried using blocks in an iOS extension?
    Regards
    Anthony

Maybe you are looking for

  • Compaq pressario 6604 au conexant high definition audio is not working in windows 7.. please help me

    i upgraded my hp compaq pressario v 6604 au to windows 7.but i cant install sound driver. while installing it tells 'driver installation failed, could not find the device for this driver' i downloaded new version of sound driver named sp 40170 from

  • How can I download Aperture on OX 10.10.3

    I saw a video about Aperture and the first thing I wanted was to download the app. I searched in the App Store for the app and I couldn't find it. Then I searched in the Internet and read that the app was discontinued and the new version is Photos fo

  • IPod connected to other Computers

    Hi guys i lately tried to connect my iPod to my friends Computer. after doing this i opened iTunes and everything was fine except for one thing: eventhough all my files were listed and shown they were almost invisible, indicating me that i can't use

  • How to extract multibyte characters?

    Hi, I have used acrobat plug in and could extract ascii characters to a text file. I want to extract multi byte characters, Chinese, Korean. Could you help me if you know how to do it? Another question is that how could I debug plug in (by example, s

  • GUI Development Paradigm

    Hi everybody! I'm quite new in ALBPM and I have some questions about it, especially about user interfaces. I've been developing JSP aplications (using MVC frameworks) for a long time, and I can't figure out how does it fit in the ALBPM world. What's