finance_teacher
asked on
C# -- ListBox.Items.Insert -- SORTING ?
I dropped a list box onto the page, added the below EVENT, ran the app, clicked anywhere on the APP multiple times, and my listbox got populated. How can I change the below so NEWEST values appear as the last entry instead of the first entry ?
-------------------------- ---------- ---------- ---------- ---------- ---------- ---------- ---------- ----
private void Form1_MouseClick(object sender, MouseEventArgs e)
{
string locationText = String.Format("{0}, {1}", e.X, e.Y);
listBox1.Items.Insert(0, locationText);
}
-------------------------- ---------- ---------- ---------- ---------- ---------- ---------- ---------- ----
--------------------------
private void Form1_MouseClick(object sender, MouseEventArgs e)
{
string locationText = String.Format("{0}, {1}", e.X, e.Y);
listBox1.Items.Insert(0, locationText);
}
--------------------------
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
private void Form1_MouseClick(object sender, MouseEventArgs e)
{
string locationText = String.Format("{0}, {1}", e.X, e.Y);
listBox1.Items.Insert(list
}