// Collection of code snippets by Arne Vajhøj // (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) using System.ComponentModel; using System.Drawing; using System.Windows.Forms; namespace E { partial class MainForm : Form { private IContainer components = null; protected override void Dispose(bool disposing) { if (disposing) { if (components != null) { components.Dispose(); } } base.Dispose(disposing); } private void InitializeComponent() { textBox1 = new TextBox(); textBox2 = new TextBox(); label1 = new Label(); label2 = new Label(); button1 = new Button(); SuspendLayout(); textBox1.Location = new Point(150, 50); textBox1.Size = new Size(100, 25); textBox2.Location = new Point(150, 100); textBox2.Size = new Size(100, 25); label1.Location = new Point(50, 50); label1.Size = new Size(100, 25); label1.Text = "Min"; label2.Location = new Point(50, 100); label2.Size = new Size(100, 25); label2.Text = "Max"; button1.Location = new Point(100, 150); button1.Size = new Size(75, 25); button1.Text = "Generate"; button1.UseVisualStyleBackColor = true; button1.Click += new System.EventHandler(Button1Click); ClientSize = new Size(300, 200); Controls.Add(button1); Controls.Add(label2); Controls.Add(label1); Controls.Add(textBox2); Controls.Add(textBox1); Text = "Generator"; ResumeLayout(false); PerformLayout(); } private Button button1; private Label label2; private Label label1; private TextBox textBox2; private TextBox textBox1; } }