Posting Transfer Order Through Code.

I have a requirement that i need to write the posting routine to post the transfer order But there are so many things in between posting the transfer order i.e. pick,receipt etc…

My data is inserting in transfer header and lines.

Can some one guide me how can i achieve this task through cside code.

Thanks.

You don’t have to write a single line of posting code, that already exists. All that you have to do is figure out what happens behind the scenes, and automate those tasks. The posting itself will be simple calls to the already existing posting routines.

Take a blank piece of paper, turn on the debugger, and process a transaction manually. Write down what all happens in code, and decide which parts you need to write code for.

One thing is clear though: you do NOT have to write ANY posting code. Create the documents and call the posting/registration codeunits for those documents.

Hi guys,

you can use a report based on Transfer header and call the codeunit to release and posting Transfer order.

//use Global variables

TransferPostShipment Codeunit TransferOrder-Post Shipment

ReleaseTransferDocument Codeunit Release Transfer Document

Transfer Header - OnAfterGetRecord()

TransHeader:=“Transfer Header”;

//Release

ReleaseTransferDocument.RUN(TransHeader);

//Validation Expédétion

IF TransHeader.“Expédition.Auto” THEN

TransferPostShipment.RUN(TransHeader);

//Validation Recéption

IF TransHeader.“Recéption.Auto” THEN

TransferPostReceipt.RUN(TransHeader);

but there 's a problem when you would validate more then one Transfer Order at the same time : there is a message like this :

Error :The Value Entry already Exists , Identification fields and values : Entry no.=‘274565’

I’m looking for someone has this Error message. i’m cloged at this step. any suggestion you are welcome.

Best regards.