How to Post[Receive / Ship] an existing Transfer Order using AIF Service [InventTransferOrderPostingService] in AX 2012 R2


I need some help on the below scenario:

I have created Transfer Order in AX 2012 R2. Now I have to Post [Receive] this created Transfer Order using AIF service provided by AX 2012 R2 [i.e. InventTransferOrderPostingService].

Can you please help me out on how can I use this service in order to POST[Receive] my already created Transfer Order in AX 2012 R2.

Would appreciate for your help.



Do you really want to use a document service for that? I wouldn’t say that you want to create a journal outside AX and import it to AX; you want just to say AX which order ID to post (maybe with some parameters) and AX will do the rest.

A custom service sounds as a much better choice to me than a document service.

Hi Martin,

Appreciate for your quick response.

I mentioned document service because I found one that is provided by AX in standard [InventTransferOrderPostingService]

Yes, I just want to POST [Receive] my Transfer Order using AIF. Can you please help me how can I achieve that using custom service if not Document Service?

Would appreciate for your help.



Aha, I didn’t know about this document service. I’ll have to take a look first.

Hi Muneeb

Could you please tell me from where you want to call InventTransferOrderPosting.Create service operation???


Vijay Solanki.

All right, so the document contains InventTransferParmTable and InventTransferParmLine records. They define what should be posted. The service then call InventTransferUpdShip or InventTransferUpdReceive to post the document.

What kind of help do you need from us?

Hi Martin,

I too am facing the same problem. The Ship portion works just fine if you set the QtyShipNow and QtyShipNowSpecified fields on the InventTransferParmLine records.

I expected the receive to work by setting the QtyReceiveNow and QtyReceiveNowSpecified fields. I even set teh ReceiveUpdateQty to ReceiveNow enum value and ReceivedUpdateQtySpecified to true in teh InvTransferParmTable to no avail. The error message I get is “Ship now quantity must be positive.” The message itself is surprising because we are on the receive side of things. I even tried to set a value for QtyShipNow, but that didn’t make a difference in the error message.

The post has been out there for some time with a few followers.

Any thoughts?


This error comes from inside AX, not from the web service interface. Therefore you can go and debug the code to see what’s going on (see Debugging Services in AX 2012).

Thanks for the tip on debugging Martin. I was able to debug and find the solution. The following code does the trick.

invTransferParmTable.UpdateType =


invTransferParmTable.UpdateTypeSpecified =


invTransferParmTable.ReceiveUpdateQty =


invTransferParmTable.ReceiveUpdateQtySpecified =


I did a little bit more work and found that all you really need is to set the UpdateType and UpdateTypeSpecified properties.

Hey Raman,

That’r right. AX expects some values that you need to provide by using the standard service itself.

If you need any help please do let me know.



Hi Muneeb,

I am also consuming same inbound, I am getting so many errors like inventtransid and other errors can you provide me code if possible.

Hi Ashish,

Thanks for your query.

Can you please elaborate your scenario as in what exactly are you trying to do and where you getting stuck up.

Accordingly, I can provide my input.