i am new to android and java development and want some help.
this question may sound stupid, but i am trying to make an android application that sends a file (located on an android device) to a java server running on PC(windows) using FTP (android client and java server are connected to the same wireless network). i have gone through so many questions but that cannot satisfy my answer.
i have also gone through some libraries - jftp and simpleftp but i really dont know how to use it. some piece of code might be useful.
consider file on android /sdcard/temp/sample.rar of size 100 mb.
p.s. - file can be on any type. and can be of large size 100 - 150 mb.
i am currently using TCP to send messages from android client to java server.
some code....
clientSocket = serverSocket.accept();
DataInputStream dis = new DataInputStream(clientSocket.getInputStream());
String command = dis.readUTF();
String prefix = command.substring(0,3);
String postfix = command.substring(3);
if(prefix.equals("key"))
{
new Thread()
{
public void run()
{
System.out.println("key postfix" + postfix);
int keyCode = Integer.parseInt(postfix); <br/>
keyPress(keyCode);
}
}.start();
}