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)

Full CIL generation Error @ AX 2012 R2:

(0) ShareShare
ReportReport
Posted on by 1,006

Hi - Having this errer when running full CIL. Has any body an idea to get rid of it?

System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.

Parameter name: index

 at System.Collections.Generic.List'1.get_Item(Int32 index)

 at Microsoft.Dynamics.Ax.Xpp.ILGenerator.loadFieldsIL(TypeBuilder typeBuilder)

 at Microsoft.Dynamics.Ax.Xpp.ILGenerator.declareFields()

 at Microsoft.Dynamics.Ax.Xpp.ILGenerator.GenerateXppModule()

 The CIL generator found errors and could not save the new assembly.

 regards
Beat
 

 

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Tommy Skaue Profile Picture
    Moderator on at

    You can investigate the details around the error by finding the CIL compilation error log under \Program Files\Microsoft Dynamics AX\60\Server\YOUR_INSTANCE\bin\XppIL\Dynamics.Ax.Application.dll.log

    Given your AOT compiles without errors, CIL should compile. Sometimes there are dependent assemblies not being loaded correctly, which means either the service or the client needs a restart to pick them up.

  • ARPIT CHAVHAN Profile Picture
    4,359 on at

    Hi Beat,

    I can tell you what I observe during CIL generation. It will run succesfully only when you dont have any error in your AOT. First see to it that the development you have done doesnot have any error left and then try to run CIL again.

  • Verified answer
    Beat Profile Picture
    1,006 on at

    It is solved. Even full compile (right click on top node in AOT and select coompile) run without any error - log prooved -. When i compiled tables or classes only it showed errors on several baseEnum. Fixing these - CIL generation was possible.

  • Husna Yusuf Profile Picture
    1,094 on at

    Hi Beat,

    btw, can you describe how to solve this problem? ...

    i've got same error with you.

    Thank you very much.

    Regard,

    Husna

  • Suggested answer
    Beat Profile Picture
    1,006 on at

    Hi Husna, this error is based on using an enum value that does not exists at the enum anymore. I did not see this error on a full compile. What i did i compile the table tree, then class tree on its own. Then a compile error was shown. I then fixed it. After this i could generate the CIL.

  • Suggested answer
    ArunGarg Profile Picture
    3,926 on at

    Hi,

    Please follow the below steps:

    1. Stop the AOS.

    2. Delete all of the source in the C:\Program Files\Microsoft Dynamics AX\60\Server\InstanceName\bin\XppIL directory.

    3. Start the AOS.

    4. Perform a Full CIL.

    5. Perform a Incremental CIL.

    Thanks & Regards

    Arun

  • Suggested answer
    Tommy Skaue Profile Picture
    Moderator on at

    You should be good by simply doing a full AOT compile, synchronize Data Dictionary and finally do a full CIL generate.

    Deleting the content in XppIL and/or the SysXppAssembly-table is a last resort and more often a symptom for an unstable development environment.

    Occasionally, you also need to restart the AOS/Client for it to pick up on potential new assemblies being completed on the first compilation iteration, but so far I've only seen that with third-party solutions.

  • Husna Yusuf Profile Picture
    1,094 on at

    guys,

    now my machine running compile on AOT,... take a long time.ill get back to you later guys, and inform the result.

    Terimakasih.Thank you very much.

    Regard,

    Husna

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