Find your content:

Search form

You are here

Unexpected Error Occured Compiling Apex Class

 
Share

I'm trying to work through translating a lot of code and getting classes compile and save to server, however, the IDE doesn't report the name/line of a dependent class, instead I get:

Save error: Dependent class is invalid and needs recompilation: 

Which isn't helpful at all, however, I am also now receiving unexpected compilation errors:

Save error: An unexpected error occurred. Please include this ErrorId if you contact support...

Has anyone else received this type of unexpected error when compiling classes, and know what caused it?


Attribution to: jordan.baucke

Possible Suggestion/Solution #1

I've seen this happen, if an update of one class breaks the integrity of another class. Which class is broken is not communicated quite well in the error messages you receive, this could give you a better clue about where to look:

Log in to SFDC and go to setup-->develop-->apex classes and click the "compile all classes" link around the top of the page.


Attribution to: sorenkrabbe

Possible Suggestion/Solution #2

Did you change the name of or delete a method or class variable recently? It may be that there is a class or trigger still pointing to that old name. To check any particular class or trigger, try to save it in Eclipse IDE. You will receive an explicit error that should indicate what's missing. Most likely, you'll immediately know what happened, once you have that info.


Attribution to: Jeremy Nottingham
This content is remixed from stackoverflow or stackexchange. Please visit https://salesforce.stackexchange.com/questions/1662

My Block Status

My Block Content