Adding a custom tree

Ooopps, this video is for subscribers-only

To access this video, you need to be logged in and be an umbraco.tv subscriber.

Please login or signup for umbraco.tv here

get instant access to umbraco.tv

Comments on this video

  1. Dean Beasley Says:

    Gravatar Image

    This has to be the best video tutorial I have ever seen. Clear, logical and at good pace.

  2. gregg dourgarian Says:

    Gravatar Image

    yes very well done tutorial...i don't imagine ever needing to add a section but very helpful to see someone swimming around inside parts of umbraco i haven't touched before

  3. oskar Says:

    Gravatar Image

    Mind your steps! Seems like RenderJS is obsolete! I've used:

    public override void Render(ref XmlTree tree)
    {
    IRecordsReader reader = Application.SqlHelper.ExecuteReader("SELECT * FROM op_product");
    while (reader.Read())
    {
    XmlTreeNode xNode = XmlTreeNode.Create(this);
    xNode.NodeID = reader.GetInt("prdID").ToString();
    xNode.Text = reader.GetString("prdInternalName");
    xNode.Icon = "icon_shop_product.png";

    xNode.Action = "JavaScript: parent.right.document.location.href = '/umbraco/plugins/editProduct.aspx?id=" + xNode.NodeID + "'; void(0);";
    tree.Add(xNode);
    }
    }

    but this could probably solved in a much better way.

  4. Nathan Scherff Says:

    Gravatar Image

    Can you explain how i can add extra levels in nodes?

    like

    -base
    --a
    ---all records starting with an a
    --b
    ---all records starting with a b
    --c


    etc.

    I can only add treenodes to the tree and no treenodes can have children.
    How do i solve this?

  5. Troels Larsen Says:

    Gravatar Image

    Nathan Scherff u can use the xNode.source to add child nodes



Brilliant umbraco hosting provided by FAB-IT