Spring – I am getting java.lang.NoClassDefFoundError: org/springframework/web/context/WebApplicationContext


I have added spring-web.4.0.jar in classpath. It contains the class – org.springframework.web.context.WebApplicationContext. but when I try to run it in eclipse it shows me an error : org/springframework/web/context/WebApplicationContext.
How to resolve this error?

Best Solution

Choosing "Clean..." from the server contextual menu helped me get rid of this problem.