12

I need to set the following argument as the Default VM Arguments in Eclipse

-javaagent /Developer/aspectj-1.6/aspectjweaver.jar

When I add the line and run my code, it gives me the error:

Unrecognized option: -javaagent
Could not create the Java virtual machine.

How do I fix this ?

4

1 回答 1

21

和 JAR 之间需要一个冒号 ( :) -javaagent,而不是空格。例如:

-javaagent:/Developer/aspectj-1.6/aspectjweaver.jar
于 2013-07-31T23:43:47.010 回答