Quantcast
Channel: SharePoint 2010 - Setup, Upgrade, Administration and Operations forum
Viewing all articles
Browse latest Browse all 13778

Running two Powershell commands in a batch file

$
0
0

Hello

I have two powershell commands below:

Update-SPInfoPathUserFileUrl -Site http://somesite -find "http://oldsite" -replace "http://newsite"
Update-SPInfoPathUserFileUrl -Site "http://somesite1" -find "http://oldsite" -replace "http://newsite"

I put these two commands in a Powershell script called "RunCmds.ps1". I then created a batch file to run the scripts.

When I double click the batch file, the first command runs but throws an error message "Cannot perform the action request because an existing Form Library URL Repair timer job is still running."

So this means the first command is running, how do I get the second command to wait for the first one to finish?

Thank you.

Yoshi


Viewing all articles
Browse latest Browse all 13778

Trending Articles



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