JFileChooser displays garbage file icons

When running JFileChooser on Win98 with the system look and feel set I get the same garbage icon for every file. I cannot find this in the bug database. I tried submitting a bug report but there seems to be a bug in the bug report web page as it complained that I had omitted essential data when I had not.

You should report it here
http://developers.sun.com/contact/index.jsp

Similar Messages

  • JFileChooser Displays Garbage Icons for Files in 1.4.2-02

    Since switching from 1.3.1 to 1.4.2-02 I no longer get meaningful icons displayed beside file names by JFileChooser. What it is displaying do not look like anything meaningful. I suspect it is just grabbing some random chunk of memory and interpreting it as an icon. In 1.3.1 I got a folder icon for directories and a dog-eared piece of paper for files. I have not changed any of the code here, except to fix a bug where I was passing an invalid object (not a Component) to showOpenDialog, and the problem occurs both before and after that change. I appreciate that I can create a FileView to display whatever icons I want, but I do not understand why the default is garbage.
         JFileChooser chooser;
         String     directory     = parent.getProperty("directory", "");
         if (directory != "")
         chooser = new JFileChooser(directory);
         else
         chooser = new JFileChooser();
         // select only Text and Excel files, but permit multiples to be chosen
         chooser.addChoosableFileFilter(new TxtFileFilter());
         chooser.setFileFilter(new XlsFileFilter());
         chooser.setMultiSelectionEnabled(true);
         // display the dialog and wait for a response
         int option = chooser.showOpenDialog(desk);

    I have since determined that the problem is in FileSystemView.getSystemIcon, which returns a garbage icon on my system.

  • How to display default file icon in Swing listing?

    Hi All,
    I am developing an application where I need to display all the files under a specific folder. But I need to list the files along with their default icon. Also, I need to open that file on clicking (or double clicking) on that file icon.
    I am not able to understand how to do that. I am able to list the files in the GUI, but the rest -- I have no clue how to do it.
    Any help/pointer on how to do that would be great for me.
    Thanks in advance...

    FileSystemView fsv = FileSystemView.getFileSystemView();
    Icon icon = fsv.getSystemIcon(myFile);As for opening a file on the double-click, assuming you're using a JList, just add a MouseListener/MouseAdapter to your list, and respond to the click events:
    public void mouseClicked(MouseEvent e) {
      if(e.getClickCount() == 2) {
        int index = list.locationToIndex(e.getPoint());
        list.ensureIndexIsVisible(index);
        ListModel dlm = list.getModel();
        Object item = dlm.getElementAt(index);
        // Open the file represented by "item".
    }If you need to open the file using the system's default application for that file, use Desktop.open(File).

  • JFileChooser does not display Korean files

    I have an application that uses JFileChooser to select some files. The application is bundled with English version of JRE 1.6.0_06. On Korean Windows 2003 the application displays files with filenames in Korean and allows them to be chosen. However on Korean Solaris 10, it does not even display the files? Anyone have an idea on why there is this discrepancy?
    I assume that the file with the Korean filename created on Korean Windows 2003 got created with the MS949 encoding for the filename. Similarly I assumed that the file with the Korean filename created on Korean Solaris 10 got created with UTF-8 encoding because that's the encoding set on Korean Solaris when I log in (its not set to EUC-KR). So how do I get the files to display and allow to be chosen on Korean Solaris?
    Thanks,
    Kartik
    P. S. I have the same problem with filenames in Japanese - on a Japanese Windows 2003 server the JFileChooser displays the files while on a Japanese Solaris 10 box, the JFileChooser does not display the files.

    Hi,
    I am trying to pick up data from an excel sheet and insert them into a database. However, once updated, they end up with '?' values.
    I have tried to make font.properties.ja as the default font.properties file, which failed to display Japanese characters.
    Any suggestions?
    This is a part of my code:
    String sJIS = "";
    sJIS = new String(cell1.getStringCellValue().getBytes("8859_1"), "JISAutoDetect");
    String sUTF = "";
    sUTF = new String(cell1.getStringCellValue().getBytes(), "UTF-16");
    System.out.println("sUTF" + sUTF + " " + "sJIS" + sJIS);
    Thanks,

  • Blinking file icon with question mark at startup

    my computer sort of froze so i forced restarted it (second time i've done that in its one year lifetime) and when it started back up the screen displayed a file icon with a question mark blinking on and off every two seconds. eventually the fan started humming too. i have since forced restarted it twice with the same results. any ideas on why my darling will not start properly?

    My MacBook Pro did the same thing last night, and I don't think this is good news.
    So far I have:
    -Reset PRAM and PMU
    -Startup from install disks and run Disk Utility. DU doesn't even see the drive! Even Target disk mode doesn't reveal the drive.
    -Archive and install; the installer doesn't see the drive
    None of these worked, and from reading on other disussions, it looks like it is a hareware problem. I will be going to the Applestore this afternoon when I get off of work to see if they can fix it.

  • Displaying File Icons

    I'm a seriously frustrated java newbie. Could someone baby-step me through the following?
    A: how I would display a file's icon (a picture of a folder or a document next to the name of a file in OSX or windows) in my program (larger than the usualy 16x16 icons... OSX does 128x128)
    B: how I would figure that out from java's documentation
    I'm still trying to get a grasp on how to use a given object by reading the documentation. I know max/msp and javascript and I learned both by just poking around the documentation for a few days and then looking something up when I need it.
    JAVA has stopped that pattern dead in its tracks. I don't want to program in java if I need to take a course to learn every java class individually. honestly I'm kind of sad about it. I thought java was going to be fun, but it seems like a beurocratic mess. I'm hoping I just dont get it yet. Any suggestions?
    I'm running 5.0 on osx in xcode 10.4.5 if it matters

    thanks for the reply ChuckBing.
    I will definately plug away at the tutorial.
    I'm also in a java class, (the teacher doesn't like me pestering him ahead of schedule)
    and have my textbook, an ORIELY book and a SAMS book lying around.
    I've had some success with the geticon method, but I can't convert it. but only in labels. Being able to suck an icon into an object seems within on my plain of capability.
    I'll keep working. again thanks
    -matt

  • File icons not displaying in dock folders

    I'm having trouble seeing File icons in the folders added to the dock in Lion. For example I am used to seeing a file icon that isa preview of the file e.g. for a pdf the icon would show the content of that pdf. For many files (but not all) I just see a black box with a white dashed line around it (see image).Eventually these icons may refresh and display properly and if I open the folder in finder the icon is correct but not in stacks. It's not a file type specific issue because in the attached image some jpegs are displaying other are not. Any advice?

    Solved.
    Reset the p-ram.

  • IPAD3/IPAD2 :PDF files/ attachments  sent in an email  displayed inline ( embedded within the main email) in the message text on both my Ipad2 and Ipad three, however the same email displayed the PDF File icons/ attachment on both my Iphone and a friend's

    IPAD3/IPAD2 :PDF files/ attachments  sent in an email  displayed inline ( embedded within the main email) in the message text on both my Ipad2 and Ipad three, however the same email displayed the PDF File icons/ attachment on both my Iphone and a friend’s PC. How do i get both my IPAD devices to display the PDF icons/attachments? Bearing in mind if i open the same email over the internet the PDF Icons/attachments display OK!
    Has anyone come across this? Your advice/help would be most appreciated

    This happens to me all the time.
    If is a one page PDF it seems as though it comes over already open and inline in the body of the email. Multiple page PDF files show as the PDF icon.
    I can't find any official documentation of this - other than based on my own experience with PDF attachments in my various email accounts.
    Message was edited by: Demo

  • Display JPEG files not on desktop as thumbnails, not generic icons

    I understand from previous forum entries that bringing up menu with command-J and checking "show icon preview" will display image files ON THE DESKTOP as thumbnails. This has worked fine for me. However, most of my image files are not on the desktop.
    How do I get the system to display all JPEGs and other images not on the desktop as thumbnails. These are in folders, either on the startup volume or on other volumes.
    My son who is a PC user was surprised that my Mac image folders contained all those generic icons and not thumbnails, like he is used to on his PC.
    Hope there is an easy answer to this, and I greatly appreciate your help.

    I have continued working on this issue since I posed the question, and discovered that I have to have my images in "icon display", not "list display" (which I have usually used).
    When I changed to icon display, the menu from command-j allowed me to display all my icons as thumbnails.
    The menu (command-j) from the list display doesn't give that option, so I was stumped until I stumbled on to this detail.
    Thanks again to all who have helped me in the past on these forums. You're the best.

  • MBP is missing the "Display" icon in Sys Pref, Display PrefPane file needed

    Hi,
    I noticed that my "Display" icon under >Hardware, in the System Preferences is suddenly missing. It should be between "CDs & DVDs..." and "Energy Saver" icons. I think I need the Display Preferences Pane. Can anyone send me a copy, I don't have another Mac to copy it from (except a really old 10 yr imac running System 9). I don't know why it is missing, but I can't calibrate my display without it. The "display.prefpane" file is located under system>library>PreferencePanes. My email address is: melissa (at) melissatobiaart (Dot) com
    If anyone can send me a copy I would greatly appreciate it!

    The file is part of the OS X system therefore it's proprietary to Apple. Furthermore, it's a violation of the Apple Software License to install OS X on more than one CPU at a time (for a single-licensed copy. The Family Pack allows up to five concurrent installations.)
    As the AD belongs to Apple it would be against the Terms of Use for us to enable any of the above. Thus, it's both inappropriate to ask as well as to send.
    That's my interpretation of the software license. You may choose to interpret it differently or even ignore it, but such actions are best left off of the forums.
    I would be more than happy to inquire of the moderators and report back what they suggest.

  • JFileChooser does not display japanese file names

    I am using JFileChooser to load some files in my application. I have some files which have japanese file names. When I try to load these files it does not even display these files for me to choose and then load them. Any ideas?

    Hi,
    I am trying to pick up data from an excel sheet and insert them into a database. However, once updated, they end up with '?' values.
    I have tried to make font.properties.ja as the default font.properties file, which failed to display Japanese characters.
    Any suggestions?
    This is a part of my code:
    String sJIS = "";
    sJIS = new String(cell1.getStringCellValue().getBytes("8859_1"), "JISAutoDetect");
    String sUTF = "";
    sUTF = new String(cell1.getStringCellValue().getBytes(), "UTF-16");
    System.out.println("sUTF" + sUTF + " " + "sJIS" + sJIS);
    Thanks,

  • Dreamweaver CS6 displaying the wrong icon for certain file types

    I recently upgraded to the Maverick and I noticed that my Dreamweaver changed some of my files' icon to Acrobat Reader symbol. This does not represent the actual file type. My most important files, such as mp3 and m4v, are not displaying correctly. My concern is that it is affecting my website. How do I change the icons back to the original file type icons? Much needed help! Thanks!

    What do local file associations have to do with your website? You have a severely wrong understanding of this stuff. Anyway, file associations on Mac can be changed using a right-click and Get Info and then choosing a new default program for the file type.
    Mylenium

  • File Icons display issue

    I am using File.icon property to get the icon bitmap image of
    a file.
    File Icons are not displayed when the operating system
    display property setting is in 16-bit color mode or 24-bit color
    mode. When the display property setting is changed to 32-bit color
    mode file icons is displayed.
    System Configuration:
    Windows XP (SP2)
    1 GB RAM
    INTEL P4, 2.8 GHz Processor Speed.
    AIR Runtime 1.1
    Flash Player 9.0.115.
    Can any one explain that is there any issue with Flash Player
    or AIR runtime?

    It sounds like it may be a bug, which you can report via
    www.adobe.com/go/wish. Providing a sample would be helpful.

  • PSD File Icons don't display in Windows 8.1?

    PSD File Icons don't display in Windows 8.1. How to fix?

    You would have to buy a third party codec for thumbnail displays that Windows doesn't support.
    Ardfry Imaging, LLC
    So why should you have to pay?
    I have many years ago tried to get Microsoft to implement thumbnail support to no avail.
    So in the end, Ardfrey's codec takes care of it for $20, free upgrades and I can get on with any work that requires thumbnails at the OS level.

  • FileSelectPopup function in LabWondows cvi to display the files as icons

    Does anyone know hoe to default the FileSelectPopup in LabWindows CVI to display the files as icons?
    Solved!
    Go to Solution.

    I took a look at this on XP and you're right, the View settings aren't retained. However this is actually an issue with the operating system and not CVI. If you attempt this in Notepad you'll see the same behavior. In Windows 7 (probably Vista too but I didn't test it) this has actually been fixed and the View settings are retained in the Windows File Open dialogs (which is what FileSelectPopup launches internally).
    Kevin B.
    National Instruments

