LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-27-2009, 02:12 PM   #1
DanaBrown
LQ Newbie
 
Registered: Jul 2008
Posts: 3

Rep: Reputation: 0
Images, Java, and Linux


Hi all,

I have written a java application which displays an image via the ImageIcon class.

It works fine on my Windows machine, but now that I try to execute the same program on a linux machine the image doesnt show up. I changed the location of the image when I made the switch from Windows to Linux, so that is not the problem. Also, the image is a jpg.

If anyone has any ideas, itd be much appreciated.
 
Old 04-27-2009, 02:27 PM   #2
vitalstrike82
Member
 
Registered: Oct 2007
Location: Singapore
Distribution: OpenSuse, Slackware, Redhat
Posts: 318

Rep: Reputation: 40
hi,
have you check if the path to the jpg image is correct? Windows and Linux has different path statement to the specific file.

eg: for windows is c:\\directory\pic.jpeg, linux will be /home/user/pic.jpg

And lastly Windows use backslash in their paths. Unix and others use forward slash
 
Old 04-27-2009, 02:32 PM   #3
DanaBrown
LQ Newbie
 
Registered: Jul 2008
Posts: 3

Original Poster
Rep: Reputation: 0
I guess the problem was just that the extension was in all capitals and linux cared whereas windows did not.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
background images in java applications - HELP ohfaney Programming 3 06-14-2006 04:19 PM
importing images into java, and problems with my arrays ohfaney Programming 2 06-14-2006 09:26 AM
Transmit images between 2 Java applications Elec490 Linux - General 1 04-16-2005 10:10 AM
Images on Java poeta_boy Programming 3 03-03-2004 01:29 AM
best way of handling images in Java secprovider Programming 1 09-22-2003 05:22 PM


All times are GMT -5. The time now is 08:26 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration