Added functionality for retrieving file path from button.