Executing using exe in SCCM

Hi,

Deploying a SCCM package containing toolkits files.
I intend to use this to uninstall Office 2010x64 and install Office 2013x86.
The ps1 file seems to run OK but I’m haviing difficulty getting this to work with the exe. Apparently in sccm you need to use the exe rather than the ps1 directly.
i had tried the below commandline, which fails:
“Powershell.exe” -ExecutionPolicy Bypass -File .\Deploy-Application.ps1 -DeployMode ‘Silent’

Running ‘Deploy-Application.ps1’ as the LOCAL SYSTEM is OK, as it uninstalls office 2010x64 and installs 2013x86.

when running the ‘Deploy-Application.exe’ (even as administrator) it fails. (info below from the log file):

2016/07/18 17:26:59:225::[7904] Installation of 32-bit Office product blocked as supported 64-bit Office product already installed.
2016/07/18 17:26:59:225::[7904] The following are a list of the 64-bit Office product(s) installed :
2016/07/18 17:26:59:225::[7904] Microsoft Office Office 32-bit Components 2010
2016/07/18 17:26:59:225::[7904] Microsoft Office Professional Plus 2010
2016/07/18 17:26:59:225::[7904] See Setup.chm for more information.

I have read the manual and it doesn’t specify any particular parameters I need to use.

Any suggestions?

Using the ps1 from the example folder:

seems i need to somehow modify the ‘Deploy-Application.ps1’ to execute the 32-bit version of CSCRIPT.exe and not the 64-bit.
Any ideas on how to do that?
Tried modifying line 185 without any success:

Execute-Process -Path “%Systemroot%\SysWOW64\cscript.exe” -Parameters “”$dirSupportFiles\OffScrub10.vbs" ClientAll /S /Q /NoCancel" -WindowStyle Hidden -IgnoreExitCodes ‘1,2,3’

Hi what I did was include the following code just above the Pre-installation phase.

## Configure correct paths for cscript depending on architecture.
if ($is64Bit -and -not($is64BitProcess))
{
    [string]$exeCscript = "$envWinDir\SysNative\cscript.exe"
} else {
    [string]$exeCscript = "$envWinDir\system32\cscript.exe"
}

To start the offscrub I have used this.

<backtick> = should be replaced by an actual backtick.

Execute-Process -Path "$exeCscript" -Parameters "<backtick>"$dirSupportFiles$OffScrub<backtick>" $OffScrubArgs" -WindowStyle Hidden -IgnoreExitCodes '1,2,3,16,42,67'