Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Visual Studio.NET / Debugging / June 2004

Tip: Looking for answers? Try searching our database.

IDE is changing design mode settings when compiling

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Jonas L - 22 Jun 2004 17:01 GMT
I have run into a problem that I can't understand and it is becoming
really annoying.

The problem occurs when I compile my solution. When compiling the
IDE(?) sometimes removes properties that are set in the "Designer
generated code" region.

Let me give you an example...

In one of my forms I have a standard TabControl, placed on the form by
draging and dropping from the toolbox. It has the Dock property set to
'Fill'. Two TabPage's have been added to the TabControl by clicking on
the TabPages property in the Properties Windows. On both of these tab
pages there are other control's (textbox, datagrid etc).

When compiling something happen. The TabControl is nolonger filling my
form, it's possitioned in the upper left corner of the form and it has
no TabPages.

Looking in "Designer generated code" region I have the following code

//
// tabControl1
//
this.tabControl1.Location = new System.Drawing.Point(0, 0);
this.tabControl1.Name = "tabControl1";
this.tabControl1.SelectedIndex = 0;
this.tabControl1.TabIndex = 0;
//
// tabPage1
//
this.tabPage1.Location = new System.Drawing.Point(0, 0);
this.tabPage1.Name = "tabPage1";
this.tabPage1.TabIndex = 0;
//
// tabPage2
//
this.tabPage2.Location = new System.Drawing.Point(0, 0);
this.tabPage2.Name = "tabPage2";
this.tabPage2.TabIndex = 0;

Normally i.e. the TabControl has more properties set like this...

this.tabControl1.Controls.Add(this.tabPage1);
this.tabControl1.Controls.Add(this.tabPage2);
this.tabControl1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tabControl1.Size = new System.Drawing.Size(410, 335);
etc...

Looking further in the "Designer generated code" region, all control's
that has been draged-and-dropped on to the form has its Location
property set to System.Drawing.Point(0, 0). Unfortunately, I don't
know which properties that are normally set by the IDE so I don't know
which other properities are changed or is missing/removed.

Has anyone else had this problem?
What am I doing wrong?
How can I fix this? Is there a "undo" for this? Today I have to
re-create the form :(

Thanks!

BR
Jonas
Giacomo - 22 Jun 2004 23:29 GMT
Do you use sourcesafe?   I ask because this is a problem common to having an
older binary (.frx as opposed to .frm) somewhere.  Another guess may be that
you have right protected an old version of the binary ".frx"?
Giac
> I have run into a problem that I can't understand and it is becoming
> really annoying.
[quoted text clipped - 60 lines]
> BR
> Jonas
Jonas L - 23 Jun 2004 07:20 GMT
No, I don't use any version handling software, but I have CVS NT
installed on the same PC.

Regarding the .frx binary. Is that a file that is associated with
SourceSafe?

/Jonas

> Do you use sourcesafe?   I ask because this is a problem common to having an
> older binary (.frx as opposed to .frm) somewhere.  Another guess may be that
[quoted text clipped - 64 lines]
> > BR
> > Jonas

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.