This Way:
<form id="form1" runat="server">
<div>
<asp:ListBox ID="lbDemo" runat="server" AutoPostBack="true" OnSelectedIndexChanged="lbDemo_SelectedIndexChanged">
<asp:ListItem Text="Ashwin"></asp:ListItem>
<asp:ListItem Text="Bhasker"></asp:ListItem>
<asp:ListItem Text="Chandru"></asp:ListItem>
<asp:ListItem Text="Das"></asp:ListItem>
<asp:ListItem Text="Das"></asp:ListItem>
</asp:ListBox>
<br />
<asp:ListView ID="lvDemo" runat="server">
<LayoutTemplate>
Name
<br />
<asp:PlaceHolder ID="itemPlaceholder" runat="server"></asp:PlaceHolder>
</LayoutTemplate>
<ItemTemplate>
<asp:Label ID="lblName" runat="server" Text='<%# Eval("Name") %>'></asp:Label>
</ItemTemplate>
<ItemSeparatorTemplate>
<br />
</ItemSeparatorTemplate>
</asp:ListView>
</div>
</form>
C#:
protected void lbDemo_SelectedIndexChanged(object sender, EventArgs e)
{
DataTable dt = new DataTable();
dt.Columns.Add("Name", typeof(string));
if (ViewState["Table"] == null)
{
dt.Rows.Add(lbDemo.SelectedItem.Text);
ViewState["Table"] = dt;
this.lvDemo.DataSource = dt;
this.lvDemo.DataBind();
}
else
{
dt = (DataTable)ViewState["Table"];
dt.Rows.Add(lbDemo.SelectedItem.Text);
this.lvDemo.DataSource = dt;
this.lvDemo.DataBind();
}
}
Image: