web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Picking List Registration through X++

(0) ShareShare
ReportReport
Posted on by

Hi everyone. I'm trying to confirm, picking list, picking list registration and packing slip on Sales Orders. I've already done confirming and picking the list. I have trouble coding the Picking List Registration, I couldn't find any reliable codes online that could somehow help my logic. Do you guys have available codes that somehow are related to Picking List Registration? Anything can help. Thank you!

PS: When I run my job, it creates the sales order, and does the confirm and picking list all at once. I want to include Picking List registration in the process. That's how it goes. Just saying. :)

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Heinz Schweda Profile Picture
    1,367 on at

    Hi,

    I've done this once with code similar to the following. Hope it helps.

    static void pickingListRegistration(Args _args)
    {
        WMSPickingRouteID pickingRouteID = "00061";    // Route id to be picked
        List list = new List(Types::String);
    
        list.addEnd(pickingRouteID);
    
        WMSPickingRoute::finishMulti(list.pack());   // Note - this is not in a single tts, so some routes might be posted and others fail
    
        wmsDeliverPickedItems::checkDeliverPickedItems(pickingRouteID, list.pack());
    }


    Regards,
    Heinz

  • Abhijeet Kr  Profile Picture
    60 on at

    The job is great, just one question what to do in case we have with us value of quantity to picked instead of all. Similar to in picking list registration we can provide the number to be picked. What to do in this case thorugh code. 

  • Suggested answer
    Heinz Schweda Profile Picture
    1,367 on at

    Hi, in this case you have to modify the quantity in your WMSOrderTrans-Record before calling WMSPickingRoute::finishMulti().

    There are several ways to do this, the following code worked for me:

    static void pickingListRegistration(Args _args)
    {
        WMSPickingRouteID pickingRouteID = 00061		// Route id to be picked
        InventTransId inventTransId = "000015303";          // LOT ID
        Qty pickQty = 14;                                   // Quantity to pick
        List list = new List(Types::String);
        WmsOrderTrans wmsOrderTrans;
        WmsOrderTrans wmsOrderTransNew;
    
        list.addEnd(pickingRouteID);
    
        // Change quantity
        ttsBegin;
        select forupdate wmsOrderTrans
            where wmsOrderTrans.RouteId         == pickingRouteID &&
                  wmsOrderTrans.inventTransId   == inventTransId &&
                  wmsOrderTrans.FullPallet      == NoYes::No &&
                 (wmsOrderTrans.ExpeditionStatus == WMSExpeditionStatus::Registered ||
                  wmsOrderTrans.ExpeditionStatus == WMSExpeditionStatus::Activated  ||
                  wmsOrderTrans.ExpeditionStatus == WMSExpeditionStatus::Started);
         
        // Split line
        wmsOrderTransNew = wmsOrderTrans.split(pickQty);
        ttsCommit;
    
        ttsBegin;
        // Cancel remaining line
        wmsOrderTrans.cancel();
        ttsCommit;
        
        WMSPickingRoute::finishMulti(list.pack());   // Note - this is not in a single tts, so some routes might be posted and others fail
    
        wmsDeliverPickedItems::checkDeliverPickedItems(pickingRouteID, list.pack());
    }


    Hope this helps,

    Heinz

  • Abhijeet Kr  Profile Picture
    60 on at

    Hi Hienz,

    Thanks for the response, my case is for sales order picking list. I got the idea but i want to update each line by line during some trigger... If if call finishMulti method using routeId it will update all the lines which we dont want. Any suggestions would be really helpful.

  • Mahesh Holla Profile Picture
    30 on at

    Hi,

    I have a similar requirement.

    Did anyone find a solution?

    Regards,

    Mahesh

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans