这个程序不难吧,你将文本中内容写到文件中去就是了,用file类,

解决方案 »

  1.   

    is it difficult for,help me please.thnak you!
      

  2.   

    以下是鄙人的看法,不对之处请指正:由于 Applet 可以在网上自动下载,JVM 执行 Applet 时,对 Applet 的限制很多,比如“限制Applet对本地硬盘的操作”,“进行数据库操作时也有不少限制”我认为用Applet实现这个功能不是一个好办法,何不用Php,Jsp(如果主页空间支持的话)?
    另外,数据最好放在数据库中
      

  3.   

    not possible by using applet, unless you want to get digital certifercate for that
      

  4.   

    这个是读签名后读本地文件的applet,
    import java.awt.*;
    import java.awt.event.*;
    import java.applet.*;
    import java.io.*;public class FileReaderApplet extends Applet {
    boolean isStandalone = false;
    TextField fileNameField;
    TextArea fileArea;file://Get a parameter value
    public String getParameter(String key, String def) {
     return isStandalone ? System.getProperty(key, def) :
     (getParameter(key) != null ? getParameter(key) : def);
    }file://Construct the applet
    public FileReaderApplet() {
    }file://Initialize the applet
    public void init() {
    try {
    jbInit();
    }
    catch(Exception e) {
    e.printStackTrace();
    }
    }file://Component initialization
    private void jbInit() throws Exception {
    this.setSize(new Dimension(400,300));
    this.setLayout(new BorderLayout());
    Panel panel=new Panel();
    Label label=new Label("File Name");
    panel.add(label);
    fileNameField=new TextField(25);
    panel.add(fileNameField);
    Button b=new Button("Open File");
    b.addActionListener(new ActionListener(){
    public void actionPerformed(ActionEvent e){
    loadFile(fileNameField.getText());
    }
    });
    panel.add(b);
    this.add(panel,BorderLayout.NORTH);
    fileArea=new TextArea();
    this.add(fileArea,BorderLayout.CENTER);
    }public void loadFile(String fileName){
    try{
    BufferedReader reader=new BufferedReader(new FileReader(fileName));
    String context=new String();
    while((context=reader.readLine())!=null){
    fileArea.append(context+"/n");
    }
    reader.close();
    }catch(IOException ie){
    fileArea.append(ie.getMessage());
    }catch(SecurityException se){
    fileArea.append("because of security constraint ,it can not do that!");
    }
    }file://Get Applet information
    public String getAppletInfo() {
    return "This is an applet can read and write the local file system";
    }}
      

  5.   

    这是不可能办到的,除非你的主页空间所在的服务器允许你使用CGI, ASP, JSP等。
      

  6.   

    谢谢大家,
    我要得其实就是一个FTP上传程序,
    知道主机的地址,FTP的用户名,FTP的密码,然后上传一个文件到主机中,
    就是这样。
    我继续等待,再次谢谢大家。我的MAIL:[email protected]