Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Apr 27, 2009 01:51 PM by DreamBig
Apr 25, 2009 09:24 AM|LINK
i want to strictly pass the querystring from aspx page & not from code behind then how to do it?
<asp:HyperLink ID="HyperLink1" runat="server" Text="Pay"
NavigateUrl='<%# "Payment.aspx?S=" & Request.QueryString("S") %>' />
but it doesn't work.From code behind it works.
But i want it from aspx page or else is it not possible.
Also the hyperlink is not inside gridview.
passing querystring parameters from aspx page
Apr 25, 2009 03:13 PM|LINK
So is HyperLink1 passing the value to the next page? If so your syntax is wrong. It should be <%# "Payment.aspx?S=" Eval("ValueForS") %>. You would use that syntax if you were trying to get the value from a sending page.
Apr 25, 2009 03:52 PM|LINK
If you don't want server side access for the control... then only use a html anchor tag:
<a href='Payment.aspx?S=<%= Request.QueryString("S") %>'>Pay</a>
Any doubt, post your comment.
Apr 27, 2009 10:48 AM|LINK
I m trying to get the value from the sending page.
I have value of S on one page & from that page I want that value & redirect to another page.
but using NavigateUrl='<%# "Payment.aspx?S=" & Request.QueryString("S") %>' , is not working.
it works on page load of the first page i set page.databind().
why so???any ideas??without it also it shud work...
Apr 27, 2009 10:52 AM|LINK
Have you tried to construct it in your code, maybe in the Page Load event?
HyperLink1.NavigateUrl = "Payment.aspx?S=" + Request.QueryString["S"];
Apr 27, 2009 11:42 AM|LINK
u can also use Application.Set("name", & ___ &) method.... and retrive the value from Application.get("name") in the page whr u want to retrivw the value
Apr 27, 2009 01:51 PM|LINK
@malcolms - from code behind it does work..but i want it in aspx page.