Maybe you are looking for

  • Apple Mobile Device Support fails to install, remains unsolved.

    i came back to the forums after a coupld of months, and this issue is still unsolved, will support please read this and answer us, it seems i am not the only one with such problems. so i will repost this issue here hoping to find a solution. Thank yo

  • Photoshop CC 2014.2.1 not detecting my dedicated GPU

    When I open Photoshop, I get the following error message: "3D features require a minimum of 512MB of vRAM. Photoshop has detected less than that on your system. Updating the driver of your graphics card may resolve the issue." I am running a laptop P

  • Page Validation - Function Returning Boolean - Check for NULL

    I have 3 Page Validations which all fire on "When Button Pressed" = "Submit". <br><br> Number 1 is of type "Item specified is NOT NULL" for "P199_BUSINESS_UNIT1". <br> Number 2 is of type "Item specified is NOT NULL" for "P199_BUSINESS_UNIT2". <br> N

  • Adobe Photoshop Elements 12 Organizer does not load- why?

    I just installed Elements 12 on a machine running Windows 8.1.  Organizer will not load no matter what I do.  How do I make this program work?

  • How to open a file with a specific program

    I would like to do this in applescript instead of the terminal. I would like to pick the application and the file in the same command so to avoid opening a blank document. open -a textedit /Users/mac/Desktop/GNPRC.doc