Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics AX forum
Suggested answer

Ax2012 Compile RunBaseBatch Class to CIL Error

Posted on by Microsoft Employee

Hi,

Is there anyone know what is the problem and how to compile the class to CIL successfully? Btw, where is the CIL stored localtion?
I created a class which can submit for batch processing. When compile in Ax no error. But unable to compile to CIL. Then can't run the class job using Batch processing. Always prompting error with no solutions.

Below are the error messages when going through the process from compiling to CIL and run Batch job for the class.

CIL compilation error message:-
\xppIL  ERR:351
"The CIL generator found errors and could not save the new assembly."

Batch job process error messages:-
Unable to construct and object from the class XXXXX in the batch framework. Make sure that the X++ has be compiled to Microsoft .Net Framework..........
Microsoft.Dynamics.Ax.Xpp.ErrorException of type 'Microsoft.Dynamics.Ax.Xpp.ErrorException' was thrown.......

Thanks in advance. 

 

  • Suggested answer
    Ali Zaidi Profile Picture
    Ali Zaidi 4,657 on at
    Re: Ax2012 Compile RunBaseBatch Class to CIL Error

    While positing sales order I got following exception.

    Exception of type 'Microsoft.Dynamics.Ax.Xpp.ErrorException' was thrown

    On event log on Server OSA, I found following message.

    Object Server: RPC error: RPC exception 1702 occurred in session 8 process is Ax32Serv.exe thread is 19640 (User: username, ClientType: Worker)

    For Correct the problem, I recompile the CIL via System Administration Periodic  Compile into CIL NET Framework and restart the AOS needed.

  • Suggested answer
    Community Member Profile Picture
    Community Member Microsoft Employee on at
    Re: Ax2012 Compile RunBaseBatch Class to CIL Error

    The inkremental CIL compile only discovers new codings.

    If there was an error early in the codings and you deleted the class(or whatever),

    you have to make an full CIL compile.

  • Suggested answer
    Community Member Profile Picture
    Community Member Microsoft Employee on at
    Re: Ax2012 Compile RunBaseBatch Class to CIL Error

    I did a full CIL compile and error has gone now.

  • Suggested answer
    Joris dG Profile Picture
    Joris dG 17,775 on at
    Re: Ax2012 Compile RunBaseBatch Class to CIL Error

    Does the X++ compile finish without errors?

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    Re: Ax2012 Compile RunBaseBatch Class to CIL Error

    Joris,

    Thanks for the reply. I did tried to restart the AOS but still compile with the same error. Only myself will do the development on this server.

    Thank you.

  • Suggested answer
    Joris dG Profile Picture
    Joris dG 17,775 on at
    Re: Ax2012 Compile RunBaseBatch Class to CIL Error

    I've seen this error before and I'm not entirely sure what the cause is. We were able to get past it by making sure nobody is left on the system and restarting the AOS. This happened here when multiple developers were doing several differrent things and it seemed to choke on that.

    As for where the CIL is stored. I'm assuming the "generation" creates temporary files somewhere, and the CIL is in fact stored in the model store in the database. An AOS will actually download the CIL to disk to be able to load them (in the server/bin/vsassemblies). When the CIL changed the AOS will re-download those DLL files (there are rules around when/how etc).

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

Anton Venter – Community Spotlight

Kudos to our October Community Star of the month!

Announcing Our 2024 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Dynamics 365 Community Newsletter - September 2024

Check out the latest community news

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,532 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 228,501 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans