Loading a User Control Onto Form return error every time program is built
up vote
0
down vote
favorite
Hello im creating a media player program on visual studio using vb.net. A basic feature of my application is a simple GUI navigation system, in which the user can select tabs such as 'Home' and 'upload' and a different page will show on each one. To do this i have created user controls, in which i load onto my main form and simply turn visibility to false when not selected.
The problem is i having been getting errors everytime the program is built/ i close and reopen the program.
The designer cannot process unknown name 'BackColor' at line 324. The code within the method 'InitializeComponent' is generated by the designer and should not be manually modified. Please remove any changes and try opening the designer again.
Viewing this code directs to this chunk-
'
'Uploader_Control2
'
Me.Uploader_Control2.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Uploader_Control2.Dock = System.Windows.Forms.DockStyle.Fill
Me.Uploader_Control2.Location = New System.Drawing.Point(248, 23)
Me.Uploader_Control2.Name = "Uploader_Control2"
Me.Uploader_Control2.Size = New System.Drawing.Size(1180, 656)
Me.Uploader_Control2.TabIndex = 0
'
'Home_Control2
'
Me.Home_Control2.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Home_Control2.Dock = System.Windows.Forms.DockStyle.Fill
Me.Home_Control2.Location = New System.Drawing.Point(248, 23)
Me.Home_Control2.Name = "Home_Control2"
Me.Home_Control2.Size = New System.Drawing.Size(1180, 656)
Me.Home_Control2.TabIndex = 1
'
'Uploader_Control1
'
Me.Uploader_Control1.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Uploader_Control1.Location = New System.Drawing.Point(0, 0)
Me.Uploader_Control1.Name = "Uploader_Control1"
Me.Uploader_Control1.Size = New System.Drawing.Size(1180, 656)
Me.Uploader_Control1.TabIndex = 0
'
'Home_Control1
'
Me.Home_Control1.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Home_Control1.Location = New System.Drawing.Point(0, 0)
Me.Home_Control1.Name = "Home_Control1"
Me.Home_Control1.Size = New System.Drawing.Size(1180, 656)
Me.Home_Control1.TabIndex = 0
Deleting this chunk of code removes the error and shows the user controls in my form how i want them. Its starting to become a persistent and annoying issue and despite researching it i have struggled to find any information on how to fix it.
In addition to this loading any of the user controls like this returns a error-
Private Sub Uploader_Control2_Load(sender As Object, e As EventArgs) Handles Uploader_Control2.Load
End Sub
Event load cannot be found
All help appreciated. Thanks in advance.
vb.net visual-studio
|
show 3 more comments
up vote
0
down vote
favorite
Hello im creating a media player program on visual studio using vb.net. A basic feature of my application is a simple GUI navigation system, in which the user can select tabs such as 'Home' and 'upload' and a different page will show on each one. To do this i have created user controls, in which i load onto my main form and simply turn visibility to false when not selected.
The problem is i having been getting errors everytime the program is built/ i close and reopen the program.
The designer cannot process unknown name 'BackColor' at line 324. The code within the method 'InitializeComponent' is generated by the designer and should not be manually modified. Please remove any changes and try opening the designer again.
Viewing this code directs to this chunk-
'
'Uploader_Control2
'
Me.Uploader_Control2.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Uploader_Control2.Dock = System.Windows.Forms.DockStyle.Fill
Me.Uploader_Control2.Location = New System.Drawing.Point(248, 23)
Me.Uploader_Control2.Name = "Uploader_Control2"
Me.Uploader_Control2.Size = New System.Drawing.Size(1180, 656)
Me.Uploader_Control2.TabIndex = 0
'
'Home_Control2
'
Me.Home_Control2.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Home_Control2.Dock = System.Windows.Forms.DockStyle.Fill
Me.Home_Control2.Location = New System.Drawing.Point(248, 23)
Me.Home_Control2.Name = "Home_Control2"
Me.Home_Control2.Size = New System.Drawing.Size(1180, 656)
Me.Home_Control2.TabIndex = 1
'
'Uploader_Control1
'
Me.Uploader_Control1.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Uploader_Control1.Location = New System.Drawing.Point(0, 0)
Me.Uploader_Control1.Name = "Uploader_Control1"
Me.Uploader_Control1.Size = New System.Drawing.Size(1180, 656)
Me.Uploader_Control1.TabIndex = 0
'
'Home_Control1
'
Me.Home_Control1.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Home_Control1.Location = New System.Drawing.Point(0, 0)
Me.Home_Control1.Name = "Home_Control1"
Me.Home_Control1.Size = New System.Drawing.Size(1180, 656)
Me.Home_Control1.TabIndex = 0
Deleting this chunk of code removes the error and shows the user controls in my form how i want them. Its starting to become a persistent and annoying issue and despite researching it i have struggled to find any information on how to fix it.
In addition to this loading any of the user controls like this returns a error-
Private Sub Uploader_Control2_Load(sender As Object, e As EventArgs) Handles Uploader_Control2.Load
End Sub
Event load cannot be found
All help appreciated. Thanks in advance.
vb.net visual-studio
You created a custom control? Did you follow these steps, docs.microsoft.com/en-us/dotnet/framework/winforms/controls/… ?
– dbasnett
Nov 19 at 15:27
Depending which version of VS you're running there was a known issue that toggling the framework may fix: developercommunity.visualstudio.com/content/problem/160241/…
– Nathan Champion
Nov 19 at 15:28
@NathanChampion I have seen the article and unfortunatley neither of the solutions worked. Any other ideas?
– Lupe_99
Nov 19 at 15:37
1
By chance, Backcolor is the first property set for each control. If you comment out that line, the error will move to the next line. Chances are that the namespace or class name for the user control is mispelled, or was changed between the time the user control was firstly consumed in the form and now. Also, if rebuilding the app causes the user control to be rebuilt as part of the same solution, the .dll will be cleaned up before being recompiled. That's where the errors are coming while recompiling.
– Alessandro Mandelli
Nov 19 at 16:12
1
@Lupe_99 If I assume that you created a custom control.did you inherit UserControl?
– dbasnett
Nov 19 at 16:49
|
show 3 more comments
up vote
0
down vote
favorite
up vote
0
down vote
favorite
Hello im creating a media player program on visual studio using vb.net. A basic feature of my application is a simple GUI navigation system, in which the user can select tabs such as 'Home' and 'upload' and a different page will show on each one. To do this i have created user controls, in which i load onto my main form and simply turn visibility to false when not selected.
The problem is i having been getting errors everytime the program is built/ i close and reopen the program.
The designer cannot process unknown name 'BackColor' at line 324. The code within the method 'InitializeComponent' is generated by the designer and should not be manually modified. Please remove any changes and try opening the designer again.
Viewing this code directs to this chunk-
'
'Uploader_Control2
'
Me.Uploader_Control2.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Uploader_Control2.Dock = System.Windows.Forms.DockStyle.Fill
Me.Uploader_Control2.Location = New System.Drawing.Point(248, 23)
Me.Uploader_Control2.Name = "Uploader_Control2"
Me.Uploader_Control2.Size = New System.Drawing.Size(1180, 656)
Me.Uploader_Control2.TabIndex = 0
'
'Home_Control2
'
Me.Home_Control2.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Home_Control2.Dock = System.Windows.Forms.DockStyle.Fill
Me.Home_Control2.Location = New System.Drawing.Point(248, 23)
Me.Home_Control2.Name = "Home_Control2"
Me.Home_Control2.Size = New System.Drawing.Size(1180, 656)
Me.Home_Control2.TabIndex = 1
'
'Uploader_Control1
'
Me.Uploader_Control1.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Uploader_Control1.Location = New System.Drawing.Point(0, 0)
Me.Uploader_Control1.Name = "Uploader_Control1"
Me.Uploader_Control1.Size = New System.Drawing.Size(1180, 656)
Me.Uploader_Control1.TabIndex = 0
'
'Home_Control1
'
Me.Home_Control1.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Home_Control1.Location = New System.Drawing.Point(0, 0)
Me.Home_Control1.Name = "Home_Control1"
Me.Home_Control1.Size = New System.Drawing.Size(1180, 656)
Me.Home_Control1.TabIndex = 0
Deleting this chunk of code removes the error and shows the user controls in my form how i want them. Its starting to become a persistent and annoying issue and despite researching it i have struggled to find any information on how to fix it.
In addition to this loading any of the user controls like this returns a error-
Private Sub Uploader_Control2_Load(sender As Object, e As EventArgs) Handles Uploader_Control2.Load
End Sub
Event load cannot be found
All help appreciated. Thanks in advance.
vb.net visual-studio
Hello im creating a media player program on visual studio using vb.net. A basic feature of my application is a simple GUI navigation system, in which the user can select tabs such as 'Home' and 'upload' and a different page will show on each one. To do this i have created user controls, in which i load onto my main form and simply turn visibility to false when not selected.
The problem is i having been getting errors everytime the program is built/ i close and reopen the program.
The designer cannot process unknown name 'BackColor' at line 324. The code within the method 'InitializeComponent' is generated by the designer and should not be manually modified. Please remove any changes and try opening the designer again.
Viewing this code directs to this chunk-
'
'Uploader_Control2
'
Me.Uploader_Control2.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Uploader_Control2.Dock = System.Windows.Forms.DockStyle.Fill
Me.Uploader_Control2.Location = New System.Drawing.Point(248, 23)
Me.Uploader_Control2.Name = "Uploader_Control2"
Me.Uploader_Control2.Size = New System.Drawing.Size(1180, 656)
Me.Uploader_Control2.TabIndex = 0
'
'Home_Control2
'
Me.Home_Control2.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Home_Control2.Dock = System.Windows.Forms.DockStyle.Fill
Me.Home_Control2.Location = New System.Drawing.Point(248, 23)
Me.Home_Control2.Name = "Home_Control2"
Me.Home_Control2.Size = New System.Drawing.Size(1180, 656)
Me.Home_Control2.TabIndex = 1
'
'Uploader_Control1
'
Me.Uploader_Control1.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Uploader_Control1.Location = New System.Drawing.Point(0, 0)
Me.Uploader_Control1.Name = "Uploader_Control1"
Me.Uploader_Control1.Size = New System.Drawing.Size(1180, 656)
Me.Uploader_Control1.TabIndex = 0
'
'Home_Control1
'
Me.Home_Control1.BackColor = System.Drawing.Color.FromArgb(CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer), CType(CType(24, Byte), Integer))
Me.Home_Control1.Location = New System.Drawing.Point(0, 0)
Me.Home_Control1.Name = "Home_Control1"
Me.Home_Control1.Size = New System.Drawing.Size(1180, 656)
Me.Home_Control1.TabIndex = 0
Deleting this chunk of code removes the error and shows the user controls in my form how i want them. Its starting to become a persistent and annoying issue and despite researching it i have struggled to find any information on how to fix it.
In addition to this loading any of the user controls like this returns a error-
Private Sub Uploader_Control2_Load(sender As Object, e As EventArgs) Handles Uploader_Control2.Load
End Sub
Event load cannot be found
All help appreciated. Thanks in advance.
vb.net visual-studio
vb.net visual-studio
asked Nov 19 at 15:13
Lupe_99
202
202
You created a custom control? Did you follow these steps, docs.microsoft.com/en-us/dotnet/framework/winforms/controls/… ?
– dbasnett
Nov 19 at 15:27
Depending which version of VS you're running there was a known issue that toggling the framework may fix: developercommunity.visualstudio.com/content/problem/160241/…
– Nathan Champion
Nov 19 at 15:28
@NathanChampion I have seen the article and unfortunatley neither of the solutions worked. Any other ideas?
– Lupe_99
Nov 19 at 15:37
1
By chance, Backcolor is the first property set for each control. If you comment out that line, the error will move to the next line. Chances are that the namespace or class name for the user control is mispelled, or was changed between the time the user control was firstly consumed in the form and now. Also, if rebuilding the app causes the user control to be rebuilt as part of the same solution, the .dll will be cleaned up before being recompiled. That's where the errors are coming while recompiling.
– Alessandro Mandelli
Nov 19 at 16:12
1
@Lupe_99 If I assume that you created a custom control.did you inherit UserControl?
– dbasnett
Nov 19 at 16:49
|
show 3 more comments
You created a custom control? Did you follow these steps, docs.microsoft.com/en-us/dotnet/framework/winforms/controls/… ?
– dbasnett
Nov 19 at 15:27
Depending which version of VS you're running there was a known issue that toggling the framework may fix: developercommunity.visualstudio.com/content/problem/160241/…
– Nathan Champion
Nov 19 at 15:28
@NathanChampion I have seen the article and unfortunatley neither of the solutions worked. Any other ideas?
– Lupe_99
Nov 19 at 15:37
1
By chance, Backcolor is the first property set for each control. If you comment out that line, the error will move to the next line. Chances are that the namespace or class name for the user control is mispelled, or was changed between the time the user control was firstly consumed in the form and now. Also, if rebuilding the app causes the user control to be rebuilt as part of the same solution, the .dll will be cleaned up before being recompiled. That's where the errors are coming while recompiling.
– Alessandro Mandelli
Nov 19 at 16:12
1
@Lupe_99 If I assume that you created a custom control.did you inherit UserControl?
– dbasnett
Nov 19 at 16:49
You created a custom control? Did you follow these steps, docs.microsoft.com/en-us/dotnet/framework/winforms/controls/… ?
– dbasnett
Nov 19 at 15:27
You created a custom control? Did you follow these steps, docs.microsoft.com/en-us/dotnet/framework/winforms/controls/… ?
– dbasnett
Nov 19 at 15:27
Depending which version of VS you're running there was a known issue that toggling the framework may fix: developercommunity.visualstudio.com/content/problem/160241/…
– Nathan Champion
Nov 19 at 15:28
Depending which version of VS you're running there was a known issue that toggling the framework may fix: developercommunity.visualstudio.com/content/problem/160241/…
– Nathan Champion
Nov 19 at 15:28
@NathanChampion I have seen the article and unfortunatley neither of the solutions worked. Any other ideas?
– Lupe_99
Nov 19 at 15:37
@NathanChampion I have seen the article and unfortunatley neither of the solutions worked. Any other ideas?
– Lupe_99
Nov 19 at 15:37
1
1
By chance, Backcolor is the first property set for each control. If you comment out that line, the error will move to the next line. Chances are that the namespace or class name for the user control is mispelled, or was changed between the time the user control was firstly consumed in the form and now. Also, if rebuilding the app causes the user control to be rebuilt as part of the same solution, the .dll will be cleaned up before being recompiled. That's where the errors are coming while recompiling.
– Alessandro Mandelli
Nov 19 at 16:12
By chance, Backcolor is the first property set for each control. If you comment out that line, the error will move to the next line. Chances are that the namespace or class name for the user control is mispelled, or was changed between the time the user control was firstly consumed in the form and now. Also, if rebuilding the app causes the user control to be rebuilt as part of the same solution, the .dll will be cleaned up before being recompiled. That's where the errors are coming while recompiling.
– Alessandro Mandelli
Nov 19 at 16:12
1
1
@Lupe_99 If I assume that you created a custom control.did you inherit UserControl?
– dbasnett
Nov 19 at 16:49
@Lupe_99 If I assume that you created a custom control.did you inherit UserControl?
– dbasnett
Nov 19 at 16:49
|
show 3 more comments
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53377568%2floading-a-user-control-onto-form-return-error-every-time-program-is-built%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
You created a custom control? Did you follow these steps, docs.microsoft.com/en-us/dotnet/framework/winforms/controls/… ?
– dbasnett
Nov 19 at 15:27
Depending which version of VS you're running there was a known issue that toggling the framework may fix: developercommunity.visualstudio.com/content/problem/160241/…
– Nathan Champion
Nov 19 at 15:28
@NathanChampion I have seen the article and unfortunatley neither of the solutions worked. Any other ideas?
– Lupe_99
Nov 19 at 15:37
1
By chance, Backcolor is the first property set for each control. If you comment out that line, the error will move to the next line. Chances are that the namespace or class name for the user control is mispelled, or was changed between the time the user control was firstly consumed in the form and now. Also, if rebuilding the app causes the user control to be rebuilt as part of the same solution, the .dll will be cleaned up before being recompiled. That's where the errors are coming while recompiling.
– Alessandro Mandelli
Nov 19 at 16:12
1
@Lupe_99 If I assume that you created a custom control.did you inherit UserControl?
– dbasnett
Nov 19 at 16:49