/*需求,拷贝一个图像文件*/
import java.io.*;
public class CopPic {
public static void main(String[] args) throws IOException
{
BufferedReader br=new BufferedReader(new InputStreamReader(new FileInputStream("C:\\Users\\Administrator\\Desktop\\pc201206210003_2.GIF")));
BufferedWriter bw=new BufferedWriter(new OutputStreamWriter(new FileOutputStream("C:\\Users\\Administrator\\Desktop\\小外甥1.GIF")));
String line=null;
while((line=br.readLine())!=null)
{
bw.write(line);
bw.flush();
}
bw.close();
br.close();
}
}
为什么报错说找不到指定的路径?
|
|