• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Custom Ant Task Issue

 
Ranch Hand
Posts: 47
Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I have created my own custom task for Ant as follows:



I have placed the following ant build file in the same folder where this java class file is kept:



However, on executing it gives the error "taskdef class com.ant.AntTest cannot be found". I know it's a classpath issue but how do I fix it? Please note that this is my first ant hands-on.

Thanks in advance.

Ankit
 
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
[copy] placed the following ant build file in the same folder where this java class file is kept[/copy]
The base build directory is not automatically in the classpath. You need to add a classpath or classpathref to your taskdef and reference the JAR file (or base directory) containing your task class.

reply
    Bookmark Topic Watch Topic
  • New Topic