Dynamic text -'undefined'

anyone has an idea why the dynamic text comes to ‘undefined’ when trying to load txt file, and sometimes simply won’t load txt unless I press button and then txt gets loaded?