Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8003399

JFileChooser gives wrong path to selected file when saving to Libraries folder on Windows 7

    XMLWordPrintable

Details

    • b68
    • windows_7

    Backports

      Description

        Steps to reproduce:

        - Open plain JFileChooser e.g. like this:
                JFileChooser fc = new JFileChooser();
                if( JFileChooser.APPROVE_OPTION == fc.showSaveDialog( this ) ) {
                    File selFile = fc.getSelectedFile();
                    System.err.println( selFile.getAbsolutePath() );
                }

        - select 'Libraries' in file chooser's combo box
        - then double-click 'Pictures'
        - type any new file name, e.g. 'aaaaa.txt'

        The selected path provided by the file chooser will be something like:

        D:\temp\JavaApplication19\::{031E4825-7B94-4DC3-B131-E946B44C8DD5}\Pictures.library-ms\aaaaa.txt


        See also this NetBeans issue: http://netbeans.org/bugzilla/show_bug.cgi?id=219837

        Attachments

          Issue Links

            Activity

              People

                ssadetsky Semyon Sadetsky (Inactive)
                saubrech Stanislav Aubrecht
                Votes:
                0 Vote for this issue
                Watchers:
                9 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: