DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

+ Reply to Thread
Results 1 to 3 of 3

Hybrid View

  1. #1
    Join Date
    Aug 2005
    Posts
    2

    deploy jar file + mail api

    I've searched everywhere (sun forums etc etc etc), but nothing seems to work for me:
    I'm using netbeans 4.0, wrote a java program which requires other jar files (eg mail.jar etc). Now I create the executable jar file. Of course it doesn't work since I need to include the Class-path for the jar files (using Windows btw) in the Manifest file. So I open it with WinRar, open the manifest file, make the changes, and now it looks like this:
    Manifest-Version: 1.0
    Ant-Version: Apache Ant 1.6.2
    Created-By: 1.4.2_08-b03 (Sun Microsystems Inc.)
    Main-Class: alfio.Main
    Class-Path: ./javamail/mail.jar
    Class-Path: ./javamail/mailapi.jar
    Class-Path: ./javamail/imap.jar
    Class-Path: ./javamail/pop3.jar
    Class-Path: ./javamail/smtp.jar
    Class-Path: ./javamail/activation.jar
    X-COMMENT: Main-Class will be added automatically by build

    since the jar files are in the same directory than alfio.jar (the executable jar file) in a folder called javamail. However things still don't work
    Urgent help needed, have to hand up this project in two days, and nobody seems to be able to help me.

  2. #2
    Join Date
    Jul 2005
    Location
    SW MO, USA
    Posts
    299
    Have you looked at the doc re how to code the Class-Path atribute in the manifest?
    I see:
    Class-Path: buy.jar sell.jar

    ie there is only one Class-Path line with all the jars on it.

  3. #3
    Join Date
    Aug 2005
    Posts
    2
    thanks a lot, you saved my day/night

Similar Threads

  1. Replies: 1
    Last Post: 07-19-2005, 01:03 AM
  2. Setting a .BAT file to 'Close on Exit'? API call?
    By Chris L. in forum VB Classic
    Replies: 0
    Last Post: 07-31-2001, 12:23 PM
  3. jar file
    By cesar in forum Java
    Replies: 0
    Last Post: 06-28-2001, 03:21 PM
  4. How to use Java to lock a file
    By Cynthia Leslie in forum Java
    Replies: 3
    Last Post: 06-09-2001, 06:43 PM
  5. Replies: 12
    Last Post: 05-18-2001, 04:05 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


Top DevX Stories

Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL


Sponsored Links