ASP.NET Web Service from Server

GaganSinghGaganSingh Gagandeep SinghUSMember, University

So I have an application that grabs data from a database through a web service. I want to put the web service onto a server so I can use the application anywhere, without having to be on my network.

Steps I took
1. I put the web service (.asmx + c# files) on the server.
2. I created a solution with an android project and a web service project (doesnt have .asmx + c# files because I put them on the server)
3. Right clicked the web service project and clicked add as link and added the .asmx file and c# files from the server.
4. I then tried to add a web reference (to get the web service) in the android project.

ERROR:
5. It works fine if i added the .asmx file and c# file but I get errors when I try to add as link.
Im getting an Error 400 – Bad Request when I try to add a web reference after I add as link.

GOAL:
I want to reference the web service on the web server. And if I simply add it, it creates a copy of it in the web services folder. So I assume I would need to add as link to the web service

please help me!

Sign In or Register to comment.