Bit more code

View type change button
Added icons
Better error handling