473,513 Members | 2,693 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

debugging at class level ??

hi,

How can one set a conditional-breakpoint not linked to any particular
statement in a method but rather at class level so to speak ?

I'd like to break into debugging mode when e.g. the enabled-property of
a button belonging to a form changes, but not in any particular method.

thank you
Chris


*** Sent via Developersdex http://www.developersdex.com ***
May 2 '07 #1
8 1062
Chris,
I doubt there is a way to set this kind of "global breakpoint" that you
describe, but you can look into Debug.Assert as well as the Debugger.Break
method.
Peter

--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net


"Chris Peeters" wrote:
hi,

How can one set a conditional-breakpoint not linked to any particular
statement in a method but rather at class level so to speak ?

I'd like to break into debugging mode when e.g. the enabled-property of
a button belonging to a form changes, but not in any particular method.

thank you
Chris


*** Sent via Developersdex http://www.developersdex.com ***
May 2 '07 #2
Hi,

I don't know of nothing like this. I have never seen a IDE with that
feature.

"Chris Peeters" <cm****@yahoo.comwrote in message
news:eo**************@TK2MSFTNGP06.phx.gbl...
hi,

How can one set a conditional-breakpoint not linked to any particular
statement in a method but rather at class level so to speak ?

I'd like to break into debugging mode when e.g. the enabled-property of
a button belonging to a form changes, but not in any particular method.

thank you
Chris


*** Sent via Developersdex http://www.developersdex.com ***

May 2 '07 #3
On May 2, 11:26 am, "Ignacio Machin \( .NET/ C# MVP \)" <machin TA
laceupsolutions.comwrote:
I don't know of nothing like this. I have never seen a IDE with that
feature.
VB6 had this feature. It would break immediately after the line which
changed the watched value.

May 2 '07 #4
Right, but that isn't what the OP wants. The OP wants to say "any time
any method/property in this class is accessed, break".

The feature in VB allowed you to watch a value, and when it changed,
break.

Two very, very different things.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Andy" <an***@med-associates.comwrote in message
news:11**********************@q75g2000hsh.googlegr oups.com...
On May 2, 11:26 am, "Ignacio Machin \( .NET/ C# MVP \)" <machin TA
laceupsolutions.comwrote:
>I don't know of nothing like this. I have never seen a IDE with that
feature.

VB6 had this feature. It would break immediately after the line which
changed the watched value.

May 2 '07 #5
On Wed, 02 May 2007 09:30:04 -0700, Nicholas Paldino [.NET/C# MVP]
<mv*@spam.guard.caspershouse.comwrote:
Right, but that isn't what the OP wants. The OP wants to say "any
time any method/property in this class is accessed, break".
Actually, that's not how I read the OP either. While his first paragraph
seems to imply he wants to break "any time any method/property in this
class is accessed", as near as I can tell that's only because he didn't
write it very clearly. His second paragraph makes it pretty clear that
what he really does want is a data-based breakpoint, and while I haven't
looked for that in VS2005, it certainly has been present in previous
versions of that debugger and others. When putting the breakpoint on a
small enough variable, it can even be done using a hardware register,
allowing execution to happen at full speed.

It wouldn't surprise me if this is missing from VS Express, and it *would*
surprise me if it's missing in the retail versions of VS.

Pete
May 2 '07 #6
On Wed, 02 May 2007 10:00:52 -0700, Peter Duniho
<Np*********@nnowslpianmk.comwrote:
It wouldn't surprise me if this is missing from VS Express, and it
*would* surprise me if it's missing in the retail versions of VS.
Just looked. It's there, but not for C# or managed C++ code. Native
only. Doh.
May 2 '07 #7
Hi,

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.comwrote in
message news:OY**************@TK2MSFTNGP02.phx.gbl...
Right, but that isn't what the OP wants. The OP wants to say "any time
any method/property in this class is accessed, break".

The feature in VB allowed you to watch a value, and when it changed,
break.

Two very, very different things.
This is not what the OP wants, he wants to break as soon as any member of
the class is accesed.
May 2 '07 #8
Hi,

"it certainly has been present in previous
versions" ... indeed, I used it in VS 6.0 with C++.

But apparently it is not available anymore for managed code.

Anyway, thank you all for taking your time

Chris
*** Sent via Developersdex http://www.developersdex.com ***
May 3 '07 #9

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

Similar topics

7
2128
by: Mikael Östberg | last post by:
Hello all! I have been working on a project for some time now and yesterday, my debugger stopped working. It is a class library which I run from a Win32 test app, so no IIS involved at this...
16
4175
by: Serdar Kalaycý | last post by:
Hi everybody, My problem seems a bit clichè but I could not work around. Well I read lots of MSDN papers and discussions, but my problem is a bit different from them. When I tried to run the...
5
1129
by: Davids | last post by:
many of you probably remember using Response.Write(...) for debugging purposes, writing out the values of objects etc... How can I do the same with c#/ASP.Net ? It would be great to see some text...
3
1838
by: gaugust | last post by:
I am running Visual Studio .Net 2003 with Windows XP Pro and SP2. I am tying to run an ASP .Net application in debug mode. In Web.Config file I have set debug="true" but I am getting an error:...
5
7777
by: phnimx | last post by:
Hi , We have developed a number of plug-in .NET Library Components that we typically deploy with our various applications by installing them into the GAC. Each of the applications contains an...
4
2077
by: dbee | last post by:
Right. I've got a really, really annoying/difficult/time consuming problem with my development environment. I'm using django to build a web app with paypal integration. My server is hosted...
23
2231
by: mike3 | last post by:
Hi. I seem to have made some progress on finding that bug in my program. I deactivated everything in the bignum package that was used except for the returning of BigFloat objects. I even...
4
12674
by: =?Utf-8?B?TWlrZSBHYWxl?= | last post by:
VS 2008 initially didn't debug classic ASP. SP1 fixes this in some ways. You can debug if you select the debug option to "Start Without Debugging, then either attach the debugger manually or...
7
4092
by: GaryDean | last post by:
(this was also posted on the MSDN WCF forum but the answers over there are not so good) I have a WCF Library hosted by IIS 6 and it all works fine. However I need to step through the code in the...
0
7157
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
7379
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
7535
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...
1
7098
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
7521
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...
0
5682
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
3232
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1591
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
798
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.