0

When I am using with localhost the data is displaying in a web browser but it's not working with an emulator.

http://localhost:51411/api/MobileAPI/Authenticate?UID=abc&PWD=123&DeviceId=94944c77-931c-4cd3-aa23-889b9d8963f7

When I am using with android emulator is not working with this IP 10.0.2.2 not displaying the data

http://10.0.2.2:51411/api/MobileAPI/Authenticate?UID=abc&PWD=123&DeviceId=94944c77-931c-4cd3-aa23-889b9d8963f7

Plese find me solution

1 Answers1

0

You can use real IP of computer(the computer that emulator is running, example: 192.168.103.45) . If still not work you could try use newer API level . In my case i use API level 22, 24 and real IP. It work ok.

Tung Vo
  • 2,227
  • 5
  • 27
  • 45