All pastes #84435 Raw Copy code Copy link Edit

Carlos Alberto

public unlisted text v1 · immutable
#84435 ·published 2006-07-10 22:39 UTC
rendered paste body
// sample
using System;
using System.Windows.Forms;
using System.Drawing;
using System.Collections;

public class TestForm : Form
{
        static void Main ()
        {
                TestForm form = new TestForm ();
                Application.Run (form);
        }

        public TestForm ()
        {
                ListBox listbox = new ListBox ();
                listbox.Parent = this;
                listbox.Location = new Point (5, 5);

                listbox.Sorted = true; // Comment this for second case
                listbox.Items.AddRange (new string [] {"Bill", "Jeff", "Albert"});
                //listbox.Sorted = true; // Uncomment this for second case
        }
}