changing to sprintf as well to handle exec, fixing typo
adding default cases
changing to use GetMigrationDir() for remote locations on scan