I have following link in a.aspx file:
<a href="a.htm" target="iframe">A</a>
I want to set link from a.aspx.vb page according to what person is viewing the page.
How can i change this so that if user clicks on link it will replace current frameset contained in current window with a url provided according to user?
Or in another way:
How will i replace href code in aspx page by giving it value from aspx.vb page?
You can either make your current link accessible to the code-behind (your vb file) or use an .NET WebControl.
To make your HTML control visible to your code-behind, you need to add
runat="server"and an ID:Then in your code-behind, you would access the control with the ID you gave the control earlier:
You could also use an ASP HyperLink control:
And set it in the code-behind: