alternative to DataNavigateUrlField

2 posts, 0 answers
  1. Magnus Modig
    Magnus Modig avatar
    4 posts
    Member since:
    Jan 2008

    Posted 20 Oct 2013 Link to this post

    Hi


    I use the DataNavigateUrlField property to transfer users to Another page when they click a node in the tree, is there Another way to do that using JavaScript instead, for example I use this exsisting JavaScript..



    <script type="text/javascript">
     
     
        function onNodeClicked(sender, args) {
            var node = args.get_node();
            node.set_expanded(!node.get_expanded());
        }
     
        function nodeClicking(sender, args) {
     
            var nodeAtt = args.get_node().get_attributes().getAttribute("toClick");
            if (nodeAtt == "NotClickable") {
                args.set_cancel(true);
                var node = args.get_node();
                node.set_expanded(!node.get_expanded());
            }
        }
    </script>




    Can this be modified to transfer the user to the page that is defined using the DataNavigateUrlField property?









  2. Kate
    Admin
    Kate avatar
    1898 posts

    Posted 23 Oct 2013 Link to this post

    Hi Magnus,

    Did you try using the get_navigateUrl()/set_navigateUrl() property of the node as described at the end of this help article? Is this useful in your scenario or I am missing something?

    Regards,
    Kate
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top