new Thread(new Runnable(){
public void run() {
try {
Configuration conf = new PropertyConfiguration(new Properties());
OAuthAuthorization oauth = new OAuthAuthorization(conf,consumerKey,consumerSecret,token);
ImageUpload upload = ImageUpload.getTwitpicUploader(TWITPIC_API,oauth);
final String resultUrl = upload.upload(file,message);
Status s = twitter.updateStatus(message + " " + resultUrl);
final String tweetUrl = "http://twitter.com/"+s.getUser().getScreenName()+"/status/"+s.getId();
Core.getShared().defer(new Runnable(){
public void run() {
context.addNotification("Done uploading to Twitter");