Well, I doubt this is the most efficient way, but in your code behind, you can check the Request.RawUrl, and compare it to each treeview nodes NavigateUrl property one by one. Where they match, you set the nodes selected property to true...if anyone knows a more efficient way where you don't have to iterate through the nodes array, let me know!
Code:
Protected Sub trVw_DataBind(ByVal sender As Object, ByVal e As EventArgs) Handles trVw.DataBound
For Each treeVwNode As TreeNode In trVw.Nodes
If (treeVwNode.NavigateUrl = Request.RawUrl) Then
treeVwNode.Selected = True
End If
Next
End Sub
Neil Timmerman
Programmer
Veris Consulting