import java.awt.*;
import java.io.*;
public class A
{
public static void main(String args[])throws IOException
{
Frame f=new Frame ("查看文件");
f.setVisible(true);
TextArea ta=new TextArea(20,50);
String aline;
BufferedReader br=new BufferedReader(new FileReader("A.java"));
while((aline=br.readLine())!=null)
ta.append(aline+'\n');
br.close();
f.add(ta);
f.pack();
}
}
阅读(300) | 评论(0) | 转发(0) |