.NETGURU
*NOT ANSWERED* Debugging inside custom server controls
Messages   Related Types
This message was discovered on ASPFriends.com 'aspngdebug' list.


Frans, Stephen
I cannot debug inside a custom server control.

The ASPX page references it correctly <@Register...> and the controls get
loaded on the page. So far so good. But if I set a break point inside the
control (in a function or accessor), when I run the hosting web page the
debugger totally ignores the server control breakpoint.

Another potentially anomalous thing is that unless I manually compile the
control (using vbc) and copy the DLL into the \bin folder of my web project
as a separate step (as opposed to simply doing Rebuild inside of VS), I
cannot even run my web page that references the custom control. This is OK,
but I suspect that this may be related to the debug problem. It looks like
as far as compile switches, the default is set to debug:all, so I'm guessing
that it has what it needs inside the DLL to debug.

I've tried a couple of things:

(1) Created a separate project to house my server control versus maintaining
the .vb file within my web project -- it made no difference; I even tried to
set the server control project to be the startup project (which it would not
allow) hoping that it would allow debugging then.
(2) Installed VS.NET RC instead of Beta 2 (slicked my machine, etc.),
thinking that it might be a Beta 2 issue - no difference (although the RC is
nice).

I cannot figure out what's wrong with my control, so I really need to debug
inside the control.

Anyone have any thoughts on what might be the problem?

TIA,

Steve
Reply to this message...
 
    
Mike Amundsen
you talking about a User Control (*.ascx file) or a compiled Server Control
(*.dll)?

if you are talking about a Server Control DLL, you need to compile the DLL
with the DEBUG option turned on. I do this often with the command line
compiler, but hsven't done this yet with VS.NET. should not be too tough.

if your'e talking about User control ASCX files, you can add the
debug='true' attribute to the control declaration at the top of the page.

again, I use the stand alone debugger to test this and it works fine in both
cases. Not sure about the VS.NET, but it should also work just fine.

FWIW, i am using beta2 to test this.

MCA

-----Original Message-----
From: Frans, Stephen [mailto:Click here to reveal e-mail address]
Sent: Thursday, December 06, 2001 9:26 AM
To: aspngdebug
Subject: [aspngdebug] *NOT ANSWERED* Debugging inside custom server
controls

I cannot debug inside a custom server control.

The ASPX page references it correctly <@Register...> and the controls get
loaded on the page. So far so good. But if I set a break point inside the
control (in a function or accessor), when I run the hosting web page the
debugger totally ignores the server control breakpoint.

Another potentially anomalous thing is that unless I manually compile the
control (using vbc) and copy the DLL into the \bin folder of my web project
as a separate step (as opposed to simply doing Rebuild inside of VS), I
cannot even run my web page that references the custom control. This is OK,
but I suspect that this may be related to the debug problem. It looks like
as far as compile switches, the default is set to debug:all, so I'm guessing
that it has what it needs inside the DLL to debug.

I've tried a couple of things:

(1) Created a separate project to house my server control versus
maintaining the .vb file within my web project -- it made no difference; I
even tried to set the server control project to be the startup project
(which it would not allow) hoping that it would allow debugging then.

(2) Installed VS.NET RC instead of Beta 2 (slicked my machine, etc.),
thinking that it might be a Beta 2 issue - no difference (although the RC is
nice).

I cannot figure out what's wrong with my control, so I really need to
debug inside the control.

Anyone have any thoughts on what might be the problem?

TIA,

Steve

| [aspngdebug] member Click here to reveal e-mail address = YOUR ID
| http://www.asplists.com/asplists/aspngreuse.asp = JOIN/QUIT
| http://www.asplists.com/search = SEARCH Archives
Reply to this message...
 
 




ExamGuru IT Solutions - .Net Guru is owned and operated by ExamGuru, Inc., the man behind .Net Guru. If you're in the market for bespoke software or software consultancy, why not get him and his highly trained team to help? - www.examguru.net/ITCertification
Ad


Need Dot Net Interview Questions?
Ask ExamGuru, Inc. for advice and help on Passing .Net Interviews
.Net Projects
Best-of-breed application framework for .NET projects, developed by ExamGuru, Inc. and ExamGuru IT
Free .net Help
Commission ExamGuru, Inc. and his team for your next bespoke software project
FogBUGZ
The only bug tracking system carefully crafted with one goal in mind: helping teams create great software.
Awesome Tools
If you don't know about these, you're missing out... IT Certification Questions
IT Interview Questions
Free Oracle 10g Training
MCSE Boortcamp
Cisco Study Guides
Cheap Study Guides
Exact Questions
Dot Net Interview Questions
Oracle OCP
Cheap Travel
Designer Perfumes - Wholesale Prices
Free Programming Tutorials
 
ExamGuru IT Solutions - .Net Guru is owned and operated by ExamGuru, Inc., the man behind .Net Guru. If you're in the market for bespoke software or software consultancy, why not get him and his highly trained team to help? - www.examguru.net/ITCertification
 Copyright © ExamGuru, Inc. 2001-2006
Contact Us - Terms of Use - Privacy Policy - www.dot-net-guru.com - www.examguru.net - www.oraclesource.net - www.itinterviews.net - www.examguru.net/ITCertification