By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
445,678 Members | 1,144 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 445,678 IT Pros & Developers. It's quick & easy.

How to Debug Design-Time support of ASP.NET Control

P: n/a
jim
I am trying to debug a user written web control and web control designer. I
found an article “Building Windows Forms Controls and Component with Rich
Design-Time Features” that describes how to setup debugging for a Windows
Form control. I cannot find any documentation or articles on setting up the
same facility for a Web control.

Any help on setting the control library project to debug the design-time
code would be greatly appreciated.

Jim

Nov 18 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
Unless the Control was compiled with debugging symbols, you're SOL.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Neither a follower
nor a lender be.

"jim" <ji*@cherokee.com> wrote in message
news:B8**********************************@microsof t.com...
I am trying to debug a user written web control and web control designer. I found an article "Building Windows Forms Controls and Component with Rich
Design-Time Features" that describes how to setup debugging for a Windows
Form control. I cannot find any documentation or articles on setting up the same facility for a Web control.

Any help on setting the control library project to debug the design-time
code would be greatly appreciated.

Jim

Nov 18 '05 #2

P: n/a
jim
Sorry I left out that the project consist of a test web page and the control
library. Both are being built with the debugger. I am trying to debug the
design-time code of the control while Visual Studio 2003 is in the web page
designer of the test web page.

Jim

"Kevin Spencer" wrote:
Unless the Control was compiled with debugging symbols, you're SOL.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Neither a follower
nor a lender be.

"jim" <ji*@cherokee.com> wrote in message
news:B8**********************************@microsof t.com...
I am trying to debug a user written web control and web control designer.

I
found an article "Building Windows Forms Controls and Component with Rich
Design-Time Features" that describes how to setup debugging for a Windows
Form control. I cannot find any documentation or articles on setting up

the
same facility for a Web control.

Any help on setting the control library project to debug the design-time
code would be greatly appreciated.

Jim


Nov 18 '05 #3

P: n/a
You need to run another instance of Visual Studio and use it to debug first
instance of VS that loads and instantiates the control.

1. Create a project for the Web control. Set executable to run to
devenv.exe.
2. Build the control library.
3. Set breakpoint in the control constructor.
4. F5. Ignore warning that devenv.exe has no symbols.
5. In the new instance of VS open/create a Web app project.
6. New Web form, add your control to the page.

At this point BP in the control constructor should get hit.

Thanks
Mikhail Arkhipov (Microsoft)
-- This post is provided 'AS IS' with no warranties and confers no rights.

On 11/29/04 14:39, in article
46**********************************@microsoft.com, "jim" <ji*@cherokee.com>
wrote:
Sorry I left out that the project consist of a test web page and the control
library. Both are being built with the debugger. I am trying to debug the
design-time code of the control while Visual Studio 2003 is in the web page
designer of the test web page.

Jim

"Kevin Spencer" wrote:
Unless the Control was compiled with debugging symbols, you're SOL.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Neither a follower
nor a lender be.

"jim" <ji*@cherokee.com> wrote in message
news:B8**********************************@microsof t.com...
I am trying to debug a user written web control and web control designer.

I
found an article "Building Windows Forms Controls and Component with Rich
Design-Time Features" that describes how to setup debugging for a Windows
Form control. I cannot find any documentation or articles on setting up

the
same facility for a Web control.

Any help on setting the control library project to debug the design-time
code would be greatly appreciated.

Jim


Nov 18 '05 #4

P: n/a
jim
Mikhail,

Ok, here is the scoop. I could not set the Start Application property
because it was disabled even though the Debug Mode was set to “Program”.
Now the reason for this follows.

The Web Control Library’s default Debug Mode is set to “Project”. The other
properties states in the Start Action branch are initially set as:
· Start Application – (Disabled)
· Start URL – (Disabled)
· Start Page – (Enabled)

Changing the Debug Mode ComboBox to “Program” does not change the state of
the other properties in the Start Action branch. Therefore I could not set
the ‘Start Application”.

Now one very important step was missing from all the instructions. It seems
you need to click the “Apply” button after changing the Debug Mode ComboBox
selection. Being a person who never clicks the “Apply” button until all his
changes are made (just incase I want to cancel) caused the problem.

To me there seems to be a problem in Visual Studio’s Debug Mode ComboBox;
the SelectedIndexChanged event is not programmed to change the enable state
of the Start Application, Start URL, or Start Page properties when the
appropriate entry is selected. Having to click the “Apply” button is not
always obvious!

So for fellow I’ll click a button when I am done please update the
instructions, fix the ComboBox event, or make it obvious.
Regards,

Jim

"Mikhail Arkhipov (Microsoft)" wrote:
You need to run another instance of Visual Studio and use it to debug first
instance of VS that loads and instantiates the control.

1. Create a project for the Web control. Set executable to run to
devenv.exe.
2. Build the control library.
3. Set breakpoint in the control constructor.
4. F5. Ignore warning that devenv.exe has no symbols.
5. In the new instance of VS open/create a Web app project.
6. New Web form, add your control to the page.

At this point BP in the control constructor should get hit.

Thanks
Mikhail Arkhipov (Microsoft)
-- This post is provided 'AS IS' with no warranties and confers no rights.

On 11/29/04 14:39, in article
46**********************************@microsoft.com, "jim" <ji*@cherokee.com>
wrote:
Sorry I left out that the project consist of a test web page and the control
library. Both are being built with the debugger. I am trying to debug the
design-time code of the control while Visual Studio 2003 is in the web page
designer of the test web page.

Jim

"Kevin Spencer" wrote:
Unless the Control was compiled with debugging symbols, you're SOL.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Neither a follower
nor a lender be.

"jim" <ji*@cherokee.com> wrote in message
news:B8**********************************@microsof t.com...
I am trying to debug a user written web control and web control designer.
I
found an article "Building Windows Forms Controls and Component with Rich
Design-Time Features" that describes how to setup debugging for a Windows
Form control. I cannot find any documentation or articles on setting up
the
same facility for a Web control.

Any help on setting the control library project to debug the design-time
code would be greatly appreciated.

Jim


Nov 18 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.