Exception: “URI formats are not supported”

后端 未结 4 1040
误落风尘
误落风尘 2020-12-08 01:40

I have an absolute local path pointing to a dir: \"file:\\\\C:\\\\Users\\\\john\\\\documents\\\\visual studio 2010\\\\Projects\\\\proj\"

But when I try

4条回答
  •  难免孤独
    2020-12-08 02:06

    Try This

    ImagePath = "http://localhost/profilepics/abc.png";
       HttpWebRequest request = (HttpWebRequest)WebRequest.Create(ImagePath);
              HttpWebResponse response = (HttpWebResponse)request.GetResponse();
                Stream receiveStream = response.GetResponseStream();
    

提交回复
热议问题