1
 2    //*********************上传文件2.0********************************
 3    protected void Button1_Click(object sender, EventArgs e)
 4    {
 5 
 6     string path = Server.MapPath("~/image/");
 7   
 8
 9    this.FileUpload1.SaveAs (path + this.FileUpload1 .FileName );
10    //
11this.Label1.Text = "路径:"+this.FileUpload1 .PostedFile .FileName +this.FileUpload1 .PostedFile.ContentLength ;
12   // this.Label2.Text = "wenjiansuccess!";
13
14    }

15
16}
17