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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

How to restore a deleted Sales order(Invoiced) with all the order data

(0) ShareShare
ReportReport
Posted on by 781

Hello Experts,

If i want to restore a deleted SO, which is already invoiced.

**I've found a link with X++ code which is for Ax 2009 - using this i can restore the deleted SO(Open order with/without Lines) in Ax 2012 also. But if the Order status is Invoiced then i'm not getting all the information( like payment,Voucher etc ) after restore.

https://community.dynamics.com/ax/b/axaptavsme/archive/2012/09/27/how-to-restore-deleted-sales-order-or-purchase-order

So please let me know how can we approach( like which class/methods we can use) this.

Thanks,

Johnkrish

*This post is locked for comments

I have the same question (0)
  • André Arnaud de Calavon Profile Picture
    303,982 Super User 2026 Season 1 on at

    Hi Johnkrish,

    What would be the purpose to have a fully invoiced order back? If it is for copy functionality, I can imagine. All posted details are in transaction tables. The sales order is considered as a 'worksheet table'. This means that after fully processing the order, the data is redundant and could be cleaned up.

    Can you elaborate on the payment and voucher details? Where exactly are you searching for this information?

  • Heinz Schweda Profile Picture
    1,367 on at

    Hello John,

    from my point of view it is not possible to fully restore a deleted sales order using this job. Take a look at the Delete Actions node of SalesTable and SalesLine, there are a lot of tables which get deleted, when you delete a sales order.

    Also, the tables SalesTableDelete and SalesLineDelete only contains a selection of fields, which are "saved" when you delete a sales order (if SalesParameters.CancelSales is enabled).

    Regards,

    Heinz

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Joris dG Profile Picture

Joris dG 5

#2
Andrew Jones a1x Profile Picture

Andrew Jones a1x 2

#3
GL-01081504-0 Profile Picture

GL-01081504-0 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans