Loading images into TreeView

1 posts, 0 answers
  1. Tomas Holek
    Tomas Holek avatar
    1 posts
    Member since:
    Feb 2009

    Posted 07 Jun 2009 Link to this post

    I have to display TreeView nodes with own images. I do it so:
     foreach (DataRow row in dataTable.Rows)
                        RadTreeNode node = new RadTreeNode();
                        node.Text = row["Name"].ToString();
                        node.Value = row["ID"].ToString();
                        node.ImageUrl = "~/images/tree/register.PNG";
                        node.ExpandMode = TreeNodeExpandMode.ClientSide;

    I think that more performed solution is to load images for nodes from WebResource.
    How do it ?
Back to Top