Solved

Hide StackTrace in Exception

Posted on 2008-10-10
8
981 Views
Last Modified: 2013-12-17
Hi,
  I am trapping errors and throwing it. But it shows all the details of the Stack Trace with it. How do I hide this ? I do not want to display the StackTrace details to the users. Thanks for all your help.
0
Comment
Question by:shabkap
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
8 Comments
 
LVL 8

Expert Comment

by:tiagosalgado
ID: 22687979
set <compilation debug="false" /> in your web.config
0
 

Author Comment

by:shabkap
ID: 22688169
tried it.  did not work
0
 
LVL 8

Expert Comment

by:tiagosalgado
ID: 22688293
Try <customErrors mode="RemoteOnly" />

0
Forrester Webinar: xMatters Delivers 261% ROI

Guest speaker Dean Davison, Forrester Principal Consultant, explains how a Fortune 500 communication company using xMatters found these results: Achieved a 261% ROI, Experienced $753,280 in net present value benefits over 3 years and Reduced MTTR by 91% for tier 1 incidents.

 
LVL 26

Accepted Solution

by:
Anurag Thakur earned 250 total points
ID: 22689536
0
 

Author Comment

by:shabkap
ID: 22767104
I tried this and it worked. I throw the error back to the ASP page and trap it there by just displaying the message from the exception.  This way i dont get the stack trace.
0
 
LVL 26

Expert Comment

by:Anurag Thakur
ID: 22947086
the authors requirement has been fulfilled by my comment i suppose ID:22767104
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my previous article (http://www.experts-exchange.com/Programming/Languages/.NET/.NET_Framework_3.x/A_4362-Serialization-in-NET-1.html) we saw the basics of serialization and how types/objects can be serialized to Binary format. In this blog we wi…
This document covers how to connect to SQL Server and browse its contents.  It is meant for those new to Visual Studio and/or working with Microsoft SQL Server.  It is not a guide to building SQL Server database connections in your code.  This is mo…
Are you ready to implement Active Directory best practices without reading 300+ pages? You're in luck. In this webinar hosted by Skyport Systems, you gain insight into Microsoft's latest comprehensive guide, with tips on the best and easiest way…

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question