Quantcast
Channel: Configuration Manager 2012 - Application Management forum
Viewing all articles
Browse latest Browse all 4762

Copying a batch file from SCCM to Clients

$
0
0

Hi Everyone,

I have 2 batch files. First batch file is supposed to copy the 2nd batch file to the client's StartupFolder of the client and 2nd batch file is supposed to kill a task on the client.

1st Batch file contains the code below:

copy /y "%~dp0killmytask.bat" "C:\Users\%username%\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup" 


So, I created a package and pointed my bat file in Command Line area. Because I will deploy this package to the clients which are not in my local network, I think I can not use UNC name. So I selected "Requires drive letter" option. Program can run "whether or not a user logged on".

All I need is to copy a file via SCCM  to the client's startup folder. Can you please verify if my batch file coding is correct. 

Or am I doing something else wrong? Thanks a lot.


Yavuz Selim Atmaca


Viewing all articles
Browse latest Browse all 4762

Trending Articles



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