Click here to Skip to main content
16,016,795 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I sent the parameter 'q' using javascript using the AJAX as

C#
var sendingStr = "Default.aspx?q=" + document.getElementById('q').value;
xmlHttpRequest.open("GET", sendingStr, true);



=============================================================================



now, using C# on my Default.aspx page, i want to get the 'q' parameter's value.

I searched web. it was somewhat talking like...

qStr = Request.QueryString["q"].ToString();

i debugged. its showing qStr as empty

it did not worked. Where's the error?

How can i get that parameter?
Posted
Updated 26-Jul-11 5:15am
v2

 
Share this answer
 
 
Share this answer
 
v2
Comments
Manas Bhardwaj 26-Jul-11 11:18am    
+5
raju melveetilpurayil 26-Jul-11 11:21am    
thank you :)
It should be :

Request.QueryString["q"];


http://www.w3schools.com/asp/asp_ref_request.asp[^]
 
Share this answer
 
Comments
raju melveetilpurayil 26-Jul-11 11:22am    
my +5

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900