Folders that having non-ascii chars are not displaying on MAC using JFileChooser

On MAC OS X 10.8.2, I have latest Java 1.7.25 installed. When I run my simple java program which allows me to browse the files and folders of my native file system using JFileChooser, It does not show the folders that having non-ascii char in there name. According this link, this bug had been reported for Java 7 update 6. It was fixed in 7 Update 10. But I am getting this issue in Java 1.7.21 and Java 1.7.25.
Sample Code-
{code}
public class Encoding {
public static void main(String[] arg) {
try {
//NOTE : Here at desktop there is a folder DKF}æßj having spacial char in its name. That is not showing in file chooser as well as while is trying to read for FILE type, it is not identify by Dir as well as File - getting File Not Found Exception
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
} catch (IllegalAccessException ex) {
Logger.getLogger(Encoding.class.getName()).log(Level.SEVERE, null, ex);
} catch (UnsupportedLookAndFeelException ex) {
Logger.getLogger(Encoding.class.getName()).log(Level.SEVERE, null, ex);
} catch (ClassNotFoundException ex) {
Logger.getLogger(Encoding.class.getName()).log(Level.SEVERE, null, ex);
} catch (InstantiationException ex) {
Logger.getLogger(Encoding.class.getName()).log(Level.SEVERE, null, ex);
JFileChooser chooser = new JFileChooser(".");
chooser.showOpenDialog(null);
{code}

Hi,
Did you try this link - osx - File.list() retrieves file names with NON-ASCII characters incorrectly on Mac OS X when using Java 7 from Oracle -…
set the LANG environment variable. It's a GUI application that I want to deploy as an Mac OS X application, and doing so, the LSEnvironment setting
<key>LSEnvironment</key> <dict> <key>LANG</key> <string>en_US.UTF-8</string> </dict>

Similar Messages

  • Can Java be started in a directory that contains non ascii char

    I installed a product developed using Java in a folder whose name contains non-ascii chars, such as Japanese chars or german chars.
    This will cause error said: unable initialise java virtual machine, error code -1
    Some one said Java doesn't like being started in a directory that contains non ascii characters. There appears to be no way of passing it unicode parameters.
    Is there anyone once hit the similiar issue or know the root cause of such problem?
    Thanks

    Yes you can use your web start application console. To enter data which is required for your application it is better idea to use java application which runs in console mode althou you may try to run console of windows and then read data from its input stream.

  • UploadedFile and filenames with non-ascii chars

    Hi
    I'm using an UploadedFile object in my web app, and all works fine. However, when I try to upload a file, with a filename containing non-ascii chars (e.g. Spanish), I see that the getBytes method returns an empty byte array, the filename is not stored correctly (the non-ascii chars are lost, replaced by another representation), and that the content-type is application/octet-stream instead of image/png as supposed to be.
    If I rename that same file to have only ascii chars - everything is back to normal.
    How can I upload files with non-ascii chars in their name?

    Hi, back! Spent a few hours experimenting and found
    that everything is working great (including the creation
    of international non-ASCII foldernames) when I used
    utf-8 encoding in the sieve filters rules for the
    the match strings and the folder names... at least
    so far so good... for your ref and sorry for bothering.

  • With IE UIX buttons are not displayed correctly

    Hello there,
    We have developed an application using UIX. While browsing application using Internet Explorer I noticed that many of the buttons are not displayed correctly. Only some part of the button is displayed. Same thing happens while displaying some of the page logos and stuff. Did anyone have same problem? What's solution?
    Thanks,

    Hi Andy,
    sometimes half of button is displayed and sometimes the whole button image is distorted. if you refresh the page, it becomes perfectly fine. sometimes nothing is displayed but if you put mouse at the place where there should be a button, you would know that there is a button...
    it happens with random buttons...
    i haven't seen this problem in mozilla. its quite frequent in IE.
    our customer is very annoyed by this problem :(

  • SAP Webdispatcher :Images are not displayed after using the URL filtering

    Hello,
    I have installed the SAP webdispatcher 7.3 on Linux redhat 5.4 in front of the Portal 7.3.
    I wanted to restrict the access just for the IRJ prefix so for this i used the parameter wdisp/permission_table = PermFile
    with Permfile as follows:
    #Denial of the useradmin URL from the WebDispatcher
    P /irj*
    P /irj/*
    The filtering is working well except that for IRJ the images are not displayed so i was using so i added the following line to disply the images to the logon page
    icm/HTTP/auth_
    P /logon_ui_resources/*
    P /logon_ui_resources*
    but i still have the same issue for the irj page where no icons are displayed and i can do nothing.
    The same issue also happened when using the icm/HTTP/auth_xx
    Do you have an idea how to deal with this issue?
    Thanks in advance;
    Hassan

    Hello,
    After checking the HTTP code of the irj page on IE,  i foud the needed URL to permit so i modified the permision table and it works fine for the moement
    P /irj*
    P /irj/*
    P /logon_ui_resources/*
    P /logon_ui_resources*
    P /AFPServlet/*
    P /AFPServlet*
    P /com.sap*
    P /com.sap/*
    P /webdynpro/resources*
    P /webdynpro/resources/*
    Thanks for you help,
    Hassan

  • Downloads are not displayed in window. I did change then change back destination folder.

    A window opens when files are downloaded but the file(s) are not displayed. They used to be

    See Tools > Options > Privacy > History: "Remember download history"
    To see all the History and Cookie settings, select: Tools > Options > Privacy > History: Firefox will: "Use custom settings for history"

  • FILE_DATASTORE and non-ASCII chars

    I have created an interMedia Text index
    with the FILE_DATASTORE option, so that
    interMedia treats table entries as
    filenames and indexes the corresponding
    file on the servers's filesystem.
    But whenever the filename contains characters
    which are not part of the US7ASCII charset (like dv| _), the file is not found. But both Oracle and the operating system support these characters.
    The Oracle instance uses UTF8 as internal
    characterset. The client which stores
    the filenames in the table uses the
    WE8ISO8859P1 charset. The values in the
    database table are stored and shown correctly
    when viewed with Oracle or Java client
    programs.
    So where does the charset conversion fail ?
    The names are stored correctly, they can be
    read correctly by clients, but the indexer
    seems to use a wrong charset to translate
    the filenames stored in the database into
    filenames of the operating system.
    Do I have to apply some additonal configurations to my indexer ?
    Greetings,
    Michael Skusa
    null

    I bump Dr. Chucks thread for a similiar problem with non-ascii chars.
    The chars show up but the sorting is a bit off.
    Example: A, Å, B, ... Z
    Should be: A, B, ... Z, Å, Ä, Ö
    In Swedish Å (the letter Aring;) is one of the last letters and should not be placed after A despite being similiar.
    Any ideas?

  • Non-ASCII chars in applets?

    hi,
    Spent 4 hours to find a way to use non-ASCII chars in applets (buttons, textareas), but didn't make it.
    Simply saying
    TextFieldObj.setText("\uxxxx");
    //or any equivalent obj. Ex. of \uxxxx: \u015F
    doesn't work. I even went into Graphics.paint() example, but it too can paint only ASCII chars.
    My hunch is that it is smt. about Character.Subset but i still can't figure out how to do it.
    Please SOS,
    Reshat.

    Hi,
    I just managed to get Buttons to show Greek characters, so it appears that static buttons are fine.
    However, i still face the same problem for TextField's:
    TextFields work fine for IE, but in NN they sometimes convert into ASCII and sometimes give ? The same in HotJava.
    So there are 2 questions in my head:
    1. why can't NN use the fonts used by IE to display Non-ASCII chars?
    2. What is the safest font to use for Non-ASCII chars, to cover the widest possible audience.
    P.S. Java solves most cross-platform-browser problems, but the font issue still seems to be dependent on a user and his/her browser. It appears Java is not font-independent in non-ASCII context. If so, it would be nice to develop a plug-in to make sure that if the user doesn't have the font, then a Java-standardized Unicode-based font is used. Otherwise, non-ASCII world is still w/o a real Java.)
    Thank you for your feedback,
    Reshat.

  • How Aperture encodes non-ascii chars

    It looks like Aperture uses a way of encode chars as UTF that seem to be bit unusual, many application (especially web apps) expects another way of encoding Unicode chars. The end result is that non-ascii chars comes out really strange.
    When I use applescript to read the IPTC info I need to do something like this before using the data:
    set c_title to normalize unicode p_title without decomposition
    Is there some way of telling Aperture to do this automatically when exporting photos?
    (sorry about the bad use of Unicode terminology but I don't know the area very well)

    I've spent quite a bit of time on this topic - I'm the author of Phoshare http://code.google.com/p/phoshare/, an open-source tool to export images and metadata from iPhoto and Aperture. Storing non-ASCII characters in image metadata is a messy business. If you want to get a taste of it, have a look at the Exiftool FAQ at http://www.sno.phy.queensu.ca/~phil/exiftool/faq.html#Q10 . A quote: "Most textual information in EXIF is stored in ASCII format, ... However *it is not uncommon for applications to write UTF‑8 or other encodings where ASCII is expected*". This leads to all sorts of problems, because the reader will have to make assumptions about the encoding used by the writer.
    In the case of Aperture, I have found that it writes metadata encoded in a way consistent with what most other applications and on-line services expect. Most of the encoding problems I've debugged where caused by bad input data. E.g. the characters were encoded improperly to begin with, but in a way that they still display as expected in some places (like Aperture). Can you try erasing some of the meta data in Aperture, and retype them from scratch (e.g. not copy-paste, which would paste the same stuff right back). Also make sure that you force-updated the preview images, so that the new meta data get written into the files.

  • Java 5, Linux, 64-bit: Non-ASCII chars over socket

    Hi,
    I am having issues with reading non-ASCII chars from a socket. I send a mixed message, with the first part in ASCII and the last bit in non-ASCII. There are no issues with reading the non-ASCII characters on Windows. However, when I try running the server on Linux. The following is a message sample:
    Start message<CRLF>
    &#1092;&#1074;&#1072;&#1092;&#1099;&#1074;&#1072;&#1092;&#1074;&#1099;&#1072;&#1092;&#1099;&#1074;<CRLF>
    The second part (which is encoded in either Windows-1250 or KOI8-R), comes out as 3F (when you look at the bytes) on Linux.
    Any suggestions?
    Thanks,
    Max

    You must be using Readers and Writers, and you need to make sure you specify the same charsets when constructing them. Don't leave this to the default, as this seems to vary across platforms and definitely has varied across releases.

  • IPhone: sectionIndexTitlesForTableView and non-ASCII chars

    You specify an array of strings for your section titles in your implementation of UITableViewDataSource method sectionIndexTitlesForTableView. However, it seems like if you have a string with non-ASCII characters, it is left blank (for example the Korean string "누리마루"). Anybody else encounter this issue?

    I bump Dr. Chucks thread for a similiar problem with non-ascii chars.
    The chars show up but the sorting is a bit off.
    Example: A, Å, B, ... Z
    Should be: A, B, ... Z, Å, Ä, Ö
    In Swedish Å (the letter Aring;) is one of the last letters and should not be placed after A despite being similiar.
    Any ideas?

  • Child DC cannot Replicate to Parent DC, because of connection errors. MS PortQryUI shows that ports 3268 and 3269 are not listening,

    I started a support case with Microsoft to help me with raising the our domain Forest level because i received a message stating that there were Windows 2000 PDC still listed in the database. These PDCs were removed years ago. The tech saw all of the problems
    i was having with domain replication so that is where he started. running the MS PortQryUI shows that ports 3268 and 3269 are not listening, (TCP port 3268 (unknown service): NOT LISTENING) when run FROM a Child domain controller against the Parent
    Domain controller. Between the 2 Child domain controllers these ports are listening.
    The Windows firewall is not running on any of the controllers, i removed a virus protect client from all of the servers, although i didn't enable the firewall there either, but these ports are still not listening on the Parent DC.
    I need help debugging this. I am not very familiar with network sniffers so if i need to run one i'll need some guidance. This DC only has one NIC, all IP addresses are static, all servers are setup like this. All servers are in the same subnet, on the same
    lan, on the same cisco switch, there shouldn't be anything blocking this port from starting.
    I looked over other post that show this same problem, but they don't give a solution. If i am not using the Windows firewall why wouldn't these ports be open?
    Any ideas? web searches are all over the map on trying to find the reason for this.
    Bobby

    Try running the below command on the DCs that you think have the ports blocked or all the DCs.
    netdiag /test:ipsec /debug > c:\dcname-ipseclog.log
    Open that from the C drive and see if there is anything saying block or filters. 
    Also, just for kicks have you disabled the firewall service on the DCs? 
    And just for kicks have you tried enabling firewalls ports on all the DCs?  The KB is below
    http://support.microsoft.com/kb/555381/en-us
    Step 1 - netdiag results
    Step 2 - disable the firewall service on all DCs if step 1 was negative
    Step 3 - enable the firewalls on all DCs per KB 555381 if step 2 doesn't work
    Let us know how it goes!
    If it answered your question, remember to “Mark as Answer”.
    If you found this post helpful, please “Vote as Helpful”.
    Postings are provided “AS IS” with no warranties, and confers no rights.
    Active Directory: Ultimate Reading Collection

  • Non-whitespace characters are not allowed ...

    I'm trying to parse the following XML fragment into a DOM Document object:
    <CNetSpecs><section name="General
    "><spec name="Printer Type
    ">Personal printer - ink-jet - colour
    </spec><spec name="Weight
    ">6.4 kg
    </spec></section><section name="Printer
    "><spec name="Print Speed
    ">Up to 15 ppm - black draft ? Up to 15 ppm - colour draft ? Up to 0.65 min/page - photo best - 101.6 x 152.4 mm ? Up to 1.28 min/page - photo best - 203 x 254 mm
    </spec><spec name="Built-in Devices
    ">Preview screen
    </spec><spec name="Max Resolution ( B&W )
    ">5760 dpi x 1440 dpi
    </spec><spec name="Max Resolution ( Colour )
    ">5760 dpi x 1440 dpi
    </spec></section><section name="Software / System Requirements
    "><spec name="OS Required
    ">Microsoft Windows 98 Second Edition / Windows ME, Apple MacOS X 10.1, Apple MacOS X 10.2, Microsoft Windows 2000 / XP, Apple MacOS 8.6 - 9.2
    </spec></section></CNetSpecs>The fragment is pulled out of a text field in a database.
    The code I'm using to do the parseing is:
    // Parse the CNet XML into a proper doc.
    DOMParser parser = new DOMParser();
    parser.parse(new InputSource(new StringReader(cnetSpecs)));
    org.w3c.dom.Document cnetXml = parser.getDocument();
    xmlUtil.toFile(cnetXml, "/tmp/cnetxml.xml");
    NodeList cnetRoot = cnetXml.getElementsByTagName("CNetSpecs");
    Node CNetStatsNode = xml.importNode(cnetRoot.item(0), true);
    root.appendChild(CNetStatsNode);and I get the following errors:
    [Error] :1:107: s4s-elt-character: Non-whitespace characters are not allowed in schema elements other than 'xs:appinfo' and 'xs:documentation'. Saw 'Personal printer - ink-jet - colour'.
    [Error] :1:150: s4s-elt-character: Non-whitespace characters are not allowed in schema elements other than 'xs:appinfo' and 'xs:documentation'. Saw '6.4 kg'.
    [Error] :1:391: s4s-elt-character: Non-whitespace characters are not allowed in schema elements other than 'xs:appinfo' and 'xs:documentation'. Saw 'Up to 15 ppm - black draft ? Up to 15 ppm - colour draft ? Up to 0.65 min/page - photo best - 101.6 x 152.4 mm ? Up to 1.28 min/page - photo best - 203 x 254 mm'.
    [Error] :1:452: s4s-elt-character: Non-whitespace characters are not allowed in schema elements other than 'xs:appinfo' and 'xs:documentation'. Saw 'Preview screen'.
    [Error] :1:528: s4s-elt-character: Non-whitespace characters are not allowed in schema elements other than 'xs:appinfo' and 'xs:documentation'. Saw '5760 dpi x 1440 dpi'.
    [Error] :1:603: s4s-elt-character: Non-whitespace characters are not allowed in schema elements other than 'xs:appinfo' and 'xs:documentation'. Saw '5760 dpi x 1440 dpi'.
    [Error] :1:847: s4s-elt-character: Non-whitespace characters are not allowed in schema elements other than 'xs:appinfo' and 'xs:documentation'. Saw 'Microsoft Windows 98 Second Edition / Windows ME, Apple MacOS X 10.1, Apple MacOS X 10.2, Microsoft Windows 2000 / XP, Apple MacOS 8.6 - 9.2'.Can anyone point me in the right direction? I've been scratching my head all day.

    I dont think so that it is because of un-escaped "&" character or breaking line sequences.
    As in mine case it is giving for XML as below:
    <?xml version="1.0" encoding="UTF-8"?>
    <publicationManifest date="03/13/2007 14:06:25">
    <contentItem action="add" expireDate="" releaseDate="" revision="1">
    <content>This would go under webstore</content>
    <metadata>This would go for Database</metadata>
    </contentItem>
    </publicationManifest>
    and console output at java IDE is
    [Error] item-manifest_Test.xml:4:46: s4s-elt-character: Non-whitespace characters are not allowed in schema elements other than 'xs:appinfo' and 'xs:documentation'. Saw 'This would go under webstore'.
    [Error] item-manifest_Test.xml:5:45: s4s-elt-character: Non-whitespace characters are not allowed in schema elements other than 'xs:appinfo' and 'xs:documentation'. Saw 'This would go for Database'.
    Therefore , if anyone had found the root cause of this discrepancy please update this topic.

  • My folders in my I-Phone are not displaying or populating.....How may I fix it?......

    My folders in my I-Phone are not displaying or populating.....How may I fix it?......

    What type of account is it?  If POP and you just setup, then yes that is all you will see.  Once you send, you will get sent times.  Once you delete you will get trash.

  • Does Java 5 accept non-ascii chars as identifiers?

    I am surprised to find out that Java 5.0 accept non-ascii chars as identifiers.
    Is it true that Java 5 really accept non-ascii chars?
    Thanks.

    Here is the code:
    public class non��������name {
      private static void ��������(){
        System.out.println("this is called from a function with a chinese name!");
        int ����1 = 1, ����2 = 2;
        System.out.println("����1 = " + ����1 + ", ����2=" + ����2 + ", �� = " + (����1+����2));
      public static void main(String[] args) {
        ��������();
    }

Maybe you are looking for

  • Why won't logic read my guitar??

    I have input 1 set to instrument.  I've tried every combination of phase invert and phantom power (although i dont even know what those things are) and my guitar still won't read.  Fresh batteries, volume turned up.  I've tried all diff settings on m

  • Posting keys for account determination for transaction do not exist

    Dear SAP Gurus, While release to accounting service sale billing bellow error occurs while i made all necessary changes in VKOA. Posting keys for account determination for transaction do not exist Please guide me to coorect this error. With Regards M

  • Locking objects across RFC calls

    Hi All, I am developing a business application using SAP UI5 and the NetWeaver Service Gateway in an embedded scenario. I have RFCs build for the backend interaction. As per my knowledge, each RFC is considered as a separate transaction and the user

  • The mute box is checked and grayed out so that I cannot uncheck it. How do I get my sound back?

    The mute box is checked and grayed out so that I cannot uncheck it. How do I get my sound back?

  • Getting my iTunes back...

    Itunes kept giving me an error message and would not start up...so I uninstalled it and have tried multiple times to reinstall it on my computer.  I still don't have an icon that I can get into it on.  Any hints?