12 Şubat 2016 Cuma
15 Ocak 2016 Cuma
14 Ocak 2016 Perşembe
11 Aralık 2015 Cuma
31 Ekim 2015 Cumartesi
Javada FileChooser kulanımı:
public static File dosyayiSec(String path) {
JFileChooser chooser = new JFileChooser(path);
chooser.setDialogTitle("Browse Directory");
chooser.setSize(new java.awt.Dimension(45, 37)); // Generated
chooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);
chooser.setAcceptAllFileFilterUsed(false);
File file = null;
if (chooser.showOpenDialog(null) == JFileChooser.APPROVE_OPTION) {
file = chooser.getSelectedFile();
System.out.println("getCurrentDirectory(): " + chooser.getCurrentDirectory());
System.out.println("getSelectedFile() : " + chooser.getSelectedFile());
} else {
System.out.println("Seçim işlemi ");
}
return file;
}
public static File dosyayiSec(String path) {
JFileChooser chooser = new JFileChooser(path);
chooser.setDialogTitle("Browse Directory");
chooser.setSize(new java.awt.Dimension(45, 37)); // Generated
chooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);
chooser.setAcceptAllFileFilterUsed(false);
File file = null;
if (chooser.showOpenDialog(null) == JFileChooser.APPROVE_OPTION) {
file = chooser.getSelectedFile();
System.out.println("getCurrentDirectory(): " + chooser.getCurrentDirectory());
System.out.println("getSelectedFile() : " + chooser.getSelectedFile());
} else {
System.out.println("Seçim işlemi ");
}
return file;
}
Kaydol:
Kayıtlar (Atom)