Issue #21006:set mode to view if closed
Merge pull request #123 from garyhgohoos/21006-2

Issue #21006:set mode to view if closed