Duplicate :
|
|
Duplicate :
|
getSelectedFiles() always return an empty array of files. code snippet: fd.setMultiSelectionEnabled(true); fd.setDialogTitle("Add item(s) into the Project ); int retval = fd.showDialog(new JPanel(),"Add"); if (retval == 0) { selectedFiles =fd.getSelectedFiles(); // here the array is empy }