Posted on: 5/30/2012 9:22:31 PM | Views : 242

i fairly new to using ascx controls
i am creating a menu and using an ascx control as a navigation menu.  it works fine unless i click on the page on the menu that i am currently on.  
so if i am on the staff page and click staff i get the multiple controls with the same id error. 
i have in the ascx code an if not postback  but I cannot figure out how to fix this. 
code below. 
can i use the properties of the control to help.   for example  clientidmode  enableviewstate  or viewstatemode  
thanks
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load

If Not IsPostBack Then
Dim ag As String
ag = Request.QueryString("ag")
Dim substring1 As String = ag.Substring(0, 1)
Dim substring2 As String = ag.Substring(1, 1)
Dim substring3 As String = ag.Substring(2, 1)
Dim Faculty As String = "F"< ...

Go to the complete details ...