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)

Restore source code from deployable package

(0) ShareShare
ReportReport
Posted on by 277

Hi.

I have some customizations that I have created into a deployable package and they are deployed with success to both UAT and PROD. Now my DEV box ended up being corrupted and I deleted it and redeployed a new DEV box. I thought that I could just create a DEV box from a point-in-time restore of my UAT, but realized to late that this wasn't the case. I then redeployed a new clean DEV box and copied in data from PROD through this guideline https://docs.microsoft.com/en-us/dynamics365/operations/dev-itpro/database/copy-database-from-azure-sql-to-sql-server which worked perfectly fine. The thing is that I didn't use VSTS for my code, which I know I should have, and now I want to restore the source code. I have deployed the deployable package to the DEV box and this makes the customizations appear and working in the application, but I cannot access the source code in VS. I can see my extension model but I cant edit it and the overlaying models do not appear at all.

Is there anyway I can restore the source code?

Any help is appreciated, thanks.

*This post is locked for comments

I have the same question (0)
  • Verified answer
    André Arnaud de Calavon Profile Picture
    301,075 Super User 2025 Season 2 on at

    HI Brian,

    As of today, you have to start using VSO for your source control. A deployable package does NOT contain the source code, only the runtime objects.

    If you have the old VHD, you can try to get the files from the local package directory.

  • Verified answer
    Martin Dráb Profile Picture
    237,965 Most Valuable Professional on at

    Deployable packages don't contain source code; they contained binaries (DLL) created by building the source code. They won't help you.

    If you don't use version control, your only chance is backup. If you don't have any, the files simply don't exist anymore.

    Working without any kind of version control is just a terrible idea; nobody should ever do it. This is just one example of what may happen if you don't manage your source code properly.

    There is a possibility to decompile DLLs to C# to see what you've done there, so you don't have to develop everything from scratch, but you can't extract X++ code and metadata from there.

  • Refshauge Profile Picture
    277 on at

    Hi Martin.

    Any good documentation for decompile to C# code? Do I need a third party tool or can I do it directly in Visual Studio?

  • Verified answer
    Martin Dráb Profile Picture
    237,965 Most Valuable Professional on at

    You would need a third-party tool such as ILSpy, Reflector or JustDecompile. Microsoft provide only a decompiler from binaries to CIL.

  • Refshauge Profile Picture
    277 on at

    Thanks

  • Community Member Profile Picture
    on at

    Hi Brian,

    We faced similar issue and we are running out of option to get back the code. 

    Did you solve this issue? How you overcome the lost codes?

  • Refshauge Profile Picture
    277 on at

    Hi Dian.

    Well i did all the code once more and took in the learning.

  • Community Member Profile Picture
    on at

    Hi Brian,

    Thanks for your quick reply. Although I hoped that you gave good news. But thanks.

  • André Arnaud de Calavon Profile Picture
    301,075 Super User 2025 Season 2 on at

    Hi Dian,

    Sorry to read you had the same experience. I do hope you are now ensuring to have source control in place which can prevent the loss of coding.

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