0
votes
2answers
68 views

How to get the method name from which the exception is thrown? [closed]

I need to get the class name and the method name from which the exception is thrown. How can I do that? Thanks in advance. My code: private void setErrorDetails(final Throwable cause) { for ...
0
votes
2answers
79 views

How is it possible to overload the throw function while writing a custom exception class in C++?

I wrote a routine to store the backtrace and line no and file name etcetera. The purpose for this was to store such data for whenever an exception is thrown. However, the problem I am facing is that ...
0
votes
1answer
61 views

Break a loop in OCaml

I often need to break a loop in OCaml, there are at least two ways: (* by exception *) try for i = 0 to 100 do ... if cond then raise BreakLoop done; ... with BreakLoop -> ... (* by ...
0
votes
0answers
25 views

System.OutOfMemoryException' occurred in mscorlib.dll in asp.net application

I am extracting the data from TFS DB. The below code works fine if the number of work items below 10000 workitem records, however it is encountering error "An exception of type ...
0
votes
0answers
26 views

Exception handling in MVC

Where are exceptions handled in the MVC architecture ? Say, i am uploading a file using Ajax and an exception occurs, where is it handled ? what is the best practice for this ? Should it be in the ...
1
vote
1answer
58 views

Why is this exception neither silent nor informational?

This legacy code is called from a gazillion places in the app: public void DBCommand(string dynSQL, bool Silent) { checkConnection(); SqlCeCommand cmd = ...
2
votes
4answers
80 views

Need explanation on Exception code

I have some few doubts on exceptions. Can anyone tell me why java doesnt allow us to create Checked Exception in a Subclass while it allows Unchecked exception in a subclass Below exampple throws ...
1
vote
2answers
57 views

Application.ThreadException is not called

My WinForms app installs Application.ThreadException event handler to process all unhandled exceptions (the handler displays a dialog box: Error occured, click here to send bug report, etc). The ...
0
votes
4answers
65 views

Unable to handle Custom Exception Java

I know this type of questions have come before, and I have went threw them, but didn't get the final part which I need to do. My ExceptionClass public class ProException extends Exception { /** * ...
1
vote
3answers
36 views

Unhandled Exception Type in JAVA

I have a two classes in the same package in JAVA. One class in which I have a constructor an exception I tried to create myself: public class ZooException extends Exception { public ...
1
vote
1answer
34 views

Catch “PDOException” with custom exception handler

I have a simple piece of code, using PDO in PHP: $conn = new PDO('mysql:host=localhost;dbname=someDatabase', $username, $password, array( PDO::ATTR_ERRMODE => ...
0
votes
1answer
18 views

Exception handling in Python and Praw

I am having trouble with the following code: import praw import argparse # argument handling was here def main(): r = praw.Reddit(user_agent='Python Reddit Image Grabber v0.1') for i in ...
0
votes
1answer
24 views

What happens with an automatically caught exception?

Suppose one has the following code: try { $i = 0; while ($i < 10) { if ($i == 7) { throw new Exception("Test exception"); } $i++; } } catch ...
0
votes
1answer
23 views

error management service for my Ruby on Rails project

I am looking for error management service for my Ruby on Rails project, Can any one suggest the best tool with lower price. I have 5 Rails projects. I found one tool http://www.batbugger.io/ is free ...
0
votes
2answers
29 views

Detect if an exception has been thrown manually without using a custom exception class

I got a try-catch block in my php application like this: try { if ($userForgotToEnterField) { throw new Exception('You need to fill in your name!'); } ... ...

1 2 3 4 5 89
15 30 50 per page