Redirect from 404.htm to 404b.htm is not working
Hi, I want to redirect to a new page, when I get 404.htm error page in the application. The application is built on MOSS and hosted on IIS6.0 in Windows 2003 Server. We also tried changing custom Errors 404b file and switching on errors in custom Web.config file. But redirection does not seem to work. We believe the page is getting redirected to some unknown location. Please specify the method we need to follow to redirect. Please give me your suggestions. Thanks and regards, Usha.
June 28th, 2010 7:17pm

One way I found to create a custom Page Not Found is to create a site level feature receiver that will attach it to the webApplication instance. On the activated event you would attach it like this: [SharePointPermission(SecurityAction.LinkDemand, ObjectModel = true)] public override void FeatureActivated(SPFeatureReceiverProperties properties) { if (properties != null) { try { SPSite site = properties.Feature.Parent as SPSite; System.Uri webApplicationUri = new Uri(site.Url); SPWebApplication webApplication = SPWebApplication.Lookup(webApplicationUri); if (webApplication != null) webApplication.FileNotFoundPage = "CustomError.html"; } catch (Exception ex) { throw; } } } And in your deactivated event you could unattach it by setting the same webApplication.FileNotFoundPage to null. You will also have to save your Custom Page Not found page in the Layout/1033, for the English resource. Hope this helps
Free Windows Admin Tool Kit Click here and download it now
June 28th, 2010 8:15pm

As far as I know Sivlian is correct and you will need to create a custom console application in order to point to a custom 404 error page. Note that there is a design limitation that means certain site collections will still show the OOB error page - we had this issue when attempting to implement a custom 404. Further information is available at http://support.microsoft.com/kb/941329/en-gbBenjamin Athawes Twitter SharePoint Blog
June 29th, 2010 10:32am

Hi Thanks for your reply. I had tried using HTTPModules and HTTPContext to check "page not found" and it is working for me but it is working and showing my custom error page only if I type a not existing .aspx page if I type a non-existing .html page or .htm page it is not showing custom error page. Please suggest. Thanks and regards, Usha.
Free Windows Admin Tool Kit Click here and download it now
July 1st, 2010 12:21pm

Please help to restore it.
September 16th, 2010 5:00am

I don.'t know how to fill up your form which you have just sent to m, please help
Free Windows Admin Tool Kit Click here and download it now
September 16th, 2010 5:05am

ive tried to instal all 3discks but it keeps coming back telling me that #2 has all ready been installed how do i go about getting #3 instaled ?
November 15th, 2010 2:51pm

Hi How are you to day
Free Windows Admin Tool Kit Click here and download it now
November 29th, 2010 12:57pm

I had brain surgery and really messed up my computer. I am disabled and cannot aford a fix it software program. I am missing 2 sys32 files, my disk drive does not work and now this? I need a fix it program. I cannot upload my Internet Security 2006 PC-cillin. How can we resolve this?Wendy J Boyer
February 24th, 2011 2:42am

I also cannot register my Microsoft WorksWendy J Boyer
Free Windows Admin Tool Kit Click here and download it now
February 24th, 2011 2:44am

I am incurable cerebral palsy person unable to afford to pay,since I am only on a disability pension.
March 5th, 2011 8:39pm

I'm closing this thread and locking it because it has been attracting a mass of spam. (I don't know why just this thread and spam has been coming even after I deleted all the earlier spam here). The unanswered question at the end is anyway from June 2010. Moderator pre-2010 forums.SP 2010 "FAQ" (mainly useful links): http://wssv4faq.mindsharp.com/default.aspx WSS3/MOSS FAQ (FAQ and Links) http://wssv3faq.mindsharp.com/default.aspx Both also have links to extensive book lists and to (free) on-line chapters
Free Windows Admin Tool Kit Click here and download it now
March 6th, 2011 1:34am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics