@fbk,
For security reasons, browsers restrict cross-origin requests. The text and the html files both have to be on the same server. You can set up a local server if you want to read the file directly.
Please refer stackOverflow for more information.
___
Suyash Singh
Team CanvasJS