简体   繁体   中英

WCF: Call Service using parameter in URL with &

I have my WCF service with URL template like..

http://localhost:8448/service/SearchProduct/{productid}/{categoryid}/{search}/{pageSize}
/{currPage}

Here, I want to call this service path by using & parameters in the URL, like..

http://localhost:8448/service/SearchProduct/?productid=10&categoryid=34&search=newproducts&pageSize=10&currPage=5

But when I call service using above path, I got the exception "Endpoint not found."

Could you please tell me How would I call this service by using passing parameter in the URL with &categoryid=10&currPage=10 ??

Thanks in Advance!

Try to modify your URI template like that :

http://localhost:8448/service/SearchProduct/?productid={productid}&categoryid={categoryid}&search={search}...

It should work

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.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM