I'm compiling AX 2012 R2 CU7 with (almost) latest kernel using AxBuild and it always finds the error ("Cannot add or remove static keyword for this method.") in a custom static method (in a custom class).
The code looks all right, nevertheless even icon in AOT and the tooltip looks like if the method wasn't static.
Recompiling the objects manually resolves the problem. Also running compilation through the startup command shows that there is no compilation error.
I start with a completely clean environment, import code from TFS and run the compilation, therefore it isn't a development environment where somebody might have recently changed the method to static.
Didn't you anybody see it before?
As I can reproduce it reliably, I'll report it to Microsoft if it's not a known issue.
*This post is locked for comments
Thank you for letting me know.
I originally wanted to log it as a support request, but for some reasons it ended up on Connect.
Martin,
We have seen the same issue before and we tried to report it to Microsoft, but we never succeeded to create a reliable repro.
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,188 Super User 2024 Season 2
Martin Dráb 230,030 Most Valuable Professional
nmaenpaa 101,156