[Android] phone data to a computer (WiFi)
4.0
How to transfer data from mobile phone to a computer via WIFI? We can use the ServerSocket (Server side) and socket (Client side) to implement as an example, Selected a photograph sent from the phone to the computer, Here it must be noted, Server and client needs in the same URL. Computer side (Server): First customize a port (this is set to 1111), then build a ServcerSocket, Then call accept () method, this method would have been to wait until the client side even come in, The program will execute the next line. Side of the build method, I use eclipse, direct NEW-> Java project, after the program comes in, Press RUN (Ctrl + F11) to perform, and then wait for the Android side even come. Android terminal (Client): Here I designed, the program started, we chose a photograph sent to the computer side, Is divided into two stages: When the