Batch-Rename heterogeneous file extensions to one extension <p>I have multiple files each with a different extension in a folder. I need to rename all of them to one extension (.txt).</p> <p><a href="https://i.stack.imgur.com/ScJII.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ScJII.jpg" alt="enter image description here"></a></p> <p>I have tried with the following command:</p> <pre><code>ren *.* "%fname%:~0,-3%.txt" </code></pre> <p>But I receive the following error:</p> <pre><code>A duplicate file name exists, or the file cannot be found. </code></pre> <p>In short I need to convert all files in a folder of miscellaneous types to one type(.txt)</p> <p>Please help. Thanks in Advance</p>