Pergunta

I am trying to generate the files using wsimport and i am getting the above error. I have done the following steps:

1) JAVA_HOME -set to C:\Program Files\Java\jre7 2) c:\Desktop\Temp>wsimport http://www.w3schools.com/webservices/tempconvert.asmx?WSDL -extension -keep running the above command results in error.

I have also tried appending /bin to the JAVA_HOME but it does not remove the error.

Foi útil?

Solução

You need a JDK, not JRE. XJC is not a part of JRE bin.

JAVA_HOME variable does not include bin:

JAVA_HOME=C:\Programme\Java\jdk1.6.0_29

However PATH should include %JAVA_HOME%\bin.

Outras dicas

This is where my jdk is, works for my system:

Go to My computer >> right click and select properties. On the properties tab select Advanced system settings (Windows 7) Click enviroment variables select path and click edit option add ";C:\Program Files\Java\jdk1.7.0_60\bin" at the end. Done.

This fixed my problem:

If you are 100% sure that everything is set-up.Try to close cmd and reopen it. It should start recognizing it.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top