473,407 Members | 2,598 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,407 software developers and data experts.

Stepping Backwards in Code ( debugger/VS03.net )

When stepping through code, to find where an error is thrown, the problem is
that I have to step threw the statement that causes the error, and if it's
in a class that's instantiated from the main program, then I may miss the
statement that causes the error.

How can I get the debugger to stop right at the statement that causes the
error.
Nov 22 '05 #1
4 1417
If the class is part of the same project then you can step into it with F11
instead of F10 (assuming you are using the default key mapping for VS.Net)
"c# newbie" <no****@leave.me.alone> wrote in message
news:71******************************@news.teranew s.com...
When stepping through code, to find where an error is thrown, the problem is that I have to step threw the statement that causes the error, and if it's
in a class that's instantiated from the main program, then I may miss the
statement that causes the error.

How can I get the debugger to stop right at the statement that causes the
error.

Nov 22 '05 #2
If the class is part of the same project then you can step into it with F11
instead of F10 (assuming you are using the default key mapping for VS.Net)
"c# newbie" <no****@leave.me.alone> wrote in message
news:71******************************@news.teranew s.com...
When stepping through code, to find where an error is thrown, the problem is that I have to step threw the statement that causes the error, and if it's
in a class that's instantiated from the main program, then I may miss the
statement that causes the error.

How can I get the debugger to stop right at the statement that causes the
error.

Nov 22 '05 #3
try CTRL + ALT + E, which will take you to the Debug exceptions window.
there you can tell visual studio to immediately break on any exception or
any .net exception etc. you can also find this under Debug -> Exceptions...

let me know if you have other questions or if this doesn't help.

jeff.

--

This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm

Note: For the benefit of the community-at-large, all responses to this
message are best directed to the newsgroup/thread from which they
originated.

Nov 22 '05 #4
Tell VS.NET to break when an excepion is thrown. Look on the
Debug/Exceptions menu.

Regards,
Aaron Queenan.

"c# newbie" <no****@leave.me.alone> wrote in message
news:71******************************@news.teranew s.com...
When stepping through code, to find where an error is thrown, the problem is that I have to step threw the statement that causes the error, and if it's
in a class that's instantiated from the main program, then I may miss the
statement that causes the error.

How can I get the debugger to stop right at the statement that causes the
error.

Nov 22 '05 #5

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

Similar topics

0
by: Fernando Rodríguez | last post by:
Hi, I was trying to step through a first attemp of multithreaded script (see below), with PythonWin, but I'm gettign a very strange error: ...
3
by: c# newbie | last post by:
When stepping through code, to find where an error is thrown, the problem is that I have to step threw the statement that causes the error, and if it's in a class that's instantiated from the main...
1
by: | ov | last post by:
Hi, My application includes a class library which has both managed C++ and unmanaged C++ code. The unmanaged C++ code includes only one class with both virtual methods and non-virtual methods....
2
by: John Black | last post by:
Hi, I wonder if there is any good way in debugging the code not steping into STL code, it is easy to do in normal statement, just click "step over", but when there are some STL type variable on...
5
by: craig | last post by:
Is it possible to step into the code of a referenced .net assembly from within a project that is being debugged? Thanks!!!
0
by: craig | last post by:
When stepping though C# code in Visual Studio, often times a line of code will cause an event handler to be run. However, it appears that the debugger will not automatically step into that event...
5
by: David C | last post by:
This is very strange. Say I have code like this. I am simply looping through a collection object in a foreach loop. Course course = new Course(); foreach(Student s in course.Students) {...
5
by: NewToCPP | last post by:
There are several occations where we write onto someone else' memory region. Is there any debugging mechanism to find out which part of the code is causing this problem?
12
by: mednyk | last post by:
T-SQL Debugger Doesn't Allow Stepping Through Stored Procedures And there is no other procedure with the same name owned by dbo or any other users. There is no error messages also, it just...
5
by: JPS | last post by:
Does anyone know how to add a VB class to a C# project and then instantiate the Vb object and step through the code? Can we do tihs with a VB DLL?
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.