if(IsPostBack)
{
   this.ListBox2.Items.Clear();
}
ListItem k = new ListItem();
k=this.ListBox1.SelectedItem;
int s = this.ListBox1.SelectedIndex;
if(s>=0)
{
if(s>0)
{
for(int i =0;i<s-1;i++)
{
ListItem other = new ListItem();
other=this.ListBox1.Items[i];
this.ListBox2.Items.Add(other);
}
this.ListBox2.Items.Add(k);
k=this.ListBox1.Items[s-1];
this.ListBox2.Items.Add(k);
for(int i=s+1;i<this.ListBox1.Items.Count;i++)
{
ListItem other = new ListItem();
other=this.ListBox1.Items[i];
this.ListBox2.Items.Add(other);
}
this.ListBox2.DataBind();
}
else
{
this.ListBox2.Items.Add(k);
k=this.ListBox1.Items[s];
this.ListBox2.Items.Add(k);
for(int i=s+1;i<this.ListBox1.Items.Count;i++)
{
ListItem other = new ListItem();
other=this.ListBox1.Items[i];
this.ListBox2.Items.Add(other);
}
this.ListBox2.DataBind();
}
}