nirtheking
New member
בעיית IO
אני רק בהתחלה של הנושא וכבר אני לא מצליח לעשות לפי הדוגמא שבספר(the java tutorial בעברית)
זה קוד המקור:
אני רק בהתחלה של הנושא וכבר אני לא מצליח לעשות לפי הדוגמא שבספר(the java tutorial בעברית)
package ch09; import java.io.*; public class Copy { public static void main(String[] args) throws IOException { File inputFile = new File("ch09/farrago.txt"); File outputFile = new File("ch09/outagain.txt"); FileReader in = new FileReader(inputFile); FileWriter out = new FileWriter(outputFile); int c; while((c=in.read())!=-1){ out.write(c); } } }
משום מה לא נכתב לי אפילו נתון אחד בקובץ outagain מתוך farrago וזה יוצר לי קובץ ריק מה אני יכול לעשות ? נ.ב ה-IDE שלי (אקליפס) מחזיר שגיאה שאני מנסה להריץ את הקובץ דרכו אבל ה-CMD לא. הוא כותב לי: Error exist in a required project. בתודה ניר