私のコード:
string dir = "/Users/valeria/Desktop/screening/"+cell;
string remoteUri ="http://www.broadinstitute.org%2Fcmap%2FviewScan.jsp%3Ftype%3DCEL%26scan%3D"+p;
string pFileName = dir + "/p";
using (WebClient myWebClient = new WebClient())
{
myWebClient.DownloadFile(remoteUri, pFileName);
}
私のプログラムはファイルを作成しますpFileName
が、次の例外が発生するため、何もダウンロードしません:
未処理の例外: System.Net.WebException: パスの一部が見つかりませんでした "/Users/valeria/Projects/screening/screening/bin/Debug/http:/www.broadinstitute.org/cmap/viewScan.jsp?type= CEL&scan=EC2003090503AA". ---> System.IO.DirectoryNotFoundException: パスの一部が見つかりませんでした "/Users/valeria/Projects/screening/screening/bin/Debug/http:/www.broadinstitute.org/cmap/viewScan.jsp?type =CEL&scan=EC2003090503AA"
どうしたの?