[quote="mojojojo"]I have 3 treeviews on a form. When the form postback, is there an easy way for me to find out which tree is in focus. I have the same contextmenu on each tree and depending on which tree the user right clicks on I'll do a different processing.
Every context menu click event has an event argument which contains ID of the node associated with the event. So you just need to call flytreeview.FindByID(e.commandArgument) for all three treeview to find where the FundByID returns non null value.
[quote="mojojojo"]
Also I have another problem regarding the setting of the attribute value. In my program, I set the value of the Attribute of a node on the client side and I can see the value on the server side. However, after I've processed the information on the server side and try to reset the attribute value of that node, it didn' really update the info on the client side. When the next time the page postback, I see the same old attribute value on that node again. Do I have to force an update on the page after I finish the processing on the server side? If so, how do I force an update? Is there a method I can call?
Callback changes (including control values changes) does not affect treeview at all. You can use PopulateOnDemand callback only to add nodes and set these nodes properties. All other changes to treeview properties and hierarchy are not transfered to client side (for callback case).