Last post Jun 22, 2018 11:17 AM by PatriceSc
Jun 21, 2018 09:34 AM|ryoka012|LINK
Can anyone help me on HTTP Error 404.0 Not Found
The data successfully submitted and save on the DB but it cannot find the page and it does exist. I am using IIS 7
here is the Error Detailed
Module: IIS Web Core
Error Code: 0x80070002
Can anyone help on why does this error pop out
Thanks and Best Regards
Jun 21, 2018 09:52 AM|mgebhard|LINK
Pretty simple a 404 means the URL was not found. Other than that there is not much we can do on the forum as you have not posted enough information.
What is the URL? What kind of application is this? Can you post source code that reproduces the issue?
Jun 22, 2018 12:07 AM|ryoka012|LINK
Thanks for the reply.
But my problem is that when i try to execute in my localhost there is no problem on the URL.
But on my publish Web Server that were the error occurs.
Please see below code
protected void btnResend_Click(object sender, EventArgs e)
string_link = "https://sample.com/Sample/Calendar/?RequestCode=" + Session["ProviderKey"];
this.btnResend.Enabled = false;
this.btnResend.Enabled = true;
Session.RemoveAll(); // This is were the URL error occurs
catch (Exception ex)
errorLogs.LoggedError(ex.Message, HttpContext.Current.Request.Url.AbsoluteUri, Request.Browser.Browser, Request.Browser.Version, Request.ServerVariables["HTTP_USER_AGENT"]);
Jun 22, 2018 06:32 AM|Nan Yu|LINK
Please confirm whether you have Successful.aspx in root website directory . You can check the directory structure or directly type the url in browser.
Jun 22, 2018 06:46 AM|ryoka012|LINK
Hi Nan yu,
Yes i can confirm that the Successful.aspx is in my root folder.
Jun 22, 2018 07:23 AM|PatriceSc|LINK
What if you try to access this page directly from: your browser? Does it work ? The 404 couldn't come from your previous http request ?
Edit: rather than just ex.Message I would log ex.ToString() to get the full details about the exception. Or could it be a problem on /ContactAdministrator ?
Jun 22, 2018 07:27 AM|ryoka012|LINK
I tried it localhost and it show no error but when it in the publish server it return 404 error.
Jun 22, 2018 07:32 AM|PatriceSc|LINK
I meant I would try to access this page from my browser and on the server on which I have a problem to make 100% sure this page actually works.
If yes, I believe the error might be not what you think :
- do you see your contactadministrator page being shown ? I not could be caused by this one. What you shown comes from your own log or from IIS ?
- also I would log ex.ToStirng() rather than ex.Message to get the full exception chain and the call stack rather than just a message
Jun 22, 2018 07:56 AM|ryoka012|LINK
Sorry but that would not be possible.
Here is my answer to your question
Jun 22, 2018 10:50 AM|mgebhard|LINK
A 404 error means the URL was not found. The fact that you are seeing the error "Thread was being aborted". Indicates this line is not causing the error.
Are you sure the deployed code matches what you posted? The following line of code would cause the described error.
Have you verified /ContactAdministrator/default.aspx exists?
Lasly, 404 error messages show the requested URL that was not found. Please post the requested URL. Use the browser's dev tools and view the network tab to get the URL. The request will show in red.
Jun 22, 2018 11:17 AM|PatriceSc|LINK
So the problem changed ? As pointed by mgebhard "Thread was being aborted" happens when using Response.Redirect("somewhere"); It should NOT happen when using false in the 2nd argument.
For the 404 I was trying to understand what you see in your browser and from where comes the information you shown to us. What I suspected is that the problem could be perhaps not in the first but rather in the 2nd redirect.