The remote server returned an error: (403) Forbidden

后端 未结 10 1418
半阙折子戏
半阙折子戏 2020-12-15 03:16

I\'ve written an app that has worked fine for months, in the last few days I\'ve been getting the error below on the installed version only.

If I run the source code

10条回答
  •  眼角桃花
    2020-12-15 04:03

    Looks like problem is based on a server side.

    Im my case I worked with paypal server and neither of suggested answers helped, but http://forums.iis.net/t/1217360.aspx?HTTP+403+Forbidden+error

    I was facing this issue and just got the reply from Paypal technical. Add this will fix the 403 issue. HttpWebRequest req = (HttpWebRequest)WebRequest.Create(url);
    req.UserAgent = "[any words that is more than 5 characters]";

提交回复
热议问题