Use the ASP HyperLink control.
<asp:hyperlink id="lnkMyLink" runat="server" test="Click Here!!" xmlns:asp="#unknown" />
Then, on the Page_Load:
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
string query =
lnkMyLink.NavigateUrl = String.Format("http://www.com.Sample.aspx?name={0}", query);
}
}
Should work fine!