Quantcast
Channel: Windows PowerShell forum
Viewing all articles
Browse latest Browse all 21975

How to make "universal" move command

$
0
0
Hello

So, I'm writing a small batch-file  that I want to be able to distribute among my friends.

But, I want the batch-file to run every time they login. So, to do this I must write a seperate batch-file (a "set-up" batch-file) that moves the first file from a given folder (let's assume everyone puts the file in the same folder on their desktop) to the "start-up" folder.

This is what I have thus far but, I keep getting an invalid syntax error. What is wrong with this bit ?

move %USERPROFILE%\desktop\cmd\*.* %USERPROFILE%\appdata\roaming\Microsoft\Windows\Start Menu\Programs\Startup

Also, is there a way to move a file that is within the same folder as the set-up batch file from that folder to the start-up folder ?

Thanks in advance !

Viewing all articles
Browse latest Browse all 21975

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>