The SaveAs method is configured to require a rooted path, and the path 'fp' is not rooted

后端 未结 6 1258
有刺的猬
有刺的猬 2020-12-06 17:47

I am doing Image uploader in Asp.net and I am giving following code under my controls:

    string st;
    st = tt.PostedFile.FileName;
    Int32 a;
    a =          


        
6条回答
  •  旧时难觅i
    2020-12-06 17:48

    We cannot use the "SaveAs" method to write directly to an FTP server. Only local paths and UNC paths are supported for the above method.

    To save it to FTP, please use the FtpWebRequest class.

    You will get the full details to this in the same type of question answer in social.msdn.

    Please go through the link.. and you will be able to solve the issue..

    enter link description here

    --thanks for the answer by Jesse HouwingXPirit (MCC, Partner, MVP)

提交回复
热议问题