windows - Batch file with simple FC command runs forever -


why simple batch file run forever printing out only line inside .bat file on , over

my fc.bat file contents

fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" 

my desktop dir/

fc.bat file1.txt file2.txt! 

here image of cmd prompt after double clicking fc.bat

output is

... c:\users\a\desktop>fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" c:\users\a\desktop>fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" c:\users\a\desktop>fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" c:\users\a\desktop>fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" c:\users\a\desktop>fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" c:\users\a\desktop>fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" c:\users\a\desktop>fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" c:\users\a\desktop>fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" c:\users\a\desktop>fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" ... 

it looks batch file in infinite loop calls on , on again.

fc "%userprofile%\desktop\file1.txt" "%userprofile%\desktop\file2.txt" 

that calling fc.bat, running same command. default, batch files print out line of code run, why seeing output.


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -