Link to home
Start Free TrialLog in
Avatar of conrad2010
conrad2010

asked on

QueryString has a value but not in code behind

when calling a page with a querystring, there is clearly a value there (i.e. www.mydomain.com/mypage.aspx?pair=value

in code behind (C#) the querystring shows up empty...

protected void Page_Load(object sender, EventArgs e)
{
        var qs = Request.QueryString["pair"].ToString()
}

and the variable "qs" turns up empty...

any idea how that could happen? There are no redirects, it's all plain and simple...
Avatar of HainKurt
HainKurt
Flag of Canada image

try this

var qs = Request.QueryString["pair"]

put a bp, and see what you get

or try this

var qs = Request["pair"]

i dont see any reason to loose the query string param...
Avatar of conrad2010
conrad2010

ASKER

bp turns up empty, either way I try this... been working with asp.net ever since it came out... never seen anything like this either...
ASKER CERTIFIED SOLUTION
Avatar of HainKurt
HainKurt
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
try creating a brand new page --> that worked...