I'm trying to add a list of words that a user has taken through a LoginPan input menu and without Do I archive them in a text file? There is already overwriting the txt file for example
bell cool Hello Java compilation
I have the problem that it depends on my writing Does that help me ??
import javax.swing.JDialog; Import java.util.Arrays; Import javax.swing *; Import java.util. *; Import java.io * *; Write public class {public static zero main (string [] args) IOException throws {PrintWriter out = new PrintWriter (aFileWriter); String word = joppenpan.showinputdialog (empty, "enter a word"); Out.print (word); Out.close (); AFileWriter.close (); }} OK now is adding the file but not going to a new line for the new word ??
Open file:
PrintWriter exits = new print-author Add a string to the file:
out.println ("text") (new buffed vter (new fluffer ("outflame", true)); ; Close the file:
out.close (); Better. < / Div>
No comments:
Post a Comment