I have a webservice in c# ,I want to access it via my android device through adhoc , I am able to get it in emulator using 10.0.2.2; but can't see on android device, Kindly suggest me any method to access that.
This is online webservice on w3school i am able to access it via my android device
private final String NAMESPACE = "http://www.w3schools.com/webservices/";
private final String URL = "http://www.w3schools.com/webservices/tempconvert.asmx";
private final String SOAP_ACTION = "http://www.w3schools.com/webservices/CelsiusToFahrenheit";
private final String METHOD_NAME = "CelsiusToFahrenheit";
This is url of my local webservice http://localhost:63693/Notif.asmx unable to access via android phone , though in emultor it is working http://10.0.2.2:63693/Notif.asmx
You also need to turn windows feature on . Go to -> Control Panel -> Add or Remove Program -> Turn Windows feature on or off -> .Net framework 4.5 advanced service -> WCF Services -> HTTP Activation . Enable this and Restart ur PC .
Use adhoc on android and connect your machine to it, simply use MachineIP:PortNo/Webservice.asmx
For custom IP - Enable IIS in turn features on or off .Run inetmgr via administrator and add your website there after that right Click edit bindings use IP or hostname whatever you want.