// 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; using System.Collections.Generic; using System.Windows.Forms; namespace E { public class MailJob { public String To { get; set; } public String Subject { get; set; } public String Body { get; set; } } public class Program { [STAThread] private static void Main(string[] args) { Queue q = new Queue(); for(int i = 0; i < 50; i++) { q.Enqueue(new MailJob { To="arne@arne", Subject="Test", Body="This is a test" }); } Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); Application.Run(new MainForm(q)); } } }