Move the Item of ListBox
来源:互联网 发布:linux lnmp搭建 编辑:程序博客网 时间:2024/04/30 08:28
.aspx
--------------------------------
<asp:ListBox id="ListBox1" style="Z-INDEX: 105; LEFT: 96px; POSITION: absolute; TOP: 344px" runat="server">
<asp:ListItem Value="a1">a1</asp:ListItem>
<asp:ListItem Value="a2">a2</asp:ListItem>
<asp:ListItem Value="a3">a3</asp:ListItem>
</asp:ListBox>
----------------------------------
.cs
//for 个
private void Button1_Click(object sender, System.EventArgs e){
if (this.ListBox1.SelectedIndex>=0)
{
int i = ListBox1.SelectedIndex;
if(i>0)
{
string values = this.ListBox1.Items[i].Text ;
this.ListBox1.Items[i].Text = this.ListBox1.Items[i-1].Text ;
this.ListBox1.Items[i-1].Text = values;
}
}
}
- Move the Item of ListBox
- Move The Taskbar to the Top of Desktop
- Move-Item 帮助信息
- [20081201]--the alert of required item
- Overview of the Supplier Item Catalog
- How to hide the highlight of a listbox
- On the Superfluousness of std::move - Scott Meyers
- 两个ListBox中的Item互换
- WPF重写ListBox的item
- Listbox 实现Item双击事件
- MVVM : MouseDoubleClick of Listbox
- Move semantics of RapidJSON
- PetStore - Solution of fixing the "item.attribute" exception
- Changing the layout direction of a form item in Flex
- The increment of remove and add live data item behavior
- How to get the value of one specified item
- SVN E200009 which is not part of the commit; both sides of the move must be committed together
- The FM of Getting all the characteristics (including values) of an Sales order item.
- 学车记(二)
- 学java也是个游戏
- .net打包自动安装数据库!
- 资源网
- How To Read and Write BLOB Data by Using ADO.NET with Visual C# .NET
- Move the Item of ListBox
- 盘点西甲之巴萨篇
- 巴萨两点最大的隐忧
- 游戏童年之打水漂
- 反编译类
- 顺便记录一下groupwise使用gaim
- [转载]开发工程师人生之路
- 无话可说
- 转贴 : 枚举算法