Search
 
SCRIPT & CODE EXAMPLE
 

JAVA

java file dialog

FileDialog fd = new FileDialog(yourJFrame, "Choose a file", FileDialog.LOAD);
fd.setDirectory("C:");
fd.setFile("*.xml");
fd.setVisible(true);
String filename = fd.getFile();
if (filename == null)
  System.out.println("You cancelled the choice");
else
  System.out.println("You chose " + filename);
Comment

java file dialog


FileDialog fd = new FileDialog(yourJFrame, "Choose a file", FileDialog.LOAD);
fd.setDirectory("C:");
fd.setFile("*.xml");
fd.setVisible(true);
String filename = fd.getFile();
if (filename == null)
  System.out.println("You cancelled the choice");
else
  System.out.println("You chose " + filename);

Comment

PREVIOUS NEXT
Code Example
Java :: javascript remove specific character from string 
Java :: java remove List null element 
Java :: java lerp 
Java :: java random 6 digit number 
Java :: gravatar default 
Java :: java format 2 decimal places 
Java :: jackson ignore null 
Java :: array to map javax 
Java :: int array to set in java 
Java :: spigot scheduler 
Java :: join array java 
Java :: java remove last character from string 
Java :: read int from keyboard java 
Java :: java jcombobox itemlistener only if value changed 
Java :: java calculate fps 
Java :: arraylist with values java 
Java :: processing draw circle 
Java :: convert base64 to bitmap android 
Java :: java jlabel border 
Java :: android parse date 
Java :: java getdeclaredfield private field 
Java :: java number of days between dates 
Java :: how to change a bukkit chat format 
Java :: consolenausgabe java 
Java :: Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory 
Java :: processing load font from file 
Java :: change color of text in textview android 
Java :: java repeat loop cycle for 
Java :: java socket get ip address of client 
Java :: print hashtable in java 
ADD CONTENT
Topic
Content
Source link
Name
9+1 =