ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tek1 <>
Subject custom ant task can't find classpath
Date Sat, 06 Apr 2002 12:48:03 GMT
i'm having a problem with one my taskdefs.

the custom task that i've created is basically calling a .class located in 
a .jar and passing it some parameters.

the part of the build.xml file calling my custom task basically looks like this.

     <target name="modifyIt">

         <taskdef name="mytask" classname="com.mycom.MyCustomTask">

                  <pathelement location="/dev/anttasks/mytasks.jar"/>


         <mytask param1="abc" helperJar="/java/helper/123/helper.jar"/>


my custom task is calling the Help.class in the helper.jar.

the command line that is constructed by my custom task ("mytask") and that 
is executed is:

(i'm using windows2000, so all the paths are converted appropriately)

c:\java\j2se\sun\131_02\bin\java.exe -classpath 
c:\java\helper\123\helper.jar Help abc

if i type in this command at the dos prompt, it works.  however, when my 
ant script runs, ant complains that it could not find Help and that i 
should check to see if i have it in my classpath.  i'm getting the same 
error when i try to run my script from within netbeans also...

any advice is greatly appreciated.

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message