My question is about WCF service I wrote in C#, and android client which consume it using “REST” protocol.
I am using example from this link:
I am working with visual studio 2010 .net framework 4.
I wrote a simple WCF service and deployed it to IIS on windows 7.
I succeed to access the service from android (10.0.2.2 is localhost when using android emulator):
It returns HTML test page with “200 OK”.
But when I try to access the function “GetPlates” in the service (or any other function) I get “HTTP/1.1 400 Bad Request”:
This is my function declaration in my interface:
UriTemplate = "/GetPlates",
BodyStyle = WebMessageBodyStyle.WrappedRequest,
ResponseFormat = WebMessageFormat.Json,
RequestFormat = WebMessageFormat.Json)]
How can I know if my functions are accessible from "outside" users using “REST” protocol?
I tried a lot, adding and removing function attributes but I still get the error.
I will appreciate any help with this.
Thanks in advance!