Print to PDF creates long file name cannot delete

Most of the time when I print my invoices to PDF I change the file name to a customer-date.pdf name. One time, by mistake, I just pressed enter and took the default name. It created a file name so long it could not be deleted or renamed. Windows 10 dir /x would not even give me the correct short name to delete it. Had to copy all other files to another directory and delete the directory. Just thought I should post the problem.