Skip to main content
16-Pearl
September 24, 2018
Solved

How to assign the selected tree node after refresh in tree

  • September 24, 2018
  • 2 replies
  • 1801 views

Hi,

 

I have created tree widget and assigned nodes. My tree structure is different for different user.

How to retain the selected tree node after refresh the tree. Every 2 mins , refreshing the tree structure.

Refresh event is mapped to tree build service.

In Tree widget, I have check the "autoselectfirstrow" property.

After opening the mashup , showing the first row. If i go the different node of tree and refresh the tree, its going to first node. I am expecting the selected node after refresh also. Even I have unselected "autoselectfirstrow". Its retaining selected row but problem is tree node structure is different for different user. In that case, i am getting the error at first node if login with different user.

 

Could you please advise how to assign selected tree node after refresh.Could you give the example.

 

Thank you in advance.

 

 

Best answer by vxavier

That's what I did:

 

I used an expression. Set the output for string and created a parameter, and I made the output this parameter.

 

I bound the SelectedBreadcrumb of the tree widget with the parameter of the expression.


I evaluated the expression with the refresh event that you use to refresh the tree data.

 

Then I bound the output of the expression to the SelectedValue of the Tree Widget.

It worked just fine.

2 replies

vxavier5-Regular MemberAnswer
5-Regular Member
September 24, 2018

That's what I did:

 

I used an expression. Set the output for string and created a parameter, and I made the output this parameter.

 

I bound the SelectedBreadcrumb of the tree widget with the parameter of the expression.


I evaluated the expression with the refresh event that you use to refresh the tree data.

 

Then I bound the output of the expression to the SelectedValue of the Tree Widget.

It worked just fine.

Support
October 15, 2018

Hi @vi1.

 

If the response provided by @vxavier answered your question, please mark it as the Accepted Solution for the benefit of others who may have the same question.

 

Regards.

 

--Sharon