Added method for closing table documents.