Hi,
I have the following code.
try{
Twitter twitter = new Twitter(user,password);
twitter.setStatus(txtStatus.getText());
JOptionPane.showMessageDialog(null, "Success");
txtStatus.setText("");
txtStatus.requestFocus();
}catch(Exception e){
JOptionPane.showMessageDialog(null, "Some Error.\n" +
" If you see this after Success Message..Ignore");
}
Here even after I get "Success message" Dialog, the "Some Error" dialog is also appearing. what may be the reason? Shouldnt the flow control escape the catch block if there were no run time errors.
Even if i get an exception also, the "Some Error" dialog is appearing twice.Why is this happenning?