try修改C:\WINNT\Microsoft.NET\Framework\v1.0.3705\CONFIG\Machine.config文件ProcessModel段中的UserName, 把Machine改成SYSTEM.
类似于
<processModel enable="true" timeout="Infinite" idleTimeout="Infinite" shutdownTimeout="0:00:05" requestLimit="Infinite" requestQueueLimit="5000" restartQueueLimit="10" memoryLimit="60" webGarden="false" cpuMask="0xffffffff" userName="SYSTEM" password="AutoGenerate" logLevel="Errors" clientConnectedCheck="0:00:05" comAuthenticationLevel="Connect" comImpersonationLevel="Impersonate" responseRestartDeadlockInterval="00:09:00" responseDeadlockInterval="00:03:00" maxWorkerThreads="25" maxIoThreads="25"/>

解决方案 »

  1.   

    UserName属性默认情况下进程作为 IIS 标识 (System) 运行,默认值是 System。怎么还需要改呢?
      

  2.   

    myWebClient.DownloadFile("http://weather.sina.com.cn/gw24w.html","c:/Inetpub/wwwroot/c_Study/天气预报.html");我现在把地址更改为绝对地址,因为它默认保存在 c:\WINNT 下,按照GoodIdea说的更改了Machine.config,但现在运行时报操作超时,我到c:/Inetpub/wwwroot/c_Study/ 目录下去看,在运行时有文件 天气预报.html 产生,但后来又自动删除了?不知是什么原因?
      

  3.   

    To tgLiu:上传的用HtmlInputFile类很容易实现,在帮助里也有。inpFileUp.PostedFile.SaveAs("New.txt");能不能让我看看下载的源码啊?