DefStringList $productProperty$

DefVar  $reboot$
Set     $reboot$ = "false"

if ($sereby_dotnet1.1$ = "uninstall")
    Winbatch_dotnet1.1_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_dotnet1.1")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_dotnet2.0$ = "uninstall")
    Winbatch_dotnet2.0_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_dotnet2.0")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_dotnet3.0$ = "uninstall")
    Winbatch_dotnet3.0_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_dotnet3.0")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_dotnet3.5$ = "uninstall")
    Winbatch_dotnet3.5_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_dotnet3.5")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_dotnet4.0$ = "uninstall")
    Winbatch_dotnet4.0_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_dotnet4.0")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_dotnet4.5$ = "uninstall")
    Winbatch_dotnet4.5_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_dotnet4.5")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_msjsharp$ = "uninstall")
    Winbatch_msjsharp_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_msjsharp")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_silver$ = "uninstall")
    Winbatch_silver_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_silver")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_jre$ = "uninstall")
    Dosbatch_jre_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_jre")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_AdobeShock$ = "uninstall")
    Winbatch_AdobeShock_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_AdobeShock")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_basicruntimes$ = "uninstall")
    Winbatch_basicruntimes_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_basicruntimes")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_msdx9$ = "uninstall")
    Winbatch_msdx9_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_msdx9")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_msdxm$ = "uninstall")
    Winbatch_msdxm_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_msdxm")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_msvc$ = "uninstall")
    Winbatch_msvc_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_msvc")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_AdobeFlash$ = "uninstall")
    Winbatch_AdobeFlash_uninstall
    set $productProperty$ = addtolist($productProperty$, "[newmap]")
    set $productProperty$ = addtolist($productProperty$, "type=productProperty")
    set $productProperty$ = addtolist($productProperty$, "productId=$ProductId$")
    set $productProperty$ = addtolist($productProperty$, "property=sereby_AdobeFlash")
    set $productProperty$ = addtolist($productProperty$, "value=install")
    set $productProperty$ = addtolist($productProperty$, "objectId=%opsiserviceUser%")
    Set $reboot$ = "true"
endif
if ($sereby_java_reinstall$ = "true")
    Dosbatch_java_reinstall
endif

markErrorNumber
OpsiServiceHashList_productProperty_updateObjects
if errorsOccuredSinceMark > 0
    isFatalError
endif

if ($reboot$ = "true")
    comment "uninstall done now force Reboot"
    ExitWindows /ImmediateReboot
endif

[OpsiServiceHashList_productProperty_updateObjects]
"method": "productProperty_updateObjects"
"HashList": "$productProperty$"
"params": [
          ]

[Winbatch_dotnet1.1_uninstall]
%ScriptPath%\UnInstall\NET\cleanup_tool.exe /q:a /c:"cleanup.exe /p .NET Framework 1.1 /u"

[Winbatch_dotnet2.0_uninstall]
%ScriptPath%\UnInstall\NET\cleanup_tool.exe /q:a /c:"cleanup.exe /p .NET Framework 2.0 /u"

[Winbatch_dotnet3.0_uninstall]
%ScriptPath%\UnInstall\NET\cleanup_tool.exe /q:a /c:"cleanup.exe /p .NET Framework 3.0 /u"

[Winbatch_dotnet3.5_uninstall]
%ScriptPath%\UnInstall\NET\cleanup_tool.exe /q:a /c:"cleanup.exe /p .NET Framework 3.5 /u"

[Winbatch_dotnet4.0_uninstall]
%ScriptPath%\UnInstall\NET\cleanup_tool.exe /q:a /c:"cleanup.exe /p .NET Framework 4.0 /u"

[Winbatch_dotnet4.5_uninstall]
%ScriptPath%\UnInstall\NET\cleanup_tool.exe /q:a /c:"cleanup.exe /p .NET Framework 4.5 /u"

[Winbatch_msjsharp_uninstall]

[Winbatch_silver_uninstall]

[DosBatch_jre_uninstall]
; copy "%ScriptPath%\UnInstall\Package\JRE\JavaRa.*" "$LogDir$\"
; $LogDir$\JavaRa.exe /SILENT /PURGE /UPDATEDEFS
@echo off
cscript /nologo "%ScriptPath%\UnInstall\Package\JRE\JavaUninstallScript.vbs" /keeponly

[Dosbatch_java_reinstall]
@echo off
cscript /nologo "%ScriptPath%\UnInstall\Packages\JRE\JavaUninstallScript.vbs" /keeponly

[Winbatch_AdobeShock_uninstall]

[Winbatch_basicruntimes_uninstall]

[Winbatch_msdx9_uninstall]

[Winbatch_msdxm_uninstall]

[Winbatch_msvc_uninstall]

[Winbatch_AdobeFlash_uninstall]



