Discussion:
Disappearing User Controls in VS 2005
(too old to reply)
ARayB
2007-06-27 12:18:27 UTC
Permalink
We've suddenly had all of the controls, user and otherwise
disappear from their containing form in VS2005 (SP1).
The form included a grid, labels, tab control and a number
of instances of a user control

The project compiles cleanly and the controls are all visible
at runtime just not anywhere to be seen in the ide.

I see MS has a fix for this a while back in VS 2003 but what
about 2005? Any experiences or advice??
Ciaran O''Donnell
2007-06-27 12:52:02 UTC
Permalink
Occasionaly i open a form in VS2005 and the form shows blank and of teh
default size. If i closed all the documents then open it again it is normally
sorted.
If this is working ok at runtime then it must a visual studio issue.

Do you get any error messages from it?
--
Ciaran O''Donnell
http://wannabedeveloper.spaces.live.com
Post by ARayB
We've suddenly had all of the controls, user and otherwise
disappear from their containing form in VS2005 (SP1).
The form included a grid, labels, tab control and a number
of instances of a user control
The project compiles cleanly and the controls are all visible
at runtime just not anywhere to be seen in the ide.
I see MS has a fix for this a while back in VS 2003 but what
about 2005? Any experiences or advice??
ARayB
2007-06-27 13:12:26 UTC
Permalink
On Jun 27, 8:52 am, Ciaran O''Donnell
Post by Ciaran O''Donnell
Occasionaly i open a form in VS2005 and the form shows blank and of teh
default size. If i closed all the documents then open it again it is normally
sorted.
If this is working ok at runtime then it must a visual studio issue.
Do you get any error messages from it?
Thanks for the response, Ciaran. We don't see any errors. The form
is the default size and all of the form code is remaining as are the
definitions
in the .designer.cs file for the form.
Post by Ciaran O''Donnell
Ciaran O''Donnellhttp://wannabedeveloper.spaces.live.com
Post by ARayB
We've suddenly had all of the controls, user and otherwise
disappear from their containing form in VS2005 (SP1).
The form included a grid, labels, tab control and a number
of instances of a user control
The project compiles cleanly and the controls are all visible
at runtime just not anywhere to be seen in the ide.
I see MS has a fix for this a while back in VS 2003 but what
about 2005? Any experiences or advice??-
Ignacio Machin ( .NET/ C# MVP )
2007-06-27 13:13:27 UTC
Permalink
Hi,
Post by ARayB
We've suddenly had all of the controls, user and otherwise
disappear from their containing form in VS2005 (SP1).
The form included a grid, labels, tab control and a number
of instances of a user control
The project compiles cleanly and the controls are all visible
at runtime just not anywhere to be seen in the ide.
I see MS has a fix for this a while back in VS 2003 but what
about 2005? Any experiences or advice??
This has happened to me before, not only that but the designer says that
there are some missing files (or other error) and that cannot display the
form.

I dont remember the exact solution but goes by closing the IDE, rebuild the
solution and try again.

BTW, did you updated to SP1?
ARayB
2007-06-27 13:25:38 UTC
Permalink
On Jun 27, 9:13 am, "Ignacio Machin \( .NET/ C# MVP \)" <machin TA
Post by Ignacio Machin ( .NET/ C# MVP )
Hi,
Post by ARayB
We've suddenly had all of the controls, user and otherwise
disappear from their containing form in VS2005 (SP1).
The form included a grid, labels, tab control and a number
of instances of a user control
The project compiles cleanly and the controls are all visible
at runtime just not anywhere to be seen in the ide.
I see MS has a fix for this a while back in VS 2003 but what
about 2005? Any experiences or advice??
This has happened to me before, not only that but the designer says that
there are some missing files (or other error) and that cannot display the
form.
I dont remember the exact solution but goes by closing the IDE, rebuild the
solution and try again.
BTW, did you updated to SP1?
Yes, we are using SP1. The 'we' being my coworker(running Vista) and
myself(XP Pro) and, BTW, the
problem appears on both our workstations in the same way. The
project's been
closed, reopened and recompiled multiple times on both machines.
Ignacio Machin ( .NET/ C# MVP )
2007-06-27 13:43:17 UTC
Permalink
Hi,
Post by ARayB
Yes, we are using SP1. The 'we' being my coworker(running Vista) and
myself(XP Pro) and, BTW, the
problem appears on both our workstations in the same way. The
project's been
closed, reopened and recompiled multiple times on both machines.
Check the code of that form (both the designer's code as well as yours) and
compare it to another form that is working fine.

Must probably the code is missing something that is required by the designer
but that runs fine.
Barfy the Wonder Camel
2007-06-27 17:00:56 UTC
Permalink
Post by ARayB
We've suddenly had all of the controls, user and otherwise
disappear from their containing form in VS2005 (SP1).
The form included a grid, labels, tab control and a number
of instances of a user control
The project compiles cleanly and the controls are all visible
at runtime just not anywhere to be seen in the ide.
I see MS has a fix for this a while back in VS 2003 but what
about 2005? Any experiences or advice??
have you looked at the Document Outline window? Maybe the offending
controls are placed behind something. Format -> Bring to Front might
fix it.
ARayB
2007-06-27 17:43:26 UTC
Permalink
Post by Barfy the Wonder Camel
Post by ARayB
We've suddenly had all of the controls, user and otherwise
disappear from their containing form in VS2005 (SP1).
The form included a grid, labels, tab control and a number
of instances of a user control
The project compiles cleanly and the controls are all visible
at runtime just not anywhere to be seen in the ide.
I see MS has a fix for this a while back in VS 2003 but what
about 2005? Any experiences or advice??
have you looked at the Document Outline window? Maybe the offending
controls are placed behind something. Format -> Bring to Front might
fix it.
Isn't the document outline window used for web forms? This is a
windows forms application.
In addition, not only are the controls missing but the form shows up
as the default size as
it would in a new project.
Barfy the Wonder Camel
2007-06-27 18:12:53 UTC
Permalink
Post by ARayB
Post by Barfy the Wonder Camel
Post by ARayB
We've suddenly had all of the controls, user and otherwise
disappear from their containing form in VS2005 (SP1).
The form included a grid, labels, tab control and a number
of instances of a user control
The project compiles cleanly and the controls are all visible
at runtime just not anywhere to be seen in the ide.
I see MS has a fix for this a while back in VS 2003 but what
about 2005? Any experiences or advice??
have you looked at the Document Outline window? Maybe the offending
controls are placed behind something. Format -> Bring to Front might
fix it.
Isn't the document outline window used for web forms? This is a
windows forms application.
In addition, not only are the controls missing but the form shows up
as the default size as
it would in a new project.- Hide quoted text -
- Show quoted text -
Heck no! I use the document outline on windows forms projects. It's
very handy for determining the heirarchy of containers and um
containees. Many times I've dropped a control on a panel (I thought)
only to have it get owned by the parent form or the tab control
because I didn't have the panel selected. I move it around in the
document outline and all is wonderful again.

As to your comment about the form, it almost sounds like it's a
different form from the one you think you're working on. I'd start
examining the other xxxx.designer.cs files in the partial class --
look at the actual control creation code. If it's even there.

You might also try (if you haven't already) removing the resx file.
ARayB
2007-06-27 19:20:16 UTC
Permalink
Post by Barfy the Wonder Camel
Post by ARayB
Post by Barfy the Wonder Camel
Post by ARayB
We've suddenly had all of the controls, user and otherwise
disappear from their containing form in VS2005 (SP1).
The form included a grid, labels, tab control and a number
of instances of a user control
The project compiles cleanly and the controls are all visible
at runtime just not anywhere to be seen in the ide.
I see MS has a fix for this a while back in VS 2003 but what
about 2005? Any experiences or advice??
have you looked at the Document Outline window? Maybe the offending
controls are placed behind something. Format -> Bring to Front might
fix it.
Isn't the document outline window used for web forms? This is a
windows forms application.
In addition, not only are the controls missing but the form shows up
as the default size as
it would in a new project.- Hide quoted text -
- Show quoted text -
Heck no! I use the document outline on windows forms projects. It's
very handy for determining the heirarchy of containers and um
containees. Many times I've dropped a control on a panel (I thought)
only to have it get owned by the parent form or the tab control
because I didn't have the panel selected. I move it around in the
document outline and all is wonderful again.
As to your comment about the form, it almost sounds like it's a
different form from the one you think you're working on. I'd start
examining the other xxxx.designer.cs files in the partial class --
look at the actual control creation code. If it's even there.
You might also try (if you haven't already) removing the resx file
One thing more that makes this a head-scratching problem is that
this is the only form in the project. The document outline is as empty
as the form is in the ide. ;-(

Loading...