I have C# page to send parameters to an webservice and the webservice is not in the same project. I know the url of the webservice. How can I pass the parameters, I've tried the code below
Response.Redirect(" http://url/mobileservice.asmx/kioskOyunKodu?kioskkod='+kioskID+',kioskKodEncryped='+encodedCode+',okulno='+txt_StudentID.Text'");
Is there any other way to solve this issue when I execute that line I got
A potentially dangerous Request.Path value was detected from the client (:).
There is a space for creativity for this particular case:
GET
request ID
and then you can pass the id as a parameter between your service url POST
reqest with data You Url is wrongly formed and you have included special character in your redirect URL. That why you received A potentially dangerous Request.Path value was detected from the client (:) exception.
Below is how URL are formed with querystring.
Response.Redirect("http://url/mobileservice.asmx/kioskOyunKodu?kioskkod="+ kioskID + "&kioskKodEncryped=" + encodedCode + "&okulno=" + txt_StudentID.Text);
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.