0

I apologize because my English is not good. I Have a webpage by asp.net that contain one treeview ,xmldatasource,one xml file that related to xmldatasource and one iframe. When user click on a treenode a webpage will be shown in iframe. Now I want when treenodes clicked , my url (e.g "www.mysite.com/default.aspx") change to ("www.mysite.com/default.aspx?onenode") and if I directly enter this url ("www.mysite.com/default.aspx?onenode") on browser mypage shown and that treenode is selected and page(onenode) is shown on iframe . there a way to solve the my problem there? I am waiting for your help. Thank you for Perpend.

2 Answers2

0

I would avoid the use of IFRAMEs and use AJAX to render the treenode detail instead. That way you are dealing with just one web page, rather than two, making your problem go away.

D'Arcy Rittich
  • 167,292
  • 40
  • 290
  • 283
0

I suppose you can easily do this by using the NavigateUrl property of the TreeNode to set the target URL. (You can construct this based on the Text/Value properties of the current TreeNode.

Also, you can set the target frame in which the page is to be loaded by setting the Target property of the TreeNode. In your case, it seems you would need to set it to the parent frame (the window itself).

Cerebrus
  • 25,615
  • 8
  • 56
  • 70