Click here to Skip to main content
15,889,992 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Why i m getting error in this line when deploying website
error while i already set customerror tag to off
XML
<!-- Web.Config Configuration File -->

<configuration>
    <system.web>
        <customErrors mode="Off"/>
    </system.web>
</configuration>

Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.


<!-- Web.Config Configuration File -->

<configuration>
    <system.web>
        <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
    </system.web>
</configuration>
Posted
Updated 4-Feb-14 0:42am
v3
Comments
Dinesh.V.Kumar 3-Feb-14 7:30am    
Need more info on the error...please post the error message
tanuj.ahar 4-Feb-14 6:40am    
Hi dinesh when i am hosting my project i am getting this error i want to know what kind of changes needed in web.config file at the time of hosting
1. i change connection string
2. cutomeerror tag to="Off'
any one else
Dinesh.V.Kumar 4-Feb-14 7:04am    
set the CustomError tag to "On". It will give you a detailed error description...You may yourselves be able to solve that issue once you get it..If its still a problem..please post the detailed error message. We can solve it...
tanuj.ahar 4-Feb-14 7:57am    
Hi dinesh thanks for help
Dinesh.V.Kumar 4-Feb-14 8:26am    
Do let me know if you still face issue. Please post the detailed error so that we can help you solve it....

1 solution

This error comes when you have an exception in your application and you have CustomErrors set to On.
Just setting the custom error to On doesn't help. You will need to set a defaultRedirect value which is a page your website should redirect to when the error occurs. Usually you create an Error page, say Error.aspx and redirect to that page. This page has a customer friendly message.

If you have exception logging in place. Check the logs for what's wrong. That's how you will be able to correct it and move any further.
 
Share this answer
 
Comments
tanuj.ahar 4-Feb-14 7:59am    
@Ankur I agree with You .

Finnaly i got solution to my problem i have problem in my connection string nothing else.

Thanks for your help

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900