473,395 Members | 1,647 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Strange Exception behavior

I'm working on a project in VB.NET and when a line of code is executed that
throws a nullreferenceexception or some other type of exception, the runtime
just jumps to some other line of code(seemingly unrelated to the line that
caused the exception) instead of crashing and throwing up an exception
dialog. Has anybody else seen this type of behavior and if so, is this a bug
or is it just my screwed up project.

Thanks in advance

Steve
Nov 20 '05 #1
3 1061
* "Steve Long" <St**********@NoSpam.com> scripsit:
I'm working on a project in VB.NET and when a line of code is executed that
throws a nullreferenceexception or some other type of exception, the runtime
just jumps to some other line of code(seemingly unrelated to the line that
caused the exception) instead of crashing and throwing up an exception
dialog. Has anybody else seen this type of behavior and if so, is this a bug
or is it just my screwed up project.


Can you post the complete exception message + callstack?

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #2
"Steve Long" <St**********@NoSpam.com> wrote in message
news:Ov*************@tk2msftngp13.phx.gbl...
when a line of code is executed that throws a nullreferenceexception
. . . the runtime just jumps to some other line of code (seemingly
unrelated to the line that caused the exception) instead of crashing
and throwing up an exception dialog.


"... the runtime jumps ..." - exactly what do you mean?

If you mean the Visual Studio IDE, make sure that you've [completely]
rebuilt the [dll] solution - it could be that the dbeuggin information is
out of step with the actual dll, so the IDE gets touch confused.

HTH,
Phill W.
Nov 20 '05 #3
Well, by jumping, I mean that when the IDE hits a line of code that causes
an exception to be thrown, (I know that because I can place a try block
around it which I did after it exhibited this stupid behavior), the next
line of code that gets executed is a line of code in an event handler for
one of the controls in my project. This event code is what would run when
the form is activated. So, to me this means that the form is getting send to
the front after the exception which causes the event code to activate. This
behavior continues whenever a line of code gets executed that causes an
exception to be thrown. What I would expect, however, is that the exception
would cause the IDE to either break at that line or cause the project to
crash due to an unhandled exception.

Perhaps is does need to be cleaned and rebuilt. I'll try that. I hope I made
sense there.

Steve
"Phill. W" <P.A.Ward@o-p-e-n-.-a-c-.-u-k> wrote in message
news:ce**********@yarrow.open.ac.uk...
"Steve Long" <St**********@NoSpam.com> wrote in message
news:Ov*************@tk2msftngp13.phx.gbl...
when a line of code is executed that throws a nullreferenceexception
. . . the runtime just jumps to some other line of code (seemingly
unrelated to the line that caused the exception) instead of crashing
and throwing up an exception dialog.


"... the runtime jumps ..." - exactly what do you mean?

If you mean the Visual Studio IDE, make sure that you've [completely]
rebuilt the [dll] solution - it could be that the dbeuggin information is
out of step with the actual dll, so the IDE gets touch confused.

HTH,
Phill W.

Nov 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Terry | last post by:
It's my understanding of UDP sockets that if there is a thread blocked on a "recvFrom()" call and other thread sends a UDP packet to some address, that if the machine on the other end isn't up,...
0
by: globus | last post by:
Hi, I've a c# project calling a COM Interop library method. This method starts a Service , so I need administrator or power user rights to use it without exceptions. I'm developing exceptions...
1
by: Chris | last post by:
Hi, a strange behaviour when working with exceptions : when I divide and integer by 0 will an exception be thrown. OK but, when I divide a double by 0 is no exception thrown ??? How come ? ...
1
by: Maileen | last post by:
Hi, I finished my application butonce again i have some strange behavior with XML/text functions... for example, here below is a function which worked perfectly till now and now generate an...
0
by: ivb | last post by:
Hi all, I am using DB2 8.1.11.1 on NT with ASP.NET 1.1 When application make connection to database (via ADO.NET), it set "Connection timeout" parameter to 30 seconds. After, when my webpage...
10
by: John Kraft | last post by:
Hello all, I'm experiencing some, imo, strange behavior with the StreamReader object I am using in the code below. Summary is that I am downloading a file from a website and saving it to disk...
2
by: Raymond Andreassen | last post by:
After some time of debugging one of our apps, I started a witchhunt on the StringTrim function. basicly the error can be reduced down to the following: It started with testing of the following...
0
by: Antonio Paglia | last post by:
Hi guys, I saw an strange behavior with some printers of series HP Laserjet 1000. I have installed several printers on my PC, some of them are : HP LaserJet 1020 e 1010. I'm using...
5
by: rconradharris | last post by:
A co-worker of mine came across some interesting behavior in the Python interpreter today and I'm hoping someone more knowledgeable in Python internals can explain this to me. First, we create...
1
by: dizzy | last post by:
Hello I have noticed a strange behavior (tho for many of you this is to be expected I'm sure :) ) when I have an expression that adds a long value with an unsigned one (like in "10l + 10u"). ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.