I can write this code in Page load
con = new SqlConnection(System.Configuration.ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString);
da = new SqlDataAdapter("Select URL from Table1 where ID =" + Session["USERID"], con);
cb = new SqlCommandBuilder(da);
ds = new DataSet();
da.Fill(ds, "Table1");
string pageUrl = ds.Tables["Table1"].Rows[0]["URL"].ToString();
Response.Redirect(pageUrl);
This code working fine
I want to this code working on Hyperlink click
Like below
<li><a href="http://Mysite.azurewebsites.net/?ID=<%=Session["USERID"]%>" target="_blank">URLS</a></li>
How can i modify my code?