473,887 Members | 2,374 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Problems exporting an application with Eclipse

2 New Member
Hello all,
Mar 1 '07 #1
4 3534
Bruceski
2 New Member
Hello all,
I wrote an application with eclipse that uses Java3d and Jlayer, which is a simple MP3 player. The application is a demo to help visualize matrices in more than 3 dimensions, and basically is an animation with a series of box structures. I am now finished with the application and am trying to make it into something portable and easily distributed, and I thought the easiest way to do it was producing an executable jar file.

I made a jar file with a manifest using the wizard in Eclipse. But it does not execute when double clicked. I tried to run it via command line to get some debugging, and I have found 2 problems that I am not sure how to resolve.

1. I have a lot of resource files (texture files, mp3's etc) that are used in the application. These are just thrown in the root of the project folder. For running the application within eclipse, I can access these files with just a string name and it works fine, but when I turn the entire project into a jar file and run it via the command line or double clicking it, the resource files cannot be found. How do I link the resource files so they will be accessible within this jar file?

2. I am using two external libraries, java3d and jlayer 1.0. I followed the instructions for inserting these libraries into my project, but it seems that the program can only run if these libraries are inserted into the PATH and/or CLASSPATH for the user and system environment variables. (so the linking inside the project may not be working). I want these libraries to work within the jar file so they don't have to be individually installed on the system.

The Websites:
http://java3d.j3d.org/download.html
http://www.javazoom.net/javalayer/javalayer.html

Its actually a separate situation for each library:

JLayer seems to work fine just being referenced within the eclipse project, but cannot be run from the command line without it being referenced as a system CLASSPATH. With Jlayer I imported a class folder to reference it.

With Java3d it seems that it has to be a system environment variable for it to run either in eclipse or command line. With Java3d there was no class folder, so I referenced and copied the .jar files according to instructions from j3d.org.

I need these libraries to be used within the jar file so users don't have to download the libraries separately.

A possible solution is making this application distributable another way. Any suggestions? I tried an applet originally, but its pretty big (20 megs) and I had trouble implementing it. I also looked in to making an executable shell and Java web start, but with no initial luck.

The source code is available on request, I can post a RapidShare link. This is not for a class, but an independent research project that is non-profit, so any help I get will be properly cited.

I apologize for the length!


Microsoft XP Professional SP 2 2002
Java JRE 1.6.0
Java JDK 1.6.0
Eclipse 3.2
Mar 1 '07 #2
r035198x
13,262 MVP
Hello all,
I wrote an application with eclipse that uses Java3d and Jlayer, which is a simple MP3 player. The application is a demo to help visualize matrices in more than 3 dimensions, and basically is an animation with a series of box structures. I am now finished with the application and am trying to make it into something portable and easily distributed, and I thought the easiest way to do it was producing an executable jar file.

I made a jar file with a manifest using the wizard in Eclipse. But it does not execute when double clicked. I tried to run it via command line to get some debugging, and I have found 2 problems that I am not sure how to resolve.

1. I have a lot of resource files (texture files, mp3's etc) that are used in the application. These are just thrown in the root of the project folder. For running the application within eclipse, I can access these files with just a string name and it works fine, but when I turn the entire project into a jar file and run it via the command line or double clicking it, the resource files cannot be found. How do I link the resource files so they will be accessible within this jar file?

2. I am using two external libraries, java3d and jlayer 1.0. I followed the instructions for inserting these libraries into my project, but it seems that the program can only run if these libraries are inserted into the PATH and/or CLASSPATH for the user and system environment variables. (so the linking inside the project may not be working). I want these libraries to work within the jar file so they don't have to be individually installed on the system.

The Websites:
http://java3d.j3d.org/download.html
http://www.javazoom.net/javalayer/javalayer.html

Its actually a separate situation for each library:

JLayer seems to work fine just being referenced within the eclipse project, but cannot be run from the command line without it being referenced as a system CLASSPATH. With Jlayer I imported a class folder to reference it.

With Java3d it seems that it has to be a system environment variable for it to run either in eclipse or command line. With Java3d there was no class folder, so I referenced and copied the .jar files according to instructions from j3d.org.

I need these libraries to be used within the jar file so users don't have to download the libraries separately.

A possible solution is making this application distributable another way. Any suggestions? I tried an applet originally, but its pretty big (20 megs) and I had trouble implementing it. I also looked in to making an executable shell and Java web start, but with no initial luck.

The source code is available on request, I can post a RapidShare link. This is not for a class, but an independent research project that is non-profit, so any help I get will be properly cited.

I apologize for the length!


Microsoft XP Professional SP 2 2002
Java JRE 1.6.0
Java JDK 1.6.0
Eclipse 3.2
Specify the classpath in the manifest for the jar. See here for how to do that.
Mar 1 '07 #3
r035198x
13,262 MVP
Hello all,
Do not double post
Mar 1 '07 #4
r035198x
13,262 MVP
Also go through this.
Mar 1 '07 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

1
13935
by: steve | last post by:
hi, during a full export of my export of a (Release 9.2.0.4.0 - Production ) database i'm getting the following: I have been thru metalink, and can find nothing that is exactly the same, even though there are similar looking problems relating to export. can anyone point me to finding the objects 25245 &25244, so that i can delete them.
3
3184
by: Alan Krueger | last post by:
Greetings, I've been able to cache Transformer objects in a Tomcat-based servlet application to avoid unnecessary Transformer rebuilding, except for certain ones on certain machines. I'm running Tomcat 4.1.27 under Eclipse 2.1.0 using the Sysdeo Tomcat plugin using j2re1.4.1_02 under Windows 2000 SP4. I've digested this down to a small (albeit convoluted) sample that exhibits the behavior reliably on my development workstation.
2
10077
by: Default User | last post by:
Hi there. I have a few newbie questions. My employer has chosen to use IBM WebSphere Application Server to deploy apps on. As one of my first steps in learning Java/J2EE I need to choose and IDE. Some of the questions I can't figure out are: > Since WSAD (WebSphere Application Developer Studio) is very expensive but based off Eclipse, is it true to say that Eclipse could suffice as an IDE when applications will be deployed on WebSphere...
1
3174
by: Mustufa Baig | last post by:
I have an ASP.NET website where I am showing off crystal reports to users by exporting them to pdf format. Following is the code: ---------------- 1 Private Sub ExportReport() 2 Dim oStream As System.IO.MemoryStream = 3 myReport.ExportToStream( ExportFormatType.PortableDocFormat) 4 Response.Clear() 5 Response.Buffer() = True
22
3007
by: Wildemar Wildenburger | last post by:
To make it short: Is there something like this already? There seem to loads of python frameworks for Web-Apps, but I have a hard time finding one for desktop-apps. I imagine it wouldn't be too hard (if still time consuming) whipping up something simple myself, but I thought, I'd ask here before diving into it. greets wildemar
16
10781
by: Ananthu | last post by:
Hi I dont know how to connect mysql with ECLIPSE in RCP application. Please send me the sample code of connecting mysql sever with ECLIPSE in RCP application. Coding Part: RCP Application Codes: Class ApplicationActionBarAdvisor:
16
2644
by: Lars Uffmann | last post by:
Does anyone have a good suggestion? I am currently using Eclipse Europa with the C-Development Toolkit (plus gnu-toolchain under cygwin) and the Widestudio Native Application Builder plugin. While I am surprised I actually got this configured and running, it has some things that I do not like too much - especially a couple of bugs (build tools vanishing from the builder settings upon switching between projects, for example). And then...
3
6778
by: ravit | last post by:
Hello All, I am trying to execute an application that is developed using eclipse libraries. Jface, SWT , etc. While I execute the application , i have received an exception which I am unable to trace it. TextViewer.setSelection(100,true); is the statement whre it araised. TextViewer is org.eclipse.jface.text.SourceViewer object.
2
3852
by: Kevin G. | last post by:
Hello, I'm exporting an ASP page to Excel using 'Response.ContentType = "application/vnd.ms-excel"' and it is working fine for the most part except the particular page I'm exporting has images, and no matter what style/alignment/etc. that I provide to the <tdtag that contains the <imgtag, it always left-aligns the image in the Excel cell. Has anyone had any success with controlling the alignment of images when exporting from ASP to...
0
9799
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
11173
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10770
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10875
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10432
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7988
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6011
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
4238
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3245
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.