URGENT added exception handling.