Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JTwain not working

 
Devasia Manuel
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am having trouble making JTwain work for my pc, i downloaded the JTwain trial version from he proper website, then in Netbeans, it wont compile if I try to import anything from the jtwain packages. I have added all Jtwain jars to the src folder and to the jre/lib/ext folder, however it is not added to my classpath...

should it work or should i need to add them to my classpath??

Thanks
----Dev
 
Campbell Ritchie
Sheriff
Posts: 48652
56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Go through the documentation for JTwain. Find the Java Documentation home page and click "java" and "javac" and look for the classpath options. It sounds as though using the compiler's classpath options is worth trying, yes.
If it doesn't work, come back here.
 
Ilja Preuss
author
Sheriff
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You probably need to look at the Netbeans documentation to see how a jar file is added to the classpath of a project. Moving to our IDE forum...
 
Devasia Manuel
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Im pretty sure that its not NetBean's problem because I tried the same thing with JCreator and a Notepad and it still didn't allow me...
 
Campbell Ritchie
Sheriff
Posts: 48652
56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So, what is your classpath, and is the JTwain jar in it?
 
Devasia Manuel
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
my classpath is "." and the JTwain.jar file is in my main directory
 
Campbell Ritchie
Sheriff
Posts: 48652
56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The "." classpath means the current directory only; you will have to go through NetBeans and add JTwain to your classpath. Can't remember how to do it, I am afraid.

Also make sure to addJTwain to the .jar file when you distribute your product.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic