How to call a class in the jar?

I try deploying the wsdd by following command and go to the dir where axis.jar locates which contains AdminClient.java:
java org.apache.axis.client.AdminClient deploy.wsdd

But I got exception as follow:

C:\Projekte\MVNREPO\repo\axis-1_4\axis\1.4>java org.apache.axis.client.AdminClient deploy.wsdd
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/axis/client/AdminClient

My questions:
1. How can I call it correctly?
2. If I don't goto the dir where axis.jar locates but goto the dir where deploy.wsdd locates, how can I call it?
chenweiAsked:
Who is Participating?
 
CEHJConnect With a Mentor Commented:
Please post output of

echo %CLASSPATH%
0
 
CEHJCommented:
You need th full path to the jar in the classpath
0
 
CEHJCommented:
(fROM THERE)

java -cp axis.jar org.apache.axis.client.AdminClient deploy.wsdd
0
Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

 
chenweiAuthor Commented:
I understand what you mean. I did following:

1.
create AXISCLASSPATH which contains all the fullpath of the jars.

2.
Then I create CLASSPATH which has the value of %AXISCLASSPATH%.

Isn't it ok?
0
 
chenweiAuthor Commented:
what I did is ok.

Eventhoug, thanks.
0
 
CEHJCommented:
:-)
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.