TreeView is not beeing updated and displays old information after page changes |
| ali fakheri replied to Aravind Kumar at 09-May-08 06:24 |
Dear Kumar,
Thank you for the link. It doesn't help me, I didn't understand well in the post, how finally they fixed the issue.
Here is the code:
string issue = Request.QueryString[0];
IssueSelecter issueSelecter = new IssueSelecter(issue, this.Page); XElement currentIssue = issueSelecter.getSelectedIssue();
TreeNodeBinding alternativeNodes = new TreeNodeBinding(); alternativeNodes.Depth = 0; alternativeNodes.TextField = "title";
TreeNodeBinding positionNodes = new TreeNodeBinding(); positionNodes.Depth = 1; positionNodes.TextField = "title";
TreeView1.DataBindings.Add(alternativeNodes); TreeView1.DataBindings.Add(positionNodes);
XmlDataSource xds = new XmlDataSource(); xds.Data = currentIssue.ToString(); xds.XPath = "//Issue/*"; TreeView1.DataSource = xds;
TreeView1.DataBind();
-----------------------------------------------------------------------
|
|