findstr.exe returns 'dots' between all characters from text file

  • Thread starter Thread starter alpo486
  • Start date Start date
A

alpo486

when I create a text file with:

wmic ntdomain get /value > z:\test\test.txt

then run

findstr /i /r ".*" z:\test\test.txt

The output has a dot between each character.
Is there any way to strip these out? The text.txt file only displays these
dots when used with findstr.exe
 
Answered it myself:

FINDSTR.EXE can't handle UNICODE, which is the default output format of most
CLI commands.

SOLUTION: use "TYPE [filename]>[newfilename]" and TYPE converts the text to
ANSI, which you can then use with FINDSTR.EXE
 
Back
Top