tree view in winforms

2 posts, 0 answers
  1. Jack
    Jack avatar
    67 posts
    Member since:
    Jul 2010

    Posted 04 May 2011 Link to this post

    Hello to all  I am making a windows application in c#..In that i have a treeview. I am giving the same functionality as I have given in Web application of tree view plz see a look of web treeview--

    Now in desktop treeview the the name of file is not coming in there corresponding file, labels are running here and there plz see a desktop treeview--

    Note:--The first image is Web treeview  and the second image is desktop treeview..

    I have taken table layout panel in designing and on cs page I am generating label dynamically and adding those label in table layout panel..

    But not coming correct

    for (j = i; j < i + itemperrow; j++)

                           Label lbl = new Label();
                           PictureBox img = new PictureBox();

                           this.radContextMenuManager1.SetRadContextMenu(img, this.radContextMenu2);
                           img.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
                           img.Name = "imgbtn_" + dt.Rows[j]["NodeID"].ToString();
                           img.MouseEnter += new EventHandler(img_MouseEnter);
                           if (dt.Rows[j]["nodetype"].ToString() == "Folder")
                               img.Image = Properties.Resources.folder_icon;                         

                           lbl.Name = "lbl_" + dt.Rows[j]["NodeID"].ToString();
                           lbl.Text = dt.Rows[j]["NodeHTML"].ToString();
                           lbl.ForeColor = System.Drawing.ColorTranslator.FromHtml("#000000");


    plz help me
  2. Svett
    Svett avatar
    728 posts

    Posted 06 May 2011 Link to this post

    Hi goldy,

    Unless there is something that I do not understand, your question seems to be related to the TableLayoutPanel control. I would kindly ask you to address your questions regarding this control in the appropriate Microsoft Forums. You can read more about the control in this MSDN article.

    the Telerik team
    Q1’11 SP1 of RadControls for WinForms is available for download; also available is the Q2'11 Roadmap for Telerik Windows Forms controls.
Back to Top