asales Expert Licensed User Longtime User Feb 18, 2019 #1 In this post https://www.b4x.com/android/forum/threads/to-read-txt-file-with-more-fields.102809/#post-644839 Erel says: "Never use TextReader. Use File.ReadList or File.ReadString." I use the TextReader because the enconding. See the code: B4X: Dim tr As TextReader tr.Initialize2(Job.GetInputStream,"ISO-8859-1") parser.Parse2(tr, "Parser") - Why don't use TextReader? - How I can change my code (or I don't need in this case)? Thanks in advance.
In this post https://www.b4x.com/android/forum/threads/to-read-txt-file-with-more-fields.102809/#post-644839 Erel says: "Never use TextReader. Use File.ReadList or File.ReadString." I use the TextReader because the enconding. See the code: B4X: Dim tr As TextReader tr.Initialize2(Job.GetInputStream,"ISO-8859-1") parser.Parse2(tr, "Parser") - Why don't use TextReader? - How I can change my code (or I don't need in this case)? Thanks in advance.
Erel B4X founder Staff member Licensed User Longtime User Feb 18, 2019 #2 The correct statement should be: Never use TextReader unless you need to read a file with an encoding other than UTF8. Upvote 0
The correct statement should be: Never use TextReader unless you need to read a file with an encoding other than UTF8.