added robust functionality to login and tasklist. added refresh