VB 2005 Express false compiler error
I have a VB 2005 WinForms Project which is giving what I think is a false error.
On the Designer screen for the main form (which normally displays the form layout etc.) I get:
| One or more errors encountered while loading the designer. The errors are listed below. Some errors can be fixed by rebuilding your project, while others may require code changes. |
'.ctor' is not a valid identifier.Hide |
at Microsoft.VisualStudio.Shell.Design.Serialization.CodeDom.CodeDomEventBindingService.ValidateMethodName(String methodName) at System.ComponentModel.Design.EventBindingService.EventPropertyDescriptor.SetValue(Object component, Object value) at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeAttachEventStatement(IDesignerSerializationManager manager, CodeAttachEventStatement statement) at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeStatement(IDesignerSerializationManager manager, CodeStatement statement)
|
The report in the Error List leaves the File and Project blank, and gives a Line and Column number of zero. Double clicking on the error report goes nowhere.
I have searched for ".ctor" and it does not appear anywhere in the project. Rebuilding succeeds, but does not remove the error. It is still there after closing down & reloading.
I don't know how to get back to a position where the project file is usable at all. Can you help me find/remove/work around this please?
Regards, Tony.
Does any of your controlshave any methods, properties or events called New?
I have a form (not that giving the error) with two constructors as follows:
Public Sub New(ByVal id As Integer, ByVal adult As Boolean)' Constructor to Edit an existing Person with Id givenMyBase.New()'This call is required by the Windows Form Designer.InitializeComponent()
PAddPerson =
FalsePId = id
PAdult = adult
PName =
""End SubPublic Sub New(ByVal addName As String, ByVal adult As Boolean)' Constructor to Edit an existing Person with Id givenMyBase.New()'This call is required by the Windows Form Designer.InitializeComponent()
PAddPerson =
TruePId = -1
PAdult = adult
PName = addName
End Sub
They used to work OK -- I did not change this area to cause the error to appear (as far as I can remember what I changed).
Rgds, Tony.
Can you post the code inside the "IntializeComponent" method?
There seems to be quite a lot of it, but here it is.
'Required by the Windows Form DesignerPrivate components As System.ComponentModel.IContainer'NOTE: The following procedure is required by the Windows Form Designer'It can be modified using the Windows Form Designer. 'Do not modify it using the code editor.<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()Me.components = New System.ComponentModel.ContainerDim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(FPerson))Me.PHeader = New System.Windows.Forms.PanelMe.PictureBox1 = New System.Windows.Forms.PictureBoxMe.Label2 = New System.Windows.Forms.LabelMe.Label1 = New System.Windows.Forms.LabelMe.PFooter = New System.Windows.Forms.TableLayoutPanelMe.Button1 = New System.Windows.Forms.ButtonMe.Button2 = New System.Windows.Forms.ButtonMe.Button6 = New System.Windows.Forms.ButtonMe.Button5 = New System.Windows.Forms.ButtonMe.Button4 = New System.Windows.Forms.ButtonMe.Button3 = New System.Windows.Forms.ButtonMe.PTop = New System.Windows.Forms.PanelMe.Label19 = New System.Windows.Forms.LabelMe.Label18 = New System.Windows.Forms.LabelMe.BtnAddParent = New System.Windows.Forms.ButtonMe.Label17 = New System.Windows.Forms.LabelMe.Label16 = New System.Windows.Forms.LabelMe.CBName = New System.Windows.Forms.ComboBoxMe.BSPersonName = New System.Windows.Forms.BindingSource(Me.components)Me.DSPerson = New ACE.DSClsPersonMe.Label3 = New System.Windows.Forms.LabelMe.TBChildSurname = New System.Windows.Forms.TextBoxMe.BSChild = New System.Windows.Forms.BindingSource(Me.components)Me.TBChildForename = New System.Windows.Forms.TextBoxMe.Label15 = New System.Windows.Forms.LabelMe.CBTitle = New System.Windows.Forms.ComboBoxMe.BSPerson = New System.Windows.Forms.BindingSource(Me.components)Me.Label5 = New System.Windows.Forms.LabelMe.TBSurname = New System.Windows.Forms.TextBoxMe.Label4 = New System.Windows.Forms.LabelMe.TBForename = New System.Windows.Forms.TextBoxMe.LTitle = New System.Windows.Forms.LabelMe.PBottom = New System.Windows.Forms.PanelMe.ChkBArtists = New System.Windows.Forms.CheckBoxMe.ChkBGeneral = New System.Windows.Forms.CheckBoxMe.ChkBMember = New System.Windows.Forms.CheckBoxMe.Label14 = New System.Windows.Forms.LabelMe.TBAddress1 = New System.Windows.Forms.TextBoxMe.Label13 = New System.Windows.Forms.LabelMe.Label6 = New System.Windows.Forms.LabelMe.TBEMail = New System.Windows.Forms.TextBoxMe.TBAddress2 = New System.Windows.Forms.TextBoxMe.Label12 = New System.Windows.Forms.LabelMe.Label7 = New System.Windows.Forms.LabelMe.TBPhone2 = New System.Windows.Forms.TextBoxMe.TBAddress3 = New System.Windows.Forms.TextBoxMe.Label11 = New System.Windows.Forms.LabelMe.Label8 = New System.Windows.Forms.LabelMe.TBPhone1 = New System.Windows.Forms.TextBoxMe.TBAddress4 = New System.Windows.Forms.TextBoxMe.Label10 = New System.Windows.Forms.LabelMe.Label9 = New System.Windows.Forms.LabelMe.TBPostcode = New System.Windows.Forms.TextBoxMe.ErrorProvider1 = New System.Windows.Forms.ErrorProvider(Me.components)Me.TAPerson = New ACE.DSClsPersonTableAdapters.PersonTableAdapterMe.TAPersonName = New ACE.DSClsPersonTableAdapters.PersonNameTableAdapterMe.TAChild = New ACE.DSClsPersonTableAdapters.ChildTableAdapterMe.ToolTip1 = New System.Windows.Forms.ToolTip(Me.components)Me.HelpProvider1 = New System.Windows.Forms.HelpProviderMe.PHeader.SuspendLayout()CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()Me.PFooter.SuspendLayout()Me.PTop.SuspendLayout()CType(Me.BSPersonName, System.ComponentModel.ISupportInitialize).BeginInit()CType(Me.DSPerson, System.ComponentModel.ISupportInitialize).BeginInit()CType(Me.BSChild, System.ComponentModel.ISupportInitialize).BeginInit()CType(Me.BSPerson, System.ComponentModel.ISupportInitialize).BeginInit()Me.PBottom.SuspendLayout()CType(Me.ErrorProvider1, System.ComponentModel.ISupportInitialize).BeginInit()Me.SuspendLayout()''PHeader'Me.PHeader.BackColor = System.Drawing.Color.LightSkyBlueMe.PHeader.Controls.Add(Me.PictureBox1)Me.PHeader.Controls.Add(Me.Label2)Me.PHeader.Controls.Add(Me.Label1)Me.PHeader.Dock = System.Windows.Forms.DockStyle.TopMe.PHeader.Location = New System.Drawing.Point(0, 0)Me.PHeader.Name = "PHeader"Me.PHeader.Size = New System.Drawing.Size(517, 84)Me.PHeader.TabIndex = 1''PictureBox1'Me.PictureBox1.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)Me.PictureBox1.Image = CType(resources.GetObject("PictureBox1.Image"), System.Drawing.Image)Me.PictureBox1.Location = New System.Drawing.Point(437, 9)Me.PictureBox1.Name = "PictureBox1"Me.PictureBox1.Size = New System.Drawing.Size(68, 63)Me.PictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImageMe.PictureBox1.TabIndex = 2Me.PictureBox1.TabStop = False''Label2'Me.Label2.AutoSize = TrueMe.Label2.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.25!, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Point, CType(0, Byte))Me.Label2.Location = New System.Drawing.Point(14, 49)Me.Label2.Name = "Label2"Me.Label2.Size = New System.Drawing.Size(240, 24)Me.Label2.TabIndex = 1Me.Label2.Text = "Add Details for New Person"''Label1'Me.Label1.AutoSize = TrueMe.Label1.Font = New System.Drawing.Font("Microsoft Sans Serif", 20.25!, CType((System.Drawing.FontStyle.Bold Or System.Drawing.FontStyle.Italic), System.Drawing.FontStyle), System.Drawing.GraphicsUnit.Point, CType(0, Byte))Me.Label1.Location = New System.Drawing.Point(12, 9)Me.Label1.Name = "Label1"Me.Label1.Size = New System.Drawing.Size(264, 31)Me.Label1.TabIndex = 0Me.Label1.Text = "PERSON DETAILS"''PFooter'Me.PFooter.CausesValidation = FalseMe.PFooter.ColumnCount = 6Me.PFooter.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 12.5!))Me.PFooter.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 12.5!))Me.PFooter.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 12.5!))Me.PFooter.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 12.5!))Me.PFooter.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 12.5!))Me.PFooter.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 12.5!))Me.PFooter.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20.0!))Me.PFooter.ColumnStyles.Add(New System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 20.0!))Me.PFooter.Controls.Add(Me.Button1, 0, 0)Me.PFooter.Controls.Add(Me.Button2, 1, 0)Me.PFooter.Controls.Add(Me.Button6, 5, 0)Me.PFooter.Controls.Add(Me.Button5, 4, 0)Me.PFooter.Controls.Add(Me.Button4, 3, 0)Me.PFooter.Controls.Add(Me.Button3, 2, 0)Me.PFooter.Dock = System.Windows.Forms.DockStyle.BottomMe.PFooter.Location = New System.Drawing.Point(0, 458)Me.PFooter.Name = "PFooter"Me.PFooter.RowCount = 1Me.PFooter.RowStyles.Add(New System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100.0!))Me.PFooter.Size = New System.Drawing.Size(517, 41)Me.PFooter.TabIndex = 3''Button1'Me.Button1.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _Or System.Windows.Forms.AnchorStyles.Left) _Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)Me.Button1.BackColor = System.Drawing.Color.SandyBrownMe.HelpProvider1.SetHelpKeyword(Me.Button1, "Personal Details.htm")Me.HelpProvider1.SetHelpNavigator(Me.Button1, System.Windows.Forms.HelpNavigator.Topic)Me.Button1.Location = New System.Drawing.Point(0, 0)Me.Button1.Margin = New System.Windows.Forms.Padding(0)Me.Button1.Name = "Button1"Me.HelpProvider1.SetShowHelp(Me.Button1, True)Me.Button1.Size = New System.Drawing.Size(86, 41)Me.Button1.TabIndex = 0Me.Button1.Text = "HELP"Me.ToolTip1.SetToolTip(Me.Button1, "F1 - Help")Me.Button1.UseVisualStyleBackColor = False''Button2'Me.Button2.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _Or System.Windows.Forms.AnchorStyles.Left) _Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)Me.Button2.BackColor = System.Drawing.Color.SandyBrownMe.Button2.Location = New System.Drawing.Point(86, 0)Me.Button2.Margin = New System.Windows.Forms.Padding(0)Me.Button2.Name = "Button2"Me.Button2.Size = New System.Drawing.Size(86, 41)Me.Button2.TabIndex = 1Me.Button2.Text = "Button2"Me.ToolTip1.SetToolTip(Me.Button2, "F2")Me.Button2.UseVisualStyleBackColor = FalseMe.Button2.Visible = False''Button6'Me.Button6.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _Or System.Windows.Forms.AnchorStyles.Left) _Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)Me.Button6.BackColor = System.Drawing.Color.SandyBrownMe.Button6.Location = New System.Drawing.Point(430, 0)Me.Button6.Margin = New System.Windows.Forms.Padding(0)Me.Button6.Name = "Button6"Me.Button6.Size = New System.Drawing.Size(87, 41)Me.Button6.TabIndex = 5Me.Button6.Text = "ACCEPT"Me.ToolTip1.SetToolTip(Me.Button6, "F8 - OK / Accept")Me.Button6.UseVisualStyleBackColor = False''Button5'Me.Button5.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _Or System.Windows.Forms.AnchorStyles.Left) _Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)Me.Button5.BackColor = System.Drawing.Color.SandyBrownMe.Button5.CausesValidation = FalseMe.Button5.DialogResult = System.Windows.Forms.DialogResult.CancelMe.Button5.Location = New System.Drawing.Point(344, 0)Me.Button5.Margin = New System.Windows.Forms.Padding(0)Me.Button5.Name = "Button5"Me.Button5.Size = New System.Drawing.Size(86, 41)Me.Button5.TabIndex = 4Me.Button5.Text = "CANCEL"Me.ToolTip1.SetToolTip(Me.Button5, "F7 - Cancel")Me.Button5.UseVisualStyleBackColor = False''Button4'Me.Button4.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _Or System.Windows.Forms.AnchorStyles.Left) _Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)Me.Button4.BackColor = System.Drawing.Color.SandyBrownMe.Button4.Location = New System.Drawing.Point(258, 0)Me.Button4.Margin = New System.Windows.Forms.Padding(0)Me.Button4.Name = "Button4"Me.Button4.Size = New System.Drawing.Size(86, 41)Me.Button4.TabIndex = 3Me.Button4.Text = "SHOW HISTORY"Me.ToolTip1.SetToolTip(Me.Button4, "F6")Me.Button4.UseVisualStyleBackColor = False''Button3'Me.Button3.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _Or System.Windows.Forms.AnchorStyles.Left) _Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)Me.Button3.BackColor = System.Drawing.Color.SandyBrownMe.Button3.Location = New System.Drawing.Point(172, 0)Me.Button3.Margin = New System.Windows.Forms.Padding(0)Me.Button3.Name = "Button3"Me.Button3.Size = New System.Drawing.Size(86, 41)Me.Button3.TabIndex = 2Me.Button3.Text = "JOIN/RENEW"Me.ToolTip1.SetToolTip(Me.Button3, "F5")Me.Button3.UseVisualStyleBackColor = False''PTop'Me.PTop.Controls.Add(Me.Label19)Me.PTop.Controls.Add(Me.Label18)Me.PTop.Controls.Add(Me.BtnAddParent)Me.PTop.Controls.Add(Me.Label17)Me.PTop.Controls.Add(Me.Label16)Me.PTop.Controls.Add(Me.CBName)Me.PTop.Controls.Add(Me.Label3)Me.PTop.Controls.Add(Me.TBChildSurname)Me.PTop.Controls.Add(Me.TBChildForename)Me.PTop.Controls.Add(Me.Label15)Me.PTop.Dock = System.Windows.Forms.DockStyle.TopMe.PTop.Location = New System.Drawing.Point(0, 84)Me.PTop.Name = "PTop"Me.PTop.Size = New System.Drawing.Size(517, 88)Me.PTop.TabIndex = 4Me.PTop.Visible = False''Label19'Me.Label19.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingleMe.Label19.Location = New System.Drawing.Point(0, 52)Me.Label19.Name = "Label19"Me.Label19.Size = New System.Drawing.Size(516, 1)Me.Label19.TabIndex = 37''Label18'Me.Label18.AutoSize = TrueMe.Label18.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))Me.Label18.Location = New System.Drawing.Point(20, 64)Me.Label18.Name = "Label18"Me.Label18.Size = New System.Drawing.Size(48, 13)Me.Label18.TabIndex = 36Me.Label18.Text = "Parent:"''BtnAddParent'Me.BtnAddParent.Location = New System.Drawing.Point(412, 60)Me.BtnAddParent.Name = "BtnAddParent"Me.BtnAddParent.Size = New System.Drawing.Size(68, 24)Me.BtnAddParent.TabIndex = 34Me.BtnAddParent.Text = "Add New"Me.ToolTip1.SetToolTip(Me.BtnAddParent, "Add New Person to become Parent.")Me.BtnAddParent.UseVisualStyleBackColor = True''Label17'Me.Label17.AutoSize = TrueMe.Label17.Location = New System.Drawing.Point(108, 64)Me.Label17.Name = "Label17"Me.Label17.Size = New System.Drawing.Size(40, 13)Me.Label17.TabIndex = 33Me.Label17.Text = "Select:"''Label16'Me.Label16.AutoSize = TrueMe.Label16.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))Me.Label16.Location = New System.Drawing.Point(20, 8)Me.Label16.Name = "Label16"Me.Label16.Size = New System.Drawing.Size(39, 13)Me.Label16.TabIndex = 32Me.Label16.Text = "Child:"''CBName'Me.CBName.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppendMe.CBName.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItemsMe.CBName.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPersonName, "Name", True))Me.CBName.DataSource = Me.BSPersonNameMe.CBName.DisplayMember = "Name"Me.CBName.FormattingEnabled = TrueMe.CBName.Location = New System.Drawing.Point(152, 60)Me.CBName.Name = "CBName"Me.CBName.Size = New System.Drawing.Size(236, 21)Me.CBName.TabIndex = 31Me.CBName.ValueMember = "Id"''BSPersonName'Me.BSPersonName.DataMember = "PersonName"Me.BSPersonName.DataSource = Me.DSPerson''DSPerson'Me.DSPerson.DataSetName = "DSClsPerson"Me.DSPerson.SchemaSerializationMode = System.Data.SchemaSerializationMode.IncludeSchema''Label3'Me.Label3.AutoSize = TrueMe.Label3.Location = New System.Drawing.Point(252, 8)Me.Label3.Name = "Label3"Me.Label3.Size = New System.Drawing.Size(49, 13)Me.Label3.TabIndex = 30Me.Label3.Text = "Surname"''TBChildSurname'Me.TBChildSurname.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSChild, "Surname", True))Me.TBChildSurname.Location = New System.Drawing.Point(252, 24)Me.TBChildSurname.Name = "TBChildSurname"Me.TBChildSurname.Size = New System.Drawing.Size(136, 20)Me.TBChildSurname.TabIndex = 29''BSChild'Me.BSChild.DataMember = "Child"Me.BSChild.DataSource = Me.DSPerson''TBChildForename'Me.TBChildForename.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSChild, "Forename", True))Me.TBChildForename.Location = New System.Drawing.Point(108, 24)Me.TBChildForename.Name = "TBChildForename"Me.TBChildForename.Size = New System.Drawing.Size(136, 20)Me.TBChildForename.TabIndex = 27''Label15'Me.Label15.AutoSize = TrueMe.Label15.Location = New System.Drawing.Point(108, 8)Me.Label15.Name = "Label15"Me.Label15.Size = New System.Drawing.Size(54, 13)Me.Label15.TabIndex = 28Me.Label15.Text = "Forename"''CBTitle'Me.CBTitle.AutoCompleteMode = System.Windows.Forms.AutoCompleteMode.SuggestAppendMe.CBTitle.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItemsMe.CBTitle.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "Title", True))Me.CBTitle.FormattingEnabled = TrueMe.CBTitle.Items.AddRange(New Object() {"Mr", "Mrs", "Miss", "Ms"})Me.CBTitle.Location = New System.Drawing.Point(24, 20)Me.CBTitle.Name = "CBTitle"Me.CBTitle.Size = New System.Drawing.Size(76, 21)Me.CBTitle.TabIndex = 1''BSPerson'Me.BSPerson.DataMember = "Person"Me.BSPerson.DataSource = Me.DSPerson''Label5'Me.Label5.AutoSize = TrueMe.Label5.Location = New System.Drawing.Point(252, 4)Me.Label5.Name = "Label5"Me.Label5.Size = New System.Drawing.Size(49, 13)Me.Label5.TabIndex = 6Me.Label5.Text = "Surname"''TBSurname'Me.TBSurname.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "Surname", True))Me.TBSurname.Location = New System.Drawing.Point(252, 20)Me.TBSurname.Name = "TBSurname"Me.TBSurname.Size = New System.Drawing.Size(136, 20)Me.TBSurname.TabIndex = 5''Label4'Me.Label4.AutoSize = TrueMe.Label4.Location = New System.Drawing.Point(108, 4)Me.Label4.Name = "Label4"Me.Label4.Size = New System.Drawing.Size(54, 13)Me.Label4.TabIndex = 4Me.Label4.Text = "Forename"''TBForename'Me.TBForename.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "Forename", True))Me.TBForename.Location = New System.Drawing.Point(108, 20)Me.TBForename.Name = "TBForename"Me.TBForename.Size = New System.Drawing.Size(136, 20)Me.TBForename.TabIndex = 3''LTitle'Me.LTitle.AutoSize = TrueMe.LTitle.Location = New System.Drawing.Point(24, 4)Me.LTitle.Name = "LTitle"Me.LTitle.Size = New System.Drawing.Size(27, 13)Me.LTitle.TabIndex = 2Me.LTitle.Text = "Title"''PBottom'Me.PBottom.Controls.Add(Me.CBTitle)Me.PBottom.Controls.Add(Me.Label5)Me.PBottom.Controls.Add(Me.ChkBArtists)Me.PBottom.Controls.Add(Me.TBSurname)Me.PBottom.Controls.Add(Me.ChkBGeneral)Me.PBottom.Controls.Add(Me.Label4)Me.PBottom.Controls.Add(Me.ChkBMember)Me.PBottom.Controls.Add(Me.TBForename)Me.PBottom.Controls.Add(Me.Label14)Me.PBottom.Controls.Add(Me.LTitle)Me.PBottom.Controls.Add(Me.TBAddress1)Me.PBottom.Controls.Add(Me.Label13)Me.PBottom.Controls.Add(Me.Label6)Me.PBottom.Controls.Add(Me.TBEMail)Me.PBottom.Controls.Add(Me.TBAddress2)Me.PBottom.Controls.Add(Me.Label12)Me.PBottom.Controls.Add(Me.Label7)Me.PBottom.Controls.Add(Me.TBPhone2)Me.PBottom.Controls.Add(Me.TBAddress3)Me.PBottom.Controls.Add(Me.Label11)Me.PBottom.Controls.Add(Me.Label8)Me.PBottom.Controls.Add(Me.TBPhone1)Me.PBottom.Controls.Add(Me.TBAddress4)Me.PBottom.Controls.Add(Me.Label10)Me.PBottom.Controls.Add(Me.Label9)Me.PBottom.Controls.Add(Me.TBPostcode)Me.PBottom.Dock = System.Windows.Forms.DockStyle.BottomMe.PBottom.Location = New System.Drawing.Point(0, 205)Me.PBottom.Name = "PBottom"Me.PBottom.Size = New System.Drawing.Size(517, 253)Me.PBottom.TabIndex = 6''ChkBArtists'Me.ChkBArtists.AutoSize = TrueMe.ChkBArtists.DataBindings.Add(New System.Windows.Forms.Binding("CheckState", Me.BSPerson, "ArtistsList", True))Me.ChkBArtists.Location = New System.Drawing.Point(424, 120)Me.ChkBArtists.Name = "ChkBArtists"Me.ChkBArtists.Size = New System.Drawing.Size(54, 17)Me.ChkBArtists.TabIndex = 26Me.ChkBArtists.Text = "Artists"Me.ChkBArtists.UseVisualStyleBackColor = True''ChkBGeneral'Me.ChkBGeneral.AutoSize = TrueMe.ChkBGeneral.DataBindings.Add(New System.Windows.Forms.Binding("CheckState", Me.BSPerson, "GeneralList", True))Me.ChkBGeneral.Location = New System.Drawing.Point(424, 96)Me.ChkBGeneral.Name = "ChkBGeneral"Me.ChkBGeneral.Size = New System.Drawing.Size(63, 17)Me.ChkBGeneral.TabIndex = 25Me.ChkBGeneral.Text = "General"Me.ChkBGeneral.UseVisualStyleBackColor = True''ChkBMember'Me.ChkBMember.AutoSize = TrueMe.ChkBMember.DataBindings.Add(New System.Windows.Forms.Binding("CheckState", Me.BSPerson, "MemberList", True))Me.ChkBMember.Enabled = FalseMe.ChkBMember.Location = New System.Drawing.Point(424, 72)Me.ChkBMember.Name = "ChkBMember"Me.ChkBMember.Size = New System.Drawing.Size(64, 17)Me.ChkBMember.TabIndex = 24Me.ChkBMember.Text = "Member"Me.ChkBMember.UseVisualStyleBackColor = True''Label14'Me.Label14.AutoSize = TrueMe.Label14.Location = New System.Drawing.Point(416, 52)Me.Label14.Name = "Label14"Me.Label14.Size = New System.Drawing.Size(64, 13)Me.Label14.TabIndex = 23Me.Label14.Text = "Mailing Lists"''TBAddress1'Me.TBAddress1.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "Address1", True))Me.TBAddress1.Location = New System.Drawing.Point(80, 48)Me.TBAddress1.Name = "TBAddress1"Me.TBAddress1.Size = New System.Drawing.Size(308, 20)Me.TBAddress1.TabIndex = 7''Label13'Me.Label13.AutoSize = TrueMe.Label13.Location = New System.Drawing.Point(20, 228)Me.Label13.Name = "Label13"Me.Label13.Size = New System.Drawing.Size(33, 13)Me.Label13.TabIndex = 22Me.Label13.Text = "EMail"''Label6'Me.Label6.AutoSize = TrueMe.Label6.Location = New System.Drawing.Point(20, 52)Me.Label6.Name = "Label6"Me.Label6.Size = New System.Drawing.Size(51, 13)Me.Label6.TabIndex = 8Me.Label6.Text = "Address1"''TBEMail'Me.TBEMail.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "EMail", True))Me.TBEMail.Location = New System.Drawing.Point(80, 224)Me.TBEMail.Name = "TBEMail"Me.TBEMail.Size = New System.Drawing.Size(308, 20)Me.TBEMail.TabIndex = 21''TBAddress2'Me.TBAddress2.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "Address2", True))Me.TBAddress2.Location = New System.Drawing.Point(80, 72)Me.TBAddress2.Name = "TBAddress2"Me.TBAddress2.Size = New System.Drawing.Size(308, 20)Me.TBAddress2.TabIndex = 9''Label12'Me.Label12.AutoSize = TrueMe.Label12.Location = New System.Drawing.Point(20, 200)Me.Label12.Name = "Label12"Me.Label12.Size = New System.Drawing.Size(44, 13)Me.Label12.TabIndex = 20Me.Label12.Text = "Phone2"''Label7'Me.Label7.AutoSize = TrueMe.Label7.Location = New System.Drawing.Point(20, 76)Me.Label7.Name = "Label7"Me.Label7.Size = New System.Drawing.Size(51, 13)Me.Label7.TabIndex = 10Me.Label7.Text = "Address2"''TBPhone2'Me.TBPhone2.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "Phone2", True))Me.TBPhone2.Location = New System.Drawing.Point(80, 196)Me.TBPhone2.Name = "TBPhone2"Me.TBPhone2.Size = New System.Drawing.Size(160, 20)Me.TBPhone2.TabIndex = 19''TBAddress3'Me.TBAddress3.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "Address3", True))Me.TBAddress3.Location = New System.Drawing.Point(80, 96)Me.TBAddress3.Name = "TBAddress3"Me.TBAddress3.Size = New System.Drawing.Size(308, 20)Me.TBAddress3.TabIndex = 11''Label11'Me.Label11.AutoSize = TrueMe.Label11.Location = New System.Drawing.Point(20, 176)Me.Label11.Name = "Label11"Me.Label11.Size = New System.Drawing.Size(44, 13)Me.Label11.TabIndex = 18Me.Label11.Text = "Phone1"''Label8'Me.Label8.AutoSize = TrueMe.Label8.Location = New System.Drawing.Point(20, 96)Me.Label8.Name = "Label8"Me.Label8.Size = New System.Drawing.Size(51, 13)Me.Label8.TabIndex = 12Me.Label8.Text = "Address3"''TBPhone1'Me.TBPhone1.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "Phone1", True))Me.TBPhone1.Location = New System.Drawing.Point(80, 172)Me.TBPhone1.Name = "TBPhone1"Me.TBPhone1.Size = New System.Drawing.Size(160, 20)Me.TBPhone1.TabIndex = 17''TBAddress4'Me.TBAddress4.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "Address4", True))Me.TBAddress4.Location = New System.Drawing.Point(80, 120)Me.TBAddress4.Name = "TBAddress4"Me.TBAddress4.Size = New System.Drawing.Size(308, 20)Me.TBAddress4.TabIndex = 13''Label10'Me.Label10.AutoSize = TrueMe.Label10.Location = New System.Drawing.Point(20, 148)Me.Label10.Name = "Label10"Me.Label10.Size = New System.Drawing.Size(52, 13)Me.Label10.TabIndex = 16Me.Label10.Text = "Postcode"''Label9'Me.Label9.AutoSize = TrueMe.Label9.Location = New System.Drawing.Point(20, 124)Me.Label9.Name = "Label9"Me.Label9.Size = New System.Drawing.Size(51, 13)Me.Label9.TabIndex = 14Me.Label9.Text = "Address4"''TBPostcode'Me.TBPostcode.DataBindings.Add(New System.Windows.Forms.Binding("Text", Me.BSPerson, "PostCode", True))Me.TBPostcode.Location = New System.Drawing.Point(80, 144)Me.TBPostcode.Name = "TBPostcode"Me.TBPostcode.Size = New System.Drawing.Size(96, 20)Me.TBPostcode.TabIndex = 15''ErrorProvider1'Me.ErrorProvider1.ContainerControl = Me''TAPerson'Me.TAPerson.ClearBeforeFill = True''TAPersonName'Me.TAPersonName.ClearBeforeFill = True''TAChild'Me.TAChild.ClearBeforeFill = True''HelpProvider1'Me.HelpProvider1.HelpNamespace = "C:\Documents and Settings\Admin\My Documents\Visual Studio 2005\Projects\ACE\ACE\" & _"Help\ACE.chm"''FPerson'Me.AcceptButton = Me.Button6Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.FontMe.CancelButton = Me.Button5Me.ClientSize = New System.Drawing.Size(517, 499)Me.ControlBox = FalseMe.Controls.Add(Me.PBottom)Me.Controls.Add(Me.PTop)Me.Controls.Add(Me.PFooter)Me.Controls.Add(Me.PHeader)Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialogMe.KeyPreview = TrueMe.MaximizeBox = FalseMe.MinimizeBox = FalseMe.Name = "FPerson"Me.ShowInTaskbar = FalseMe.StartPosition = System.Windows.Forms.FormStartPosition.CenterParentMe.Text = "ACE Person Details"Me.PHeader.ResumeLayout(False)Me.PHeader.PerformLayout()CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).EndInit()Me.PFooter.ResumeLayout(False)Me.PTop.ResumeLayout(False)Me.PTop.PerformLayout()CType(Me.BSPersonName, System.ComponentModel.ISupportInitialize).EndInit()CType(Me.DSPerson, System.ComponentModel.ISupportInitialize).EndInit()CType(Me.BSChild, System.ComponentModel.ISupportInitialize).EndInit()CType(Me.BSPerson, System.ComponentModel.ISupportInitialize).EndInit()Me.PBottom.ResumeLayout(False)Me.PBottom.PerformLayout()CType(Me.ErrorProvider1, System.ComponentModel.ISupportInitialize).EndInit()Me.ResumeLayout(False)End Sub
Regards, Tony.
I see you have a table adapter on the form. Try this open the project and close the form with the error. Open the datasources window and rebuild the project. Then reopen the form.
Ken,
I have tried your suggestion, closing the form with the error, then all forms, while rebuilding but it does not help.
I have in the meantime gone back to a backup from some days ago, re-implemented the changes I had done since then, and the error has gone away. I am still holding my breath.
Rgds, Tony.
(In answer to an automatic prompt:)
I have found a workaround, so the problem is no longer outstanding, but the solution did not come from this forum.
Tony.
Tony: What is the workaround? We ae having the same problem and Microsoft is perplexed.
My workaround was to go back six days to a backup that worked, and
re-implement the changes made since then. As far as I can tell
(by doing a comparison of the VB source files) I have put all the same
changes in, and it now works. Presumably there is something I
have missed, or something not captured in the VB files, or the sequence
of the source code makes a difference, but I have not spent any more
time looking.
Sorry this is unlikely to be helpful.
Regards, Tony
I am also getting this error using VS2005 I have searched all files for .ctor and no results. Is there a fix yet? Microsoft Visual Studio 2005 Version 8.0.50727.42 (RTM.050727-4200) Microsoft .NET Framework Version 2.0.50727 Installed Edition: Professional Microsoft Visual Basic 2005 77626-009-0000007-41964 Microsoft Visual Basic 2005 Microsoft Visual C# 2005 77626-009-0000007-41964 Microsoft Visual C# 2005 Microsoft Visual C++ 2005 77626-009-0000007-41964 Microsoft Visual C++ 2005 Microsoft Visual J# 2005 77626-009-0000007-41964 Microsoft Visual J# 2005 Microsoft Visual Web Developer 2005 77626-009-0000007-41964 Microsoft Visual Web Developer 2005 Crystal Reports AAC60-G0CSA4B-V7000AY Crystal Reports for Visual Studio 2005 Microsoft Office InfoPath 2003 Toolkit for Visual Studio 2005 73931-640-1341516-57165 Microsoft Office InfoPath 2003 Toolkit for Visual Studio 2005
'.ctor' is not a valid identifier. Hide |
at Microsoft.VisualStudio.Shell.Design.Serialization.CodeDom.CodeDomEventBindingService.ValidateMethodName(String methodName) at System.ComponentModel.Design.EventBindingService.EventPropertyDescriptor.SetValue(Object component, Object value) at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeAttachEventStatement(IDesignerSerializationManager manager, CodeAttachEventStatement statement) at System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeStatement(IDesignerSerializationManager manager, CodeStatement statement)
|
Can you check to see if there is a method or field in your class that has the same name as the class? If so, could you try renaming it to something different?
Hope this helps,
Did anyone here actually get the problem solved? I am having the same problem as well.
Just make sure that you don't have any members called "[New]" in your class. That's most likely the cause of the problem