Click here to Skip to main content
15,891,184 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
hello friends,


here i want to develop the wcf web services and inserting values into mysql through android.

thanking you in advance,
Posted

1 solution

You need to understand the concepts of a Web Service, WCF is just a technology that can be used to create a web service.

A Web Service is a just an application that acts as a server that can be used by the devices connected, to pass on some data, to execute any function on the server. WCF is the technology used in this process. Using WCF you can host the web service in any application, even a Console application and access the service through any application even websites and execute a set of commands on the server (in our case; see the last paragraph, a Console application). Android application would just be a client, that would be using the service to pass on a few data, to execute a function or so on.

But there would be a few things you need to understand,


  • Your web service would be hosted on a computer, with a Uri specified for the clients to communicate with it at.
  • The code to save the data in the MySQL database would be a part of the Web Service function, not the Android application.
  • Create a module, that would connect to MySQL and would save the data to it.
  • You will send the data from the Android application to your web service to save the data.
  • Send a response to the Android application then.


I have written an article[^] on that, and that contains a sample code for creating the web service using WCF and using a website as a client, you can create an Android application as a client.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900