Hi,
I'd like users to be able to cancel the current upload operation, however, calling the code below doesn't work and often the image upload continues until completed:
// Set hardware back button to close connection
dlg.setBackCommand(new Command("Cancel") {
@Override
public void actionPerformed(ActionEvent evt) {
if (NetworkManager.getInstance() != null) {
NetworkManager.getInstance().killAndWait(r);
dlg.dispose();
}
}
});
Any idea how to prevent the upload from continuing when cancelled?
Many thanks