I have a textfield and columntree in a page. I want to construct the url for the TreeLoader based on the userinput in the textfield.

All the columntree examples I saw sets the loader and its url at the time of creation of the tree.

How can I dynamically change the loader URL for the columntree?

Also the tree should load its data only when the user enters a value in the textfield and clicks a button.

I tried setting
tree.loader.url = <new url>
in the button's click event and then tried
. But it didn't work.