Answer the question
In order to leave comments, you need to log in
What is a good tutorial for building a GUI in C#?
Of course, Visual Studio has everything you need, but I would like to dig into the code myself.
Answer the question
In order to leave comments, you need to log in
Nothing prevents you from writing this all by hand.
I really don't see the deep meaning.
Is that more control over changes in the code, or designing your own control.
But if you really want to go deep, start with
https://docs.microsoft.com/en-us/windows/win32/con... (it's important to understand what's under the hood)
https://docs.microsoft.com/ en-us/dotnet/desktop/wi...
namespace WindowsFormsApp1
{
partial class UserControl1
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Component Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.button1 = new System.Windows.Forms.Button();
this.SuspendLayout();
//
// button1
//
this.button1.Location = new System.Drawing.Point(142, 67);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(346, 47);
this.button1.TabIndex = 0;
this.button1.Text = "Eat me!";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// UserControl1
//
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.button1);
this.Name = "UserControl1";
this.Size = new System.Drawing.Size(710, 150);
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Button button1;
}
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question