I have been trying to use the ATLAS ReOrderList with
DataSet but it does not seems to work. I can see the bullet list but I am not
able to see the item names in the ReOrderList. Is ReOrderList designed to work
with DataSets?? Don't tell me NO!!
<cc1:ReorderList CssClass="ReOrderControlStyle"
OnItemReorder="ReOrderItemEvent" SortOrderField="Order"
AllowReorder="true" DataKeyField="CategoryID"
ItemInsertLocation="Beginning" DragHandleAlignment="left"
ID="ReorderList1" runat="server">
<ItemTemplate>
<asp:Label ID="lblCategoryName"
runat="server" Text='<%# Eval("CategoryName") %>' />
</ItemTemplate>
</cc1:ReorderList>
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
BindData();
}
}
private void BindData()
{
SqlConnection myConnection = new SqlConnection
("Server=localhost;Database=School;Trusted_Connection=true");
SqlDataAdapter ad = new SqlDataAdapter
("SELECT * FROM Categories", myConnection);
DataSet ds = new DataSet();
ad.Fill(ds);
ReorderList1.DataSource = ds;
ReorderList1.DataBind();
}
powered by IMHO 1.3