I'm looking to create a batch file that will create, move folder name based on user input.
Example: What is your account? (user inputs an account name like 123RS456 or 78-910)
Test 1: The user inputs 123RS456
Test 2: The user inputs 78-910
Test 3: The user inputs 123-4567
That batch file creates folder based on characters in the account name and moves that folder.
Result for Test 1: C:\Accounts\Accounts_with_RS\456_123EA456 -the batch takes every character after 'RS' and renames it before an underscore
Result for Test 2: C:\Accounts\Accounts_without_RS\78910 -the batch will remove the "-" dash.
Result for Test 3: C:\Accounts\Accounts_without_RS\1234567 -the batch will remove the "-" dash.
I've gotten as far as having the user input into a .txt file thinking I could rename it, and make a directory from it, but that is as far as I can get. Any help is appreciated
This is what I have so far,
@echo off
title intro color 1f
echo You will have to type the account name below
set /p FILENAME="What is your account? "
echo %FILENAME% > temp.txt
REN C:\Accounts\temp.txt %FILENAME%.txt - This does not work