473,395 Members | 1,412 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.

form designer

Hi,

I need a help. I have form inherited from other form. The base form
implementation is placed in other assembly. I try to open my inherited form
in designer but visual studio throws an exception. My question is: "how can
I debug visual studio form designer?" As I remember in Visual 6.0 it was
possible by running two visual session and attaching first one to the
second. Unfortunately in VS .NET 2005 it seems that it doesn't work.
What is the solution?

Thanks.

Jurek
Oct 4 '06 #1
6 1861
Assuming that your other form is in a project, don't reference the assembly;
include the project in the solution that uses it. You can include the same
project in many solutions.

--
HTH,

Kevin Spencer
Microsoft MVP
Software Composer
http://unclechutney.blogspot.com

If the Truth hurts, wear it.

"Arkadiusz Smolak" <as******@poczta.onet.plwrote in message
news:%2***************@TK2MSFTNGP03.phx.gbl...
Hi,

I need a help. I have form inherited from other form. The base form
implementation is placed in other assembly. I try to open my inherited
form in designer but visual studio throws an exception. My question is:
"how can I debug visual studio form designer?" As I remember in Visual 6.0
it was possible by running two visual session and attaching first one to
the second. Unfortunately in VS .NET 2005 it seems that it doesn't work.
What is the solution?

Thanks.

Jurek

Oct 4 '06 #2
On Oct 4, 8:12 am, "Arkadiusz Smolak" <as_sh...@poczta.onet.plwrote:
Hi,

I need a help. I have form inherited from other form. The base form
implementation is placed in other assembly. I try to open my inherited form
in designer but visual studio throws an exception. My question is: "how can
I debug visual studio form designer?" As I remember in Visual 6.0 it was
possible by running two visual session and attaching first one to the
second. Unfortunately in VS .NET 2005 it seems that it doesn't work.
What is the solution?
Is this the sort of information you're looking for:
http://msdn2.microsoft.com/en-us/library/5ytx0z24.aspx

Oct 4 '06 #3
Thank you for the answer. I saw this article earlier and it's about debuging
Custom Windows Forms Controls at Design Time. Unfortunetely I don't know how
to aply it to debugging form. It seems that framework doesn't call my form
constructor when I open it in designer.

Arek

"Bruce Wood" <br*******@canada.comwrote in message
news:11**********************@b28g2000cwb.googlegr oups.com...
On Oct 4, 8:12 am, "Arkadiusz Smolak" <as_sh...@poczta.onet.plwrote:
>Hi,

I need a help. I have form inherited from other form. The base form
implementation is placed in other assembly. I try to open my inherited
form
in designer but visual studio throws an exception. My question is: "how
can
I debug visual studio form designer?" As I remember in Visual 6.0 it was
possible by running two visual session and attaching first one to the
second. Unfortunately in VS .NET 2005 it seems that it doesn't work.
What is the solution?

Is this the sort of information you're looking for:
http://msdn2.microsoft.com/en-us/library/5ytx0z24.aspx

Oct 5 '06 #4
No... the Designer calls the constructor of your form's _base class_
when you open it in the Designer. If you want to debug your form's
constructor as it applies at design time, you have to open a form
_derived_ from your form. Then the Designer will run your form's
constuctor.

Arkadiusz Smolak wrote:
Thank you for the answer. I saw this article earlier and it's about debuging
Custom Windows Forms Controls at Design Time. Unfortunetely I don't know how
to aply it to debugging form. It seems that framework doesn't call my form
constructor when I open it in designer.

Arek

"Bruce Wood" <br*******@canada.comwrote in message
news:11**********************@b28g2000cwb.googlegr oups.com...
On Oct 4, 8:12 am, "Arkadiusz Smolak" <as_sh...@poczta.onet.plwrote:
Hi,

I need a help. I have form inherited from other form. The base form
implementation is placed in other assembly. I try to open my inherited
form
in designer but visual studio throws an exception. My question is: "how
can
I debug visual studio form designer?" As I remember in Visual 6.0 it was
possible by running two visual session and attaching first one to the
second. Unfortunately in VS .NET 2005 it seems that it doesn't work.
What is the solution?
Is this the sort of information you're looking for:
http://msdn2.microsoft.com/en-us/library/5ytx0z24.aspx
Oct 5 '06 #5
Unfortunetely it doesn't work for me. I have to VS studio opened. The first
one I'm attaching to the socond proccess nad set breakpoint in form
constructor (it's my derrived form) then I'm switching to the second
instance and opening form in designer. The debugger from first session
doesn't stop in constructor.

Arek

"Bruce Wood" <br*******@canada.comwrote in message
news:11**********************@c28g2000cwb.googlegr oups.com...
No... the Designer calls the constructor of your form's _base class_
when you open it in the Designer. If you want to debug your form's
constructor as it applies at design time, you have to open a form
_derived_ from your form. Then the Designer will run your form's
constuctor.

Arkadiusz Smolak wrote:
>Thank you for the answer. I saw this article earlier and it's about
debuging
Custom Windows Forms Controls at Design Time. Unfortunetely I don't know
how
to aply it to debugging form. It seems that framework doesn't call my
form
constructor when I open it in designer.

Arek

"Bruce Wood" <br*******@canada.comwrote in message
news:11**********************@b28g2000cwb.googleg roups.com...
On Oct 4, 8:12 am, "Arkadiusz Smolak" <as_sh...@poczta.onet.plwrote:
Hi,

I need a help. I have form inherited from other form. The base form
implementation is placed in other assembly. I try to open my inherited
form
in designer but visual studio throws an exception. My question is:
"how
can
I debug visual studio form designer?" As I remember in Visual 6.0 it
was
possible by running two visual session and attaching first one to the
second. Unfortunately in VS .NET 2005 it seems that it doesn't work.
What is the solution?

Is this the sort of information you're looking for:
http://msdn2.microsoft.com/en-us/library/5ytx0z24.aspx

Oct 17 '06 #6

Arkadiusz Smolak wrote:
Unfortunetely it doesn't work for me. I have to VS studio opened. The first
one I'm attaching to the socond proccess nad set breakpoint in form
constructor (it's my derrived form) then I'm switching to the second
instance and opening form in designer. The debugger from first session
doesn't stop in constructor.

Arek
I'm afraid I don't quite follow what you're doing. The idea goes
something like this:

public class MyForm : System.WIndows.Forms.Form
{
public MyForm()
{
... my form's constructor code ...
}
}

public class MyDerivedForm : MyForm
{
public MyDerivedForm()
{
... usual constructor stuff ...
}
}

If you set Visual Studio as the startup program for your project, then
set a breakpoint inside the MyForm constructor, the constructor should
run if you open MyDerivedForm in the Visual Studio Designer. If you
open MyForm in the Designer, then the breakpoint will not be hit, since
the constructor that is running is that for System.Windows.Forms.Form,
not MyForm. The Designer runs the MyForm constructor only when
designing MyDerivedForm.

Is that what you're doing and it still doesn't work for you?

Oct 17 '06 #7

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

Similar topics

3
by: Chris | last post by:
Hi, I'm trying to append text from another class to a generic richTextBox that I've added to a Windows form. I can't seem to figure out how to expose the richTextBox to append text to it. ...
2
by: Jaikumar | last post by:
Hi, 1) I have created one windows application, In the main form ( form1) i have added one usercontrol (usercontrol1), In that user control i am drawing one image. 2) In the UserControl1 i am...
2
by: baret bonden | last post by:
Trying to return a selected listbox item to another form .tried lots of ways; defining public variables and passing those as well as textboxes ..I' m able to display the chosen item on it's form...
18
by: Jan Nielsen | last post by:
Hi I have a main form showing personal information (name, address etc.) bound to a dataset. One of the pieces of information is the Group the person belongs to. This is selected from a combo box....
0
by: Amiram Korach | last post by:
When you create a MDI form, you can attach a main menu to the parent and to the child. When a child form is active, its menu is merged with the parent menu. The problem is: when the forms are...
4
by: Rod Gill | last post by:
Hi, I have a form that when opened in the designer appears of the screen. The form selector can't be dragged (or resized) and if I scroll right and down to centralise it the form simply jumps...
7
by: Terry | last post by:
I have a Mainform with a Statusbar. When opening another form or doing some processing I want to display info in the Statusbar of the Mainform. I have read a lot of articles on this & have come up...
4
by: ThunderMusic | last post by:
Hi, I have a custom form that works fine when I debug it or run it in release mode but cannot be loaded in the designer... Actually, it can be loaded in the designer when no control is on it, but...
8
by: TomC | last post by:
I want to bypass the Windows Form Designer in VS, to create a form programmatically. The elements of the form are to be arranged in a table, and I want the size of the table (and therefore the...
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: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
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...

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.