Added code to take a snapshot.
UI updates.