exception

How can I create a Windows App(C#) that has where I can display all the exceptions in various objects in a message box

I am trying to use MVC in C#. So the form controller uses the authentication class instance. I am handling the invalid credentials in the authentication class. But I cannot display that message in the message box as it is not in the form controller class instance. Please help ...

Unhandled exception when Linklabel is clicked C# Winform

Hello everyone. I am getting a strange unhandled exception when I click the linklabel which should open a form. I have tried to put the code in linklabel_click event handler in try-catch block, but I still get the error below. See the end of this message for details on invoking just-in-time (JIT) debugging instead of this dialog...

How can I tell if I'm in a Delphi exception stack?

From within a finally block, is it possible to tell an exception has been raised? ...

exception problem in C++ visual studio

Hello, I have a problem in catching an exception. I am trying to re throw an exception and I get a message: "There is no source code available for the current location". The code is very simple: #include <exception> using namespace std; try { throw exception("asas"); } catch (const exception& e) { cout<< "Error msg"<< e.what()<< ...

How to get Python exception text

I want to embed python in my C++ application. I'm using Boost library - great tool. But i have one problem. If python function throws an exception, i want to catch it and print error in my application or get some detailed information like line number in python script that caused error. How can i do it? I can't find any functions to ge...

Increment values using Zend_DB_Table Raw SQL

I have a website where a user can upload images for a real estate property. The table structure: image_id property_id userid filename thumbfilename display_order timestamp The scenario: When a user uploads multiple pictures, he / she SHOULD be able to set the primary photo from their uploaded images for the specified property. Th...

Single-threaded apartment - cannot instantiate ActiveX control

I need to get information about applied CSS styles in HTML page. I used AxWebBrowser and iterate IHTMLDOMNode. I'm able to get all the data I need and move the code into my application. The problem is that this part is running inside of the background worker and I got exception when trying to instantiate the control. AxWebBrowser browse...

Wrong line numbers in stack trace (release)

Sometimes we receive stack traces from our customer with wrong line numbers. It happens not so often, but sometimes it puzzles us. Customers have release assemblies with optimizations and with "pdb only" debug information. And yes, we compare line numbers with exactly the same version of code the customer has. And yes, customer has ri...

getting charconversion exception for " %" value in query parameter?

i am getting adding some of parameter in query string.value of these param can be "a%%","%" etc.on java code side .while parsing query parameter i m getting char conversionexception as shown below in exception log. 13:14:39,555 ERROR [STDERR] java.io.CharConversionException: EOF 13:14:39,555 ERROR [STDERR] at org.apache.tom...

How to debug external code after exception in .NET (vs2008)

Have Exception thrown in my app. In callstack I can see program stops at property's getter: FullName.get() I'm trying to find out what part of code is generating exception. But in call stack I can see only 3 entries: 3) FullName.get() 2) [External Code] 1) myApplication.exe Is is a way to debug external code somehow ? ...

Is it suitable to make properties of my customize exception to be set

There is my customize exception class public class ParseFailedException : Exception { public string FailedFileName { get; set; } public int? LineNo { get; set; } public int? ColumnNo { get; set; } } Is it good make the property as set, or should they be passed through the constructor...

If I change the base class that a Java Exception class extends, do I need to update the serialVersionUID value?

Consider the following Java exception classes: public class FooException extends RuntimeException { // [...] } public class FooException extends BarException { private static final long serialVersionUID = -5322002268075295537L; // [...] } If I wish to update the inheritance hierarchy to remove BarException, such that Foo...

Avoid "program stopped working" in C#/.NET

I have a console application written in C#/.NET that I want to run from a script (nant). If an exception occurs in the console application, I would like nant to continue, but in Windows Vista there is a popup that searches for solutions and asks for debug etc. I would like to avoid the popup with "program stopped working" when an except...

parsing SQLException errors in an ASP.NET (MVC) application?

While validation can prevent most SQL errors, there are situations that simply cannot be prevented. I can think of two of them: uniqueness of some column and wrong foreign key: validation cannot be effective as the an object can be created or deleted by other parties just after validation and before db insertion. So there are (at least) ...

What is the exception I should be catching on the dotted line?

I have a problem at school. I'm new to programing and I need some help. Please complete the dotted line: import java.net.*; import java.io.* public class Test{ public static void main (String arg[]} int x=0; try { ServerSocket s=new ServerSocket ( k ); s.close(); } catch (..........................) ...

Popup extender "frozen" on code-behind exception.

Hi, In a C#/ASP.NET project, we're using an ajax modalpopupextender to display a "Processing..." message to the users. We're displaying it using a Javascript call in the code of the ASP.NET page. Then, in the code behind, we're doing some database operation, and hide again the popup using "popup.hide();" The problem is that when an exc...

Symfony 1.1 Custom 500 Exception Access

In symfony 1.0 you can access the uncaught exception causing your custom 500 error page to appear through $this in your error500.php. How can this be accomplished in 1.1? ...

Java Class with string and a specified length

Hi All, I'm creating a java program that creates a file and fills it with data in string form with each field in the record limited to a specific length. What I think I need to do is to create a class that has a string for the data field and a length specifying the length of the string. And then somehow restrict it so that the string n...

How do you know there may be an exception?

Do I have to take a look at the java api everytime I instantiate an object / call a method from a class in it? Also, do I always have to know which classes are in the java api and which are not? ...

Will an exception get passed back to the calling method?

Let's say in one method I have try { callme(); } catch { // handle callme exception } Now let's say callme() calls method1() which in turn calls method2() -- If method2() throws an exception should it get thrown back to method1()'s frame, which will then stop any further execution inside of itself and pass the exception thrown from m...