Hi Everyone,
I've been watching your videos about AutoHotKey but I'm a beginner yet and I think It will take a long time for understanding and make my own scripts. Thing is I need just now resolve the next problem:
1. I Have a Music Folder. Inside I have several Sub Floders named like "Billy Joel - Greatest Hits". Because I have several albums for same artist I could have another "Billy Joel - Greatest song, etc.
2. I Need create a new folder with just artist name (Text to the right of " - "
3. Then I nedd put inside this folder all folder beginning with this artist name (Name of the new folder)
4. I need to erase the name of the artist in moved folders so result in for example "Greatest Hits"
I've trying several ways but im stocked. So I will thank you so much your help.
Help with Multi Folder Script
Re: Help with Multi Folder Script
Welcome to this AutoHotkey forum!
Code: Select all
#Requires AutoHotkey v2.0
musicDir := StrReplace(A_Desktop, 'Desktop', 'Music')
Loop Files musicDir '\* - *', 'DR' ; Get the source directories
RegExMatch(A_LoopFileName, '(.+?) - (.+)', &m) ; Parse into directory and subdirectory
, DirMove(A_LoopFilePath, musicDir '\' m[1] '\' m[2])
MsgBox 'Done!', 'Status', 64
-
- Posts: 2
- Joined: 24 Mar 2023, 21:24
Re: Help with Multi Folder Script
Thank You So Much.
I receive:
Error: Hotkey or hotstring is missing its opening brace.
Line: 4
I receive:
Error: Hotkey or hotstring is missing its opening brace.
Line: 4
Re: Help with Multi Folder Script
Did you run the script exactly as posted, or did you try adding a hotkey or something?