Hi, Im doing a project which similiar like download manager. I have 1 of the function is it allow user to pause the file and they can resume the download later.I have google it, but unlucky i stil haven solve the problem (maybe i'm new in android and stupid to solve it).
the question is.. if one of the file was haven finish downloaded for internet, how to i get the current stream/size of the file? and how can i continues writting the file?
i have saw a code in java as below:
begin = downloaded;
file = (FileConnection) Connector.open("\sdcard\abc.mp3");
OutputStream output = file.openOutputStream(begin);
DataOutputStream dos = new DataOutputStream(output);
if(read != -1) {
dos.write(buffer, 0, read);
dos.flush();
downloaded += read;
}
But i'm not really understand how it work in android :( Your reply is very appreciated!!!
P/S: I'm sorry about my bad english, hope you guys understand what i'm talking about. Thank you.
Regard
Wynix