Error when running Office 365 install via batch

Posted on 2014-08-26
Last Modified: 2014-08-27
Hi All, Ive got a batch file which runs at startup. It Assists in our migration of Office 2010 to 365 ProPlus (Locally installed).  When I run the batch it says /Config is an invalid switch and  'Setup Executed and ended with error Code 0', could someone be so kind as it look over the script and tell me that Im not going slowly mental. :) BTW Im far from a script expert so there may be mistakes in there!


REM *********************************************************************
REM Environment customization begins here. Modify variables below.
REM *********************************************************************
REM Get ProductName  
set "ProductName=O365ProPlusRetail - en-us"
REM Set DeployServer to a network-accessible location containing the Office source files.
set DeployServer=\\\netlogon\Office\Office15
REM Set ConfigFile to the configuration file to be used for deployment (required)
set ConfigFile=\\\netlogon\Office\Office15\config.xml
REM Set LogLocation to a central directory to collect log files.
set LogLocation=\\\netlogon\Office\Office15\InstallLogFiles
REM *********************************************************************
REM Deployment code begins here. Do not modify anything below this line.
REM *********************************************************************

REM Checks if office 365 is already installed, if so it skips to the end.

if exist "C:\Program Files\Microsoft Office 15\root\office15\OUTLOOK.EXE" goto End
REM Run setup here.
start /wait %DeployServer%\setup.exe /config %ConfigFile%
echo %date% %time% Setup executed and ended with error code %errorlevel%. >> %LogLocation%\%computername%.txt

REM This cscript called offscrub and removes all office 2010 programs due to ALL switch

cscript "\\\netlogon\Office\OffScrub10.vbs" /ALL
REM If 0 or other was returned, the product was found or another error occurred. Do nothing.
Question by:Jonathan Mckee
    1 Comment
    LVL 37

    Accepted Solution

    I'm not sure if it accepts shortened notations, the full switch should be /Configure.

    Lots of info is available on the internet, try for example this guide:

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    IT, Stop Being Called Into Every Meeting

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Get an idea of what you should include in an email disclaimer with these Top 5 email disclaimer tips.
    Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
    The viewer will learn how to successfully download and install the SARDU utility on Windows 7, without downloading adware.
    Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

    761 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    11 Experts available now in Live!

    Get 1:1 Help Now