We help IT Professionals succeed at work.

How to tell if a text file has tabs in it ?

brgdotnet
brgdotnet asked
on
83 Views
Last Modified: 2018-09-25
How can I tell i a text file has tabs in it? I have  vb.net code, but it is not recognizing the tabs, so I am wondering if there are actually tabs in the text file.
Comment
Watch Question

Dr. KlahnPrincipal Software Engineer
CERTIFIED EXPERT

Commented:
The legacy method would be to read the text file line by line, parsing each line to see if there is a 0x11 / HT / horizontal tab character in any byte.

Regrettably that method works 100% only in ASCII / UTF-8 source files.  For files encoded in other character sets the situation is more complicated.
brgdotnetcontractor

Author

Commented:
Thanks. Is there any editing tool which might physically show the actual tab? I Think the old Word Perfect use to allow for that type of feature. It would be real nice if I could somehow examine the file, and observe the embedded control characters.
Principal Software Engineer
CERTIFIED EXPERT
Commented:
This problem has been solved!
(Unlock this solution with a 7-day Free Trial)
UNLOCK SOLUTION