You are on page 1of 36

Installer for DevExpress VCL FullSource (D7-DXE6)

*** Tested with v14.1.2 and v13.2.5 ***


Features Installer:

Compiling VCL packages (32bit and 64bit)


- Searching for installed TeeChart Version and modifying according DPK-files
- Searching for installed FireDAC/AnyDAC Version

Installing packages into IDE

Updating Search Path and Browsing Path

Compile errors are displayed on the screen and logged in detail to


'Log_Errors.txt'

ProgressBar is shown in the TitleBar of the console window


Install.bat (1000 lines)
Code:
@echo off
@color 1F
setlocal enabledelayedexpansion
%~d0
cd %~p0
rem
rem
rem
rem
rem
rem
rem
rem
rem
rem
rem
rem

****************************************************************************
*
* DevExpress VCL FullSource - Installer for D7-DXE6
*
* Tasks:
*
1) Compiling VCL packages (32bit and 64bit)
*
- Searching for installed TeeChart Version and modifying DPK-files
*
- Searching for installed FireDAC/AnyDAC Version
*
2) Installing packages into IDE
*
3) Updating Search Path and Browsing Path
*
*****************************************************************************

set "TestMode=OFF"
set starttime=%time%
set "varEcho="
set "varLogFile= >nul 2>&1"
if "%TestMode%"=="ON" (
set "varEcho=echo"
set "varLogFile= >> "%~dp0Log_TestMode.txt""
echo TestMode - LogFile > "%~dp0Log_TestMode.txt"
)
rem ---------------------------------------------------------rem Administrative permissions required
rem ---------------------------------------------------------net session >nul 2>&1
if %errorLevel% == 0 (
rem Success: Administrative permissions confirmed.
) else (
echo ERROR: Administrative permissions required.
echo.
echo INFO: Run batch-file again as ADMIN ...
echo.
pause
goto end
)

rem ----------------------------------------rem BAT file must be executed in <installdir>


rem ----------------------------------------if not exist "%~dp0ExpressQuantumGrid\Sources\cxGrid.pas" (
echo ERROR: Current directory is not installdir
echo.
echo INFO: Run batch-file in installdir ...
echo.
pause
goto end
)
call :GetDXVersion "%~dp0ExpressCore Library\Sources\Dxcore.pas" DXVers
TITLE Installing DevExpress VCL v!DXVers!
set /a major_vers=!DXVers:~0,2!
rem -----------------rem Setting installdir
rem -----------------set "INSTALLDIR=%~dp0"
set "INSTALLDIR=!INSTALLDIR:~0,-1!"
set "TestNote="
if "%TestMode%"=="ON" set "TestNote=T E S T M O D E"
echo ===========================================================================
echo Installing DevExpress VCL v!DXVers!
!TestNote!
echo ===========================================================================
rem -------------------------rem Copying *.dfm *.res *.inc
rem -------------------------if NOT "!TestMode!"=="ON" (
for /f "eol=r tokens=*" %%a in ('dir *. /b') do
Common /Y /I >nul 2>&1
for /f "eol=r tokens=*" %%a in ('dir *. /b') do
Common /Y /I >nul 2>&1
for /f "eol=r tokens=*" %%a in ('dir *. /b') do
Common /Y /I >nul 2>&1
set /a nError=0
)
rem ---------------rem RUN INSTALLATION
rem ----------------

xcopy "%~dp0%%a\Sources\*.res"
xcopy "%~dp0%%a\Sources\*.dfm"
xcopy "%~dp0%%a\Sources\*.inc"

call :func_install DXE6


set endtime=%time%
if NOT "%TestMode%"=="ON" (
echo Started at: %starttime%
echo Finished at: %endtime%
if !nError! GEQ 1 (
echo. >> Log_Errors.txt
echo Total sum of compile errors: !nError! >> Log_Errors.txt
echo.
echo -------------------------------------------------------echo ATTENTION:
echo Total sum of compile errors: !nError!
echo See file 'Log_Errors.txt' for more details ...
echo -------------------------------------------------------)
)
echo.
if "%TestMode%"=="ON" (
echo *** All commands were logged to: Log_TestMode.txt ***
echo.
echo.

)
pause
:end
exit
rem
==================================================================================
rem
F U N C T I O N S
rem
==================================================================================
:func_install
set p1=%1_
set "str=D7_D2007_D2010_DXE_DXE2_DXE3_DXE4_DXE5_DXE6_"
if "x!str:%p1%=!"=="x%str%" (
echo.
echo ERROR: %1 not supported
echo.
Choose !str:~0,-1!
echo.
echo INFO: BAT file will be terminated now ...
echo.
pause
exit
)
CALL :func_HKCU BDSHKCU %1
CALL :func_rootdir ROOTDIR reg QUERY !BDSHKCU! /v RootDir
if not exist "!ROOTDIR!\Bin\dcc32.exe" (
echo ERROR: Compiler
echo
"!ROOTDIR!\Bin\dcc32.exe"
echo
NOT found
echo.
echo INFO: BAT file will be terminated now ...
echo.
pause
exit
)
set /a nCount=0
set /a nProgress=0
call :progress 0 >nul 2>&1
CALL :func_64Bit Is64BitSupport %1
CALL :func_Suffix SUFFIX %1
CALL :func_BDSCommonDir BDSCOMMONDIR %1
set
set
set
set

"BPLDir=!BDSCOMMONDIR!\Bpl"
"DCPDir=!BDSCOMMONDIR!\Dcp"
"RKeySearch32=!BDSHKCU!\Library"
"RKeySearch64="

set "D2010_OR_HIGHER=YES"
set "Edition=%1"
set "LIBSubDir32=!Edition!"
set "LIBSubDir64="
if "!Is64BitSupport!"=="YES" (
set "RKeySearch32=!BDSHKCU!\Library\Win32"
set "RKeySearch64=!BDSHKCU!\Library\Win64"
set "LIBSubDir32=!Edition!\Win32"
set "LIBSubDir64=!Edition!\Win64"
)
if "!Edition!"=="D7" (
set "DCPDir=!INSTALLDIR!\Library\D7"
set "D2010_OR_HIGHER=NO"
)
if "!Edition!"=="D2007" set "D2010_OR_HIGHER=NO"

if not exist "%BPLDir%" md "%BPLDir%"


if not exist "%DCPDir%" md "%DCPDir%"
if "!Is64BitSupport!"=="YES" (
if not exist "%BPLDir%\Win64" md "%BPLDir%\Win64"
if not exist "%DCPDir%\Win64" md "%DCPDir%\Win64"
)
rem ====================================
rem Search TeeChart, FireDAC and AnyDAC
rem ====================================
CALL :Search_Path TeeChartPath "reg QUERY "!BDSHKCU!\Known_Packages" /s" mytee
\DclTeePro
CALL :Search_Path FireDACPath "reg QUERY "!BDSHKCU!\Known_Packages" /s" dmy
\dclFireDAC
CALL :Search_Path AnyDACPath "reg QUERY "!BDSHKCU!\Known_Packages" /s" dmy
\AnyDAC_Dcl
set IsFireDAC=FALSE
if NOT "!FireDACPath!"=="" Set IsFireDAC=TRUE
if NOT "!AnyDACPath!"=="" Set IsFireDAC=TRUE
echo - Installing to %1
if NOT "!mytee!"=="" (
echo - TeeChart: !mytee! PRO
echo
!TeeChartPath!
)
rem echo - %1 is installed in "!ROOTDIR!"
echo
(ProgressBar is shown in TitleBar of Console Window)
echo.
if NOT "!TestMode!"=="ON" (
if exist "!INSTALLDIR!\Library\!LIBSubDir32!" del "!INSTALLDIR!\Library\!
LIBSubDir32!\*.*" /S /Q >nul 2>&1
if exist "!INSTALLDIR!\Library\!LIBSubDir64!" del "!INSTALLDIR!\Library\!
LIBSubDir64!\*.*" /S /Q >nul 2>&1
if not exist "!INSTALLDIR!\Library\!LIBSubDir32!"
md Library\!LIBSubDir32!
if "!Is64BitSupport!"=="YES" (
if not exist "!INSTALLDIR!\Library\!LIBSubDir64!" md Library\!LIBSubDir64!
)
)
if "%mytee%"=="" GOTO :DoCompile
if "%mytee%"=="Standard" GOTO :DoCompile
if "!TestMode!"=="ON" GOTO :DoCompile
rem --------------------------rem Modifying 4 TEE-Chart files
rem --------------------------rem
dxPSTeeChartxx.dpk
rem
dcldxPSTeeChartxx.dpk
rem
dxPSDBTeeChartxx.dpk
rem
dcldxPSDBTeeChartxx.dpk
rem --------------------------echo Modifying Tee Chart Packages for %1
for /f "eol=r tokens=*" %%a in ('dir "ExpressPrinting System\Packages\*TeeChart!
SUFFIX!.dpk" /b') do (
if not exist "%~dp0ExpressPrinting System\Packages\%%a.bak" (
copy "%~dp0ExpressPrinting System\Packages\%%a" "%~dp0ExpressPrinting
System\Packages\%%a.bak" >nul 2>&1
)
Call :TEE_Modify "%~dp0ExpressPrinting System\Packages\%%a.bak"
)
:DoCompile
rem ----------------------------------

rem Compiling 32bit and 64bit packages


rem ---------------------------------set "DCC32=!ROOTDIR!\Bin\dcc32.exe"
set "DCC64=!ROOTDIR!\Bin\dcc64.exe"
set "CompInfo=Compiling 32bit"
if "!Is64BitSupport!"=="YES" (
if exist "!DCC64!" set "CompInfo=!CompInfo! and 64bit"
)
echo !CompInfo! Packages for %1
set "TEEPATH32=!TeeChartPath!"
set "TEEPATH64=!TeeChartPath!"
if NOT "!TEEPATH64!"=="" Set "TEEPATH64=!TEEPATH64:WIN32\=WIN64\!
set "ANYPATH32=!AnyDACPath!"
set "ANYPATH64=!AnyDACPath!"
if NOT "!ANYPATH64!"=="" Set "ANYPATH64=!ANYPATH64!\Win64"
echo
...ExpressCore Library
call :comp32 dxCore ExpressCore_Library
call :comp32 dcldxCore ExpressCore_Library
call :progress 1 >nul 2>&1
echo
...XP Theme Manager
call :comp32 dxTheme XP_Theme_Manager
echo
...ExpressGDI+ Library
call :comp32 dxGDIPlus ExpressGDI+_Library
echo
...ExpressLibrary
call :comp32 cxLibrary ExpressLibrary
call :comp32 dclcxLibrary ExpressLibrary
call :progress 2 >nul 2>&1
echo
...ExpressCommon Library
call :comp32 dxComn ExpressCommon_Library
echo
...ExpressDataController
call :comp32 cxData ExpressDataController
call :comp32 cxADOAdapters ExpressDataController
call :comp32 cxBDEAdapters ExpressDataController
call :comp32 cxIBXAdapters ExpressDataController
call :comp32 dxServerMode ExpressDataController
call :comp32 dcldxServerMode ExpressDataController
call :comp32 dxADOServerMode ExpressDataController
call :comp32 dxDBXServerMode ExpressDataController
if "!IsFireDAC!"=="TRUE" call :comp32 dxFireDACServerMode ExpressDataController
call :comp32 dcldxADOServerMode ExpressDataController
call :comp32 dcldxDBXServerMode ExpressDataController
if "!IsFireDAC!"=="TRUE" call :comp32 dcldxFireDACServerMode ExpressDataController
echo
...ExpressEditors Library
call :comp32 cxEditors ExpressEditors_Library
call :comp32 dclcxEditors ExpressEditors_Library
call :comp32 dclcxEditorFieldLink ExpressEditors_Library
echo
...ExpressExport Library
call :comp32 cxExport ExpressExport_Library
echo
...ExpressPageControl
call :comp32 cxPageControl ExpressPageControl
call :comp32 dclcxPageControl ExpressPageControl
echo
...ExpressLibrary II
call :comp32 dcldxIconLibrary ExpressLibrary
echo
...ExpressDocking Library
call :comp32 dxDocking ExpressDocking_Library
call :comp32 dcldxDocking ExpressDocking_Library
echo
...ExpressTile Control
call :comp32 dxTileControl ExpressTile_Control
call :comp32 dcldxTileControl ExpressTile_Control
echo
...ExpressWizard Control
call :comp32 dxWizardControl ExpressWizard_Control
call :comp32 dcldxWizardControl ExpressWizard_Control
echo
...ExpressBars
call :comp32 dxBar ExpressBars

call
call
call
call
call
call
call
call
call
call
call
call
call
echo
call
call
echo
call
call
call
echo
call
call

:comp32 dxTabbedMDI ExpressBars


:comp32 dxBarDBNav ExpressBars
:comp32 dxBarExtDBItems ExpressBars
:comp32 dxBarExtItems ExpressBars
:comp32 dcldxBarExtDBItems ExpressBars
:comp32 dxRibbon ExpressBars
:comp32 cxBarEditItem ExpressBars
:comp32 dcldxBar ExpressBars
:comp32 dcldxBarExtItems ExpressBars
:comp32 dcldxRibbon ExpressBars
:comp32 dcldxTabbedMDI ExpressBars
:comp32 dclcxBarEditItem ExpressBars
:comp32 dcldxBarDBNav ExpressBars
...ExpressPageControl II
:comp32 cxPageControldxBarPopupMenu ExpressPageControl
:comp32 dclcxPageControldxBarPopupMenu ExpressPageControl
...ExpressNavBar
:comp32 dxNavBar ExpressNavBar
:comp32 dcldxNavBar ExpressNavBar
:comp32 dxNavBarAdvancedCustomizeForm ExpressNavBar
...ExpressLayout Control
:comp32 dxLayoutControl ExpressLayout_Control
:comp32 dcldxLayoutControl ExpressLayout_Control

if !major_vers! GEQ 14 (
if "!D2010_OR_HIGHER!"=="YES" (
echo
...ExpressSpreadSheet
call :comp32 dxSpreadSheet ExpressSpreadSheet
call :comp32 dcldxSpreadSheet ExpressSpreadSheet
)
echo
...ExpressSpreadSheet [deprecated]
call :comp32 cxSpreadSheet ExpressSpreadSheet_[deprecated]
call :comp32 dclcxSpreadSheet ExpressSpreadSheet_[deprecated]
) ELSE (
echo
...ExpressSpreadSheet
call :comp32 cxSpreadSheet ExpressSpreadSheet
call :comp32 dclcxSpreadSheet ExpressSpreadSheet
)
echo
...ExpressMemData
call :comp32 dxmds ExpressMemData
call :comp32 dcldxmds ExpressMemData
echo
...ExpressDBTree Suite
call :comp32 dxdbtr ExpressDBTree_Suite
call :comp32 dcldxdbtr ExpressDBTree_Suite
call :comp32 dxtrmd ExpressDBTree_Suite
call :comp32 dcldxtrmd ExpressDBTree_Suite
echo
...ExpressFlowChart
call :comp32 dxFlowChart ExpressFlowChart
call :comp32 dcldxFlowChart ExpressFlowChart
echo
...ExpressQuantumTreeList
call :comp32 cxTreeList ExpressQuantumTreeList
call :comp32 cxTreeListdxBarPopupMenu ExpressQuantumTreeList
call :comp32 dclcxTreeListdxBarPopupMenu ExpressQuantumTreeList
call :comp32 dclcxTreeList ExpressQuantumTreeList
echo
...ExpressBars II
call :comp32 dxRibbonCustomizationForm ExpressBars
call :comp32 dcldxRibbonCustomizationForm ExpressBars
echo
...ExpressQuantumGrid
call :comp32 cxGrid ExpressQuantumGrid
call :comp32 dclcxGrid ExpressQuantumGrid
call :comp32 dclcxGridWizard ExpressQuantumGrid
echo
...ExpressVerticalGrid
call :comp32 cxVerticalGrid ExpressVerticalGrid
call :comp32 dclcxVerticalGrid ExpressVerticalGrid
echo
...ExpressOrgChart
call :comp32 dxOrgC ExpressOrgChart
call :comp32 dxDBOr ExpressOrgChart

call
call
call
echo
call
call
call
call
call
call
call
call
echo
call
call
call
call
call
call
echo
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call

:comp32 dcldxOrgC ExpressOrgChart


:comp32 dxOrgChartAdvancedCustomizeForm ExpressOrgChart
:comp32 dcldxDBOr ExpressOrgChart
...ExpressScheduler
:comp32 cxScheduler ExpressScheduler
:comp32 cxSchedulerGrid ExpressScheduler
:comp32 cxSchedulerTreeBrowser ExpressScheduler
:comp32 dclcxScheduler ExpressScheduler
:comp32 cxSchedulerRibbonStyleEventEditor ExpressScheduler
:comp32 dclcxSchedulerGrid ExpressScheduler
:comp32 dclcxSchedulerTreeBrowser ExpressScheduler
:comp32 dclcxSchedulerRibbonStyleEventEditor ExpressScheduler
...ExpressPivotGrid
:comp32 cxPivotGrid ExpressPivotGrid
:comp32 cxPivotGridOLAP ExpressPivotGrid
:comp32 cxPivotGridChart ExpressPivotGrid
:comp32 dclcxPivotGrid ExpressPivotGrid
:comp32 dclcxPivotGridOLAP ExpressPivotGrid
:comp32 dclcxPivotGridChart ExpressPivotGrid
...ExpressSkins Library
:comp32 dxSkinsCore ExpressSkins_Library
:comp32 dxSkinBlack ExpressSkins_Library
:comp32 dxSkinBlueprint ExpressSkins_Library
:comp32 dxSkinBlue ExpressSkins_Library
:comp32 dxSkinCaramel ExpressSkins_Library
:comp32 dxSkinCoffee ExpressSkins_Library
:comp32 dxSkinDarkRoom ExpressSkins_Library
:comp32 dxSkinDarkSide ExpressSkins_Library
:comp32 dxSkinDevExpressDarkStyle ExpressSkins_Library
:comp32 dxSkinDevExpressStyle ExpressSkins_Library
:comp32 dxSkinFoggy ExpressSkins_Library
:comp32 dxSkinGlassOceans ExpressSkins_Library
:comp32 dxSkinHighContrast ExpressSkins_Library
:comp32 dxSkiniMaginary ExpressSkins_Library
:comp32 dxSkinLilian ExpressSkins_Library
:comp32 dxSkinLiquidSky ExpressSkins_Library
:comp32 dxSkinLondonLiquidSky ExpressSkins_Library
:comp32 dxSkinMcSkin ExpressSkins_Library
:comp32 dxSkinMetropolisDark ExpressSkins_Library
:comp32 dxSkinMetropolis ExpressSkins_Library
:comp32 dxSkinMoneyTwins ExpressSkins_Library
:comp32 dxSkinOffice2007Black ExpressSkins_Library
:comp32 dxSkinOffice2007Blue ExpressSkins_Library
:comp32 dxSkinOffice2007Green ExpressSkins_Library
:comp32 dxSkinOffice2007Pink ExpressSkins_Library
:comp32 dxSkinOffice2007Silver ExpressSkins_Library
:comp32 dxSkinOffice2010Black ExpressSkins_Library
:comp32 dxSkinOffice2010Blue ExpressSkins_Library
:comp32 dxSkinOffice2010Silver ExpressSkins_Library
:comp32 dxSkinOffice2013DarkGray ExpressSkins_Library
:comp32 dxSkinOffice2013LightGray ExpressSkins_Library
:comp32 dxSkinOffice2013White ExpressSkins_Library
:comp32 dxSkinPumpkin ExpressSkins_Library
:comp32 dxSkinSevenClassic ExpressSkins_Library
:comp32 dxSkinSeven ExpressSkins_Library
:comp32 dxSkinSharpPlus ExpressSkins_Library
:comp32 dxSkinSharp ExpressSkins_Library
:comp32 dxSkinSilver ExpressSkins_Library
:comp32 dxSkinSpringTime ExpressSkins_Library
:comp32 dxSkinStardust ExpressSkins_Library
:comp32 dxSkinSummer2008 ExpressSkins_Library
:comp32 dxSkinTheAsphaltWorld ExpressSkins_Library
:comp32 dxSkinValentine ExpressSkins_Library
:comp32 dxSkinVS2010 ExpressSkins_Library
:comp32 dxSkinWhiteprint ExpressSkins_Library
:comp32 dxSkinXmas2008Blue ExpressSkins_Library
:comp32 dxSkinscxPCPainter ExpressSkins_Library

call :comp32 dxSkinsdxNavBarPainter ExpressSkins_Library


call :comp32 dcldxSkinsCore ExpressSkins_Library
call :comp32 dxSkinsdxBarPainter ExpressSkins_Library
call :comp32 dcldxSkinsDesignHelper ExpressSkins_Library
call :comp32 dxSkinsdxDLPainter ExpressSkins_Library
call :comp32 dxSkinsdxRibbonPainter ExpressSkins_Library
call :comp32 dcldxSkinscxEditorsHelper ExpressSkins_Library
call :comp32 dcldxSkinscxPCPainter ExpressSkins_Library
call :comp32 dcldxSkinsdxNavBarPainter ExpressSkins_Library
call :comp32 dxSkinsdxBarSkinnedCustomizationForm ExpressSkins_Library
call :comp32 dcldxSkinsdxBarsPainters ExpressSkins_Library
call :comp32 dcldxSkinsdxRibbonPainters ExpressSkins_Library
call :comp32 dxSkinscxSchedulerPainter ExpressSkins_Library
call :comp32 dcldxSkinscxSchedulerPainter ExpressSkins_Library
echo
...ExpressPrinting System
call :comp32 dxPSCore ExpressPrinting_System
call :comp32 dxPScxPCProd ExpressPrinting_System
call :comp32 dxPSLnks ExpressPrinting_System
call :comp32 dxPSTeeChart ExpressPrinting_System
call :comp32 dxPScxCommon ExpressPrinting_System
call :comp32 dxPScxSSLnk ExpressPrinting_System
call :comp32 dxPSDBTeeChart ExpressPrinting_System
call :comp32 dxPSdxLCLnk ExpressPrinting_System
call :comp32 dxPSdxOCLnk ExpressPrinting_System
call :comp32 dcldxPSCore ExpressPrinting_System
call :comp32 dxPScxExtCommon ExpressPrinting_System
call :comp32 dxPSdxDBTVLnk ExpressPrinting_System
call :comp32 dxPSdxFCLnk ExpressPrinting_System
call :comp32 dxPSdxSpreadSheetLnk ExpressPrinting_System
call :comp32 dxPSPrVwAdv ExpressPrinting_System
call :comp32 dcldxPSLnks ExpressPrinting_System
call :comp32 dcldxPSTeeChart ExpressPrinting_System
call :comp32 dxPSdxDBOCLnk ExpressPrinting_System
call :comp32 dxPSPrVwRibbon ExpressPrinting_System
call :comp32 dcldxPScxCommon ExpressPrinting_System
call :comp32 dcldxPSdxLCLnk ExpressPrinting_System
call :comp32 dcldxPSdxOCLnk ExpressPrinting_System
call :comp32 dcldxPScxExtCommon ExpressPrinting_System
call :comp32 dcldxPSDBTeeChart ExpressPrinting_System
call :comp32 dcldxPSdxDBTVLnk ExpressPrinting_System
call :comp32 dcldxPSdxFCLnk ExpressPrinting_System
call :comp32 dcldxPSdxSpreadSheetLnk ExpressPrinting_System
call :comp32 dcldxPSdxDBOCLnk ExpressPrinting_System
call :comp32 dcldxPSPrVwAdv ExpressPrinting_System
call :comp32 dcldxPSPrVwRibbon ExpressPrinting_System
call :comp32 dxPScxSchedulerLnk ExpressPrinting_System
call :comp32 dxPScxTLLnk ExpressPrinting_System
call :comp32 dxPScxVGridLnk ExpressPrinting_System
call :comp32 dxPScxPivotGridLnk ExpressPrinting_System
call :comp32 dxPScxGridLnk ExpressPrinting_System
call :comp32 dcldxPScxSchedulerLnk ExpressPrinting_System
call :comp32 dcldxPScxTLLnk ExpressPrinting_System
call :comp32 dcldxPScxVGridLnk ExpressPrinting_System
call :comp32 dcldxPScxGridLnk ExpressPrinting_System
call :comp32 dcldxPScxPivotGridLnk ExpressPrinting_System
call :comp32 dcldxPScxSSLnk ExpressPrinting_System
if !major_vers! GEQ 14 (
if "!D2010_OR_HIGHER!"=="YES" (
echo
...ExpressGauge Control
call :comp32 dxGaugeControl ExpressGauge_Control
call :comp32 dcldxGaugeControl ExpressGauge_Control
echo
...ExpressMap Control
call :comp32 dxMapControl ExpressMap_Control
call :comp32 dcldxMapControl ExpressMap_Control
)
)
echo
...ExpressSpellChecker

call :comp32 dxSpellChecker ExpressSpellChecker


call :comp32 dcldxSpellChecker ExpressSpellChecker
call :progress 98 >nul 2>&1
rem ---------------------------rem Installing Packages into IDE
rem ---------------------------echo.
echo Installing Packages into %1-IDE
call :InstIDE dcldxCore "ExpressCoreLibrary by Developer Express Inc."
call :InstIDE dclcxLibrary "Express Cross Platform Library by Developer Express
Inc."
call :InstIDE dxSkinBlack "ExpressSkins - Black Skin by Developer Express Inc."
call :InstIDE dxSkinBlueprint "ExpressSkins - Blueprint Skin by Developer Express
Inc."
call :InstIDE dxSkinBlue "ExpressSkins - Blue Skin by Developer Express Inc."
call :InstIDE dxSkinCaramel "ExpressSkins - Caramel Skin by Developer Express Inc."
call :InstIDE dxSkinCoffee "ExpressSkins - Coffee Skin by Developer Express Inc."
call :InstIDE dxSkinDarkRoom "ExpressSkins - Darkroom Skin by Developer Express
Inc."
call :InstIDE dxSkinDarkSide "ExpressSkins - DarkSide Skin by Developer Express
Inc."
call :InstIDE dxSkinDevExpressDarkStyle "ExpressSkins - DevExpressDarkStyle Skin by
Developer Express Inc."
call :InstIDE dxSkinDevExpressStyle "ExpressSkins - DevExpressStyle Skin by
Developer Express Inc."
call :InstIDE dxSkinFoggy "ExpressSkins - Foggy Skin by Developer Express Inc."
call :InstIDE dxSkinGlassOceans "ExpressSkins - GlassOceans Skin by Developer
Express Inc."
call :InstIDE dxSkinHighContrast "ExpressSkins - HighContrast Skin by Developer
Express Inc."
call :InstIDE dxSkiniMaginary "ExpressSkins - iMaginary Skin by Developer Express
Inc."
call :InstIDE dxSkinLilian "ExpressSkins - Lilian Skin by Developer Express Inc."
call :InstIDE dxSkinLiquidSky "ExpressSkins - LiquidSky Skin by Developer Express
Inc."
call :InstIDE dxSkinLondonLiquidSky "ExpressSkins - LondonLiquidSky Skin by
Developer Express Inc."
call :InstIDE dxSkinMcSkin "ExpressSkins - McSkin Skin by Developer Express Inc."
call :InstIDE dxSkinMetropolisDark "ExpressSkins - MetropolisDark Skin by Developer
Express Inc."
call :InstIDE dxSkinMetropolis "ExpressSkins - Metropolis Skin by Developer Express
Inc."
call :InstIDE dxSkinMoneyTwins "ExpressSkins - MoneyTwins Skin by Developer Express
Inc."
call :InstIDE dxSkinOffice2007Black "ExpressSkins - Office2007Black Skin by
Developer Express Inc."
call :InstIDE dxSkinOffice2007Blue "ExpressSkins - Office2007Blue Skin by Developer
Express Inc."
call :InstIDE dxSkinOffice2007Green "ExpressSkins - Office2007Green Skin by
Developer Express Inc."
call :InstIDE dxSkinOffice2007Pink "ExpressSkins - Office2007Pink Skin by Developer
Express Inc."
call :InstIDE dxSkinOffice2007Silver "ExpressSkins - Office2007Silver Skin by
Developer Express Inc."
call :InstIDE dxSkinOffice2010Black "ExpressSkins - Office2010Black Skin by
Developer Express Inc."
call :InstIDE dxSkinOffice2010Blue "ExpressSkins - Office2010Blue Skin by Developer
Express Inc."
call :InstIDE dxSkinOffice2010Silver "ExpressSkins - Office2010Silver Skin by
Developer Express Inc."
call :InstIDE dxSkinOffice2013DarkGray "ExpressSkins - Office2013DarkGray Skin by
Developer Express Inc."
call :InstIDE dxSkinOffice2013LightGray "ExpressSkins - Office2013LightGray Skin by
Developer Express Inc."

call :InstIDE dxSkinOffice2013White "ExpressSkins - Office2013White Skin by


Developer Express Inc."
call :InstIDE dxSkinPumpkin "ExpressSkins - Pumpkin Skin by Developer Express Inc."
call :InstIDE dxSkinSevenClassic "ExpressSkins - SevenClassic Skin by Developer
Express Inc."
call :InstIDE dxSkinSeven "ExpressSkins - Seven Skin by Developer Express Inc."
call :InstIDE dxSkinSharpPlus "ExpressSkins - SharpPlus Skin by Developer Express
Inc."
call :InstIDE dxSkinSharp "ExpressSkins - Sharp Skin by Developer Express Inc."
call :InstIDE dxSkinSilver "ExpressSkins - Silver Skin by Developer Express Inc."
call :InstIDE dxSkinSpringTime "ExpressSkins - Springtime Skin by Developer Express
Inc."
call :InstIDE dxSkinStardust "ExpressSkins - Stardust Skin by Developer Express
Inc."
call :InstIDE dxSkinSummer2008 "ExpressSkins - Summer2008 Skin by Developer Express
Inc."
call :InstIDE dxSkinTheAsphaltWorld "ExpressSkins - TheAsphaltWorld Skin by
Developer Express Inc."
call :InstIDE dxSkinValentine "ExpressSkins - Valentine Skin by Developer Express
Inc."
call :InstIDE dxSkinVS2010 "ExpressSkins - VS2010 Skin by Developer Express Inc."
call :InstIDE dxSkinWhiteprint "ExpressSkins - Whiteprint Skin by Developer Express
Inc."
call :InstIDE dxSkinXmas2008Blue "ExpressSkins - Xmas2008Blue Skin by Developer
Express Inc."
call :InstIDE dcldxFlowChart "ExpressFlowChart by Developer Express Inc."
call :InstIDE dcldxOrgC "ExpressOrgChart by Developer Express Inc."
call :InstIDE dxSkinscxPCPainter "ExpressSkins Library Painter for PageControl by
Developer Express Inc."
call :InstIDE dxSkinsdxNavBarPainter "ExpressSkins Library Painter for NavBar by
Developer Express Inc."
call :InstIDE dclcxPageControl "ExpressPageControl by Developer Express Inc."
call :InstIDE dcldxBarExtDBItems "ExpressBars extended DB items by Developer Express
Inc."
call :InstIDE dcldxdbtr "ExpressDBTree by Developer Express Inc."
call :InstIDE dcldxNavBar "ExpressNavBar by Developer Express Inc."
call :InstIDE dcldxSkinsCore "ExpressSkins Library by Developer Express Inc."
call :InstIDE dxSkinsdxBarPainter "ExpressSkins Library Painter for Bars by
Developer Express Inc."
call :InstIDE dclcxPageControldxBarPopupMenu "ExpressPageControl dxBar Popup Menu by
Developer Express Inc."
call :InstIDE dcldxBar "ExpressBars by Developer Express Inc."
call :InstIDE dcldxDBOr "ExpressDBOrgChart by Developer Express Inc."
call :InstIDE dcldxDocking "ExpressDocking Library by Developer Express Inc."
call :InstIDE dcldxMapControl "ExpressMapControl by Developer Express Inc."
call :InstIDE dcldxSkinsDesignHelper "ExpressSkins Library Uses Clause Auto Fill
Helper by Developer Express Inc."
call :InstIDE dxSkinsdxDLPainter "ExpressSkins Library Painter for Docking Library
by Developer Express Inc."
call :InstIDE dxSkinsdxRibbonPainter "ExpressSkins Library Painter for Ribbon by
Developer Express Inc."
call :InstIDE dclcxEditors "ExpressEditors Library by Developer Express Inc."
call :InstIDE dcldxBarExtItems "ExpressBars extended items by Developer Express
Inc."
call :InstIDE dcldxIconLibrary "Express Cross Platform Library Icon Library by
Developer Express Inc."
call :InstIDE dcldxRibbon "ExpressBars Ribbon controls by Developer Express Inc."
call :InstIDE dcldxSpellChecker "ExpressSpellChecker 2 by Developer Express Inc."
call :InstIDE dcldxSpreadSheet "ExpressSpreadSheet by Developer Express Inc."
call :InstIDE dcldxTabbedMDI "ExpressBars Tabbed MDI by Developer Express Inc."
call :InstIDE dcldxTileControl "ExpressTileControl by Developer Express Inc."
call :InstIDE dcldxPSCore "ExpressPrinting System by Developer Express Inc."
call :InstIDE dcldxSkinscxEditorsHelper "ExpressSkins Library Uses Clause Auto Fill
Helper for ExpressEditors by Developer Express Inc."
call :InstIDE dcldxSkinscxPCPainter "ExpressSkins Library Uses Clause Auto Fill
Helper for PageControl Painter by Developer Express Inc."

call :InstIDE dcldxSkinsdxNavBarPainter "ExpressSkins Library Uses Clause Auto Fill


Helper for NavBar Painter by Developer Express Inc."
call :InstIDE dclcxBarEditItem "ExpressBars cxEditor item by Developer Express Inc."
call :InstIDE dcldxLayoutControl "ExpressLayout Control by Developer Express Inc."
call :InstIDE dcldxPSLnks "ExpressPrinting System ReportLinks (Standard) by
Developer Express Inc."
call :InstIDE dcldxPSTeeChart "ExpressPrinting System ReportLink for TeeChart by
Developer Express Inc."
call :InstIDE dcldxPScxCommon "ExpressPrinting System Cross Platform Library by
Developer Express Inc."
call :InstIDE dcldxPSdxLCLnk "ExpressPrinting System ReportLink for
ExpressLayoutControl by Developer Express Inc."
call :InstIDE dcldxPSdxOCLnk "ExpressPrinting System ReportLinks for ExpressOrgChart
by Developer Express Inc."
call :InstIDE dcldxPScxExtCommon "ExpressPrinting System Extended Cross Platform
Library by Developer Express Inc."
call :InstIDE dcldxPSDBTeeChart "ExpressPrinting System ReportLink for DBTeeChart by
Developer Express Inc."
call :InstIDE dcldxPSdxDBTVLnk "ExpressPrinting System ReportLink for ExpressDBTree
by Developer Express Inc."
call :InstIDE dcldxPSdxFCLnk "ExpressPrinting System ReportLinks for
ExpressFlowChart by Developer Express Inc."
call :InstIDE dcldxPSdxSpreadSheetLnk "ExpressPrinting System ReportLink for
ExpressSpreadSheet by Developer Express Inc."
call :InstIDE dcldxSkinsdxBarsPainters "ExpressSkins Library Uses Clause Auto Fill
Helper for Bars Painters by Developer Express Inc."
call :InstIDE dcldxPSdxDBOCLnk "ExpressPrinting System ReportLinks for
ExpressDBOrgChart by Developer Express Inc."
call :InstIDE dcldxPSPrVwAdv "ExpressPrinting System Advanced Preview Window by
Developer Express Inc."
call :InstIDE dcldxSkinsdxRibbonPainters "ExpressSkins Library Uses Clause Auto Fill
Helper for Ribbon Painters by Developer Express Inc."
call :InstIDE dcldxPSPrVwRibbon "ExpressPrinting System Ribbon Preview Window by
Developer Express Inc."
call :InstIDE dcldxGaugeControl "ExpressGaugeControl by Developer Express Inc."
call :InstIDE dcldxmds "ExpressMemData by Developer Express Inc."
call :InstIDE dcldxWizardControl "ExpressWizardControl by Developer Express Inc."
call :InstIDE dcldxtrmd "ExpressTreePrintedDataSet by Developer Express Inc."
call :InstIDE dcldxServerMode "ExpressDataController Server Mode by Developer
Express Inc."
call :InstIDE dcldxBarDBNav "ExpressBars DBNavigator by Developer Express Inc."
call :InstIDE dclcxEditorFieldLink "ExpressEditors FieldLink by Developer Express
Inc."
call :InstIDE dxSkinscxSchedulerPainter "ExpressSkins Library Painter for Scheduler
by Developer Express Inc."
call :InstIDE dclcxScheduler "ExpressScheduler by Developer Express Inc."
call :InstIDE dclcxVerticalGrid "ExpressVerticalGrid by Developer Express Inc."
call :InstIDE dclcxPivotGrid "ExpressPivotGrid by Developer Express Inc."
call :InstIDE dclcxTreeListdxBarPopupMenu "ExpressQuantumTreeList dxBar Built-In
Menu by Developer Express Inc."
call :InstIDE dclcxTreeList "ExpressQuantumTreeList by Developer Express Inc."
call :InstIDE dclcxPivotGridOLAP "ExpressPivotGrid OLAP by Developer Express Inc."
call :InstIDE dcldxSkinscxSchedulerPainter "ExpressSkins Library Uses Clause Auto
Fill Helper for Scheduler Painter by Developer Express Inc."
call :InstIDE dclcxGrid "ExpressQuantumGrid by Developer Express Inc."
call :InstIDE dclcxSchedulerGrid "ExpressScheduler connection to ExpressQuantumGrid
by Developer Express Inc."
call :InstIDE dclcxSchedulerTreeBrowser "ExpressScheduler tree browser by Developer
Express Inc."
call :InstIDE dclcxPivotGridChart "ExpressPivotGrid connection to ExpressQuantumGrid
Chart View by Developer Express Inc."
call :InstIDE dclcxSchedulerRibbonStyleEventEditor "ExpressScheduler Ribbon Event
Window by Developer Express Inc."
call :InstIDE dcldxPScxSchedulerLnk "ExpressPrinting System ReportLink for
ExpressScheduler by Developer Express Inc."
call :InstIDE dcldxPScxTLLnk "ExpressPrinting System ReportLink for
ExpressQuantumTreeList by Developer Express Inc."

call :InstIDE dcldxPScxVGridLnk "ExpressPrinting System ReportLink for


ExpressVerticalGrid by Developer Express Inc."
call :InstIDE dclcxGridWizard "ExpressQuantumGrid Wizard by Developer Express Inc."
call :InstIDE dcldxPScxGridLnk "ExpressPrinting System ReportLink for
ExpressQuantumGrid by Developer Express Inc."
call :InstIDE dcldxPScxPivotGridLnk "ExpressPrinting System ReportLink for
ExpressPivotGrid by Developer Express Inc."
call :InstIDE dcldxADOServerMode "ADO Data Source for ExpressDataController Server
Mode by Developer Express Inc."
call :InstIDE dcldxDBXServerMode "dbExpress Data Source for ExpressDataController
Server Mode by Developer Express Inc."
call :InstIDE dcldxFireDACServerMode "FireDAC Data Source for ExpressDataController
Server Mode by Developer Express Inc."
call :InstIDE dcldxRibbonCustomizationForm "ExpressBars Ribbon Customization Form by
Developer Express Inc."
call :InstIDE dcldxPScxSSLnk "ExpressPrinting System ReportLink for
ExpressSpreadSheet by Developer Express Inc."
call :InstIDE dclcxSpreadSheet "ExpressSpreadSheet by Developer Express Inc."
call :progress 99 >nul 2>&1
rem ---------------------------------------------------rem Adding Library Paths (Search Path and Browsing Path)
rem ---------------------------------------------------echo Adding Library Paths (Search Path and Browsing Path)
echo - Search Path (Win32)
call :func_path olddata25 reg QUERY !RKeySearch32! "Search Path"
%varEcho% reg ADD !RKeySearch32! /v "Search Path"
/d "!olddata25!;%INSTALLDIR
%\Library\!LIBSubDir32!;%INSTALLDIR%\Common" /f %varLogFile%
if "!Is64BitSupport!"=="NO" goto :Label_1
if NOT exist "!DCC64!" goto :Label_1
echo - Search Path (Win64)
call :func_path olddata25 reg QUERY !RKeySearch64! "Search Path"
%varEcho% reg ADD !RKeySearch64! /v "Search Path"
/d "!olddata25!;%INSTALLDIR
%\Library\!LIBSubDir64!;%INSTALLDIR%\Common" /f %varLogFile%
:Label_1
echo - Browsing Path (Win32)
call :func_path olddata25 reg QUERY !RKeySearch32! "Browsing Path"
%varEcho% reg ADD !RKeySearch32! /v "Browsing Path" /d "!olddata25!;%INSTALLDIR
%\ExpressCore Library\Sources;%INSTALLDIR%\XP Theme Manager\Sources;%INSTALLDIR
%\ExpressDataController\Sources;%INSTALLDIR%\ExpressCommon Library\Sources;
%INSTALLDIR%\ExpressGDI+ Library\Sources;%INSTALLDIR%\ExpressMemData\Sources;
%INSTALLDIR%\ExpressDBTree Suite\Sources;%INSTALLDIR%\ExpressLibrary\Sources;
%INSTALLDIR%\ExpressSkins Library\Sources;%INSTALLDIR%\ExpressPageControl\Sources;
%INSTALLDIR%\ExpressSpreadSheet\Sources;%INSTALLDIR%\ExpressSpreadSheet
(deprecated)\Sources;%INSTALLDIR%\ExpressFlowChart\Sources;%INSTALLDIR
%\ExpressNavBar\Sources;%INSTALLDIR%\ExpressOrgChart\Sources;%INSTALLDIR
%\ExpressDocking Library\Sources;%INSTALLDIR%\ExpressBars\Sources;%INSTALLDIR
%\ExpressEditors Library\Sources;%INSTALLDIR%\ExpressSpellChecker\Sources;
%INSTALLDIR%\ExpressLayout Control\Sources;%INSTALLDIR%\ExpressPrinting
System\Sources;%INSTALLDIR%\ExpressExport Library\Sources;%INSTALLDIR
%\ExpressScheduler\Sources;%INSTALLDIR%\ExpressVerticalGrid\Sources;%INSTALLDIR
%\ExpressPivotGrid\Sources;%INSTALLDIR%\ExpressQuantumTreeList\Sources;%INSTALLDIR
%\ExpressQuantumGrid\Sources;%INSTALLDIR%\ExpressTile Control\Sources;%INSTALLDIR
%\ExpressWizard Control\Sources;%INSTALLDIR%\ExpressGauge Control\Sources;
%INSTALLDIR%\ExpressMap Control\Sources" /f
%varLogFile%
if "!Is64BitSupport!"=="NO" goto :Label_2
if NOT exist "!DCC64!" goto :Label_2
echo - Browsing Path (Win64)
call :func_path olddata25 reg QUERY !RKeySearch64! "Browsing Path"
%varEcho% reg ADD !RKeySearch64! /v "Browsing Path" /d "!olddata25!;%INSTALLDIR
%\ExpressCore Library\Sources;%INSTALLDIR%\XP Theme Manager\Sources;%INSTALLDIR
%\ExpressDataController\Sources;%INSTALLDIR%\ExpressCommon Library\Sources;
%INSTALLDIR%\ExpressGDI+ Library\Sources;%INSTALLDIR%\ExpressMemData\Sources;

%INSTALLDIR%\ExpressDBTree Suite\Sources;%INSTALLDIR%\ExpressLibrary\Sources;
%INSTALLDIR%\ExpressSkins Library\Sources;%INSTALLDIR%\ExpressPageControl\Sources;
%INSTALLDIR%\ExpressSpreadSheet\Sources;%INSTALLDIR%\ExpressSpreadSheet
(deprecated)\Sources;%INSTALLDIR%\ExpressFlowChart\Sources;%INSTALLDIR
%\ExpressNavBar\Sources;%INSTALLDIR%\ExpressOrgChart\Sources;%INSTALLDIR
%\ExpressDocking Library\Sources;%INSTALLDIR%\ExpressBars\Sources;%INSTALLDIR
%\ExpressEditors Library\Sources;%INSTALLDIR%\ExpressSpellChecker\Sources;
%INSTALLDIR%\ExpressLayout Control\Sources;%INSTALLDIR%\ExpressPrinting
System\Sources;%INSTALLDIR%\ExpressExport Library\Sources;%INSTALLDIR
%\ExpressScheduler\Sources;%INSTALLDIR%\ExpressVerticalGrid\Sources;%INSTALLDIR
%\ExpressPivotGrid\Sources;%INSTALLDIR%\ExpressQuantumTreeList\Sources;%INSTALLDIR
%\ExpressQuantumGrid\Sources;%INSTALLDIR%\ExpressTile Control\Sources;%INSTALLDIR
%\ExpressWizard Control\Sources;%INSTALLDIR%\ExpressGauge Control\Sources;
%INSTALLDIR%\ExpressMap Control\Sources" /f %varLogFile%
:Label_2
echo.
echo.
call :progress 100 >nul 2>&1
echo Installation for DevExpress VCL v!DXVers! (%1) finished ...
echo.
goto:EOF
rem
==================================================================================
:comp32
set p1=%1
set p2=%2
set p2=%p2:_= %
set p2=%p2:[=(%
set p2=%p2:]=)%
rem ExpressSpreadSheet (deprecated) ... p3 otherwise ) gets lost in %2 comp64 %1 %2
... comp64 %1 !p3!
set p3=!p2: =_!
set ROOTLIB="!ROOTDIR!\lib"
set "NAMESPACES="
if "!Is64BitSupport!"=="YES" (
set ROOTLIB="!ROOTDIR!\lib\win32\release"
set "NAMESPACES=NSWinApi;System;System.Win;Vcl;Vcl.Imaging;Data;Data.Win;Bde;Xml;Vcl.Shell;VclTee;IB
X"
)
if NOT "!TEEPATH32!"=="" set ROOTLIB=!ROOTLIB!;"!TEEPATH32!"
if NOT "!ANYPATH32!"=="" set ROOTLIB=!ROOTLIB!;"!ANYPATH32!"
if not exist "%~dp0!p2!\Packages\%1!SUFFIX!.dpk" goto :Label_3
%varEcho% "%DCC32%" -R"%~dp0!p2!\Sources" -B -W -$C- -$D- -$L- -$O+ -$W- -$Y- -LE"!
BPLDir!" -LN"!DCPDir!" -N0"%~dp0Library\!LIBSubDir32!" -I"%~dp0Common";"%~dp0!
p2!\Sources";"%~dp0ExpressCore Library\Sources"; !NAMESPACES! -U"%~dp0Library\!
LIBSubDir32!";"%~dp0!p2!\Sources";!ROOTLIB! "%~dp0!p2!\Packages\%1!SUFFIX!.dpk"
%varLogFile%
if NOT "!TestMode!"=="ON" (
if errorlevel 1 (
echo *** COMPILE ERROR: %1!SUFFIX!.dpk - 32bit
if !nError! EQU 0 (
echo Compile Errors > Log_Errors.txt
echo. >> Log_Errors.txt
)
echo
*** COMPILE ERROR: %1!SUFFIX!.dpk - 32bit >> Log_Errors.txt
"%DCC32%" -R"%~dp0!p2!\Sources" -B -W -$C- -$D- -$L- -$O+ -$W- -$Y- -LE"!
BPLDir!" -LN"!DCPDir!" -N0"%~dp0Library\!LIBSubDir32!" -I"%~dp0Common";"%~dp0!
p2!\Sources";"%~dp0ExpressCore Library\Sources"; !NAMESPACES! -U"%~dp0Library\!

LIBSubDir32!";"%~dp0!p2!\Sources";!ROOTLIB!
Log_Errors.txt
set /a nError = !nError! + 1
echo. >> Log_Errors.txt
echo. >> Log_Errors.txt
)
)

"%~dp0!p2!\Packages\%1!SUFFIX!.dpk"

>>

:Label_3
set /a nCount = %nCount% + 1
Set /a remain = %nCount% %% 16
if %remain%==0 (
set /a nProgress = !nProgress! + 5
if NOT !nProgress! GTR 98 call :progress !nProgress! >nul 2>&1
)
if "!Is64BitSupport!"=="YES" (
if exist "!DCC64!" (
set "prae=!p1:~0,3!"
set "prae7=!p1:~0,7!"
if NOT "!prae!"=="dcl" (
if NOT "!prae7!"=="cxBDEAd" call :comp64 %1 !p3!
)
)
)
GOTO :EOF
rem
==================================================================================
:comp64
set p2=%2
set p2=%p2:_= %
set ROOTLIB="!ROOTDIR!\lib\win64\release"
if NOT "!TEEPATH64!"=="" set ROOTLIB=!ROOTLIB!;"!TEEPATH64!"
if NOT "!ANYPATH64!"=="" set ROOTLIB=!ROOTLIB!;"!ANYPATH64!"
if not exist "%~dp0!p2!\Packages\%1!SUFFIX!.dpk" goto :Label_4
%varEcho% "%DCC64%" -R"%~dp0!p2!\Sources" -B -W- -$C- -$D- -$L- -$O+ -$W- -$Y- -LE"!
BPLDir!\Win64" -LN"!DCPDir!\Win64" -N0"%~dp0Library\!LIBSubDir64!"
-I"%~dp0Common";"%~dp0!p2!\Sources";"%~dp0ExpressCore Library\Sources"
-NSWinApi;System;System.Win;Vcl;Vcl.Imaging;Data;Data.Win;Bde;Xml;Vcl.Shell;VclTee;I
BX -U"%~dp0Library\!LIBSubDir64!";"%~dp0!p2!\Sources";!ROOTLIB! "%~dp0!
p2!\Packages\%1!SUFFIX!.dpk"
%varLogFile%
if NOT "%TestMode%"=="ON" (
if errorlevel 1 (
echo *** COMPILE ERROR: %1!SUFFIX!.dpk - 64bit
if !nError! EQU 0 (
echo Compile Errors > Log_Errors.txt
echo. >> Log_Errors.txt
)
echo
*** COMPILE ERROR: %1!SUFFIX!.dpk - 64bit >> Log_Errors.txt
"%DCC64%" -R"%~dp0!p2!\Sources" -B -W- -$C- -$D- -$L- -$O+ -$W- -$Y- -LE"!
BPLDir!\Win64" -LN"!DCPDir!\Win64" -N0"%~dp0Library\!LIBSubDir64!"
-I"%~dp0Common";"%~dp0!p2!\Sources";"%~dp0ExpressCore Library\Sources"
-NSWinApi;System;System.Win;Vcl;Vcl.Imaging;Data;Data.Win;Bde;Xml;Vcl.Shell;VclTee;I
BX -U"%~dp0Library\!LIBSubDir64!";"%~dp0!p2!\Sources";!ROOTLIB! "%~dp0!
p2!\Packages\%1!SUFFIX!.dpk" >> Log_Errors.txt
set /a nError = !nError! + 1
echo. >> Log_Errors.txt
echo. >> Log_Errors.txt
)
)
:Label_4
set /a nCount = %nCount% + 1
Set /a remain = %nCount% %% 16

if %remain%==0 (
set /a nProgress = !nProgress! + 5
if NOT !nProgress! GTR 98 call :progress !nProgress! >nul 2>&1
)
GOTO :EOF
rem
==================================================================================
:InstIDE
if NOT exist "!BPLDir!\%1!SUFFIX!.bpl" (
if "!TestMode!"=="OFF" goto :Label_5
)
%varEcho% REG ADD "!BDSHKCU!\Known Packages" /v "!BPLDir!\%1!SUFFIX!.bpl"
/d
%2 /f %varLogFile%
:Label_5
REG DELETE "!BDSHKCU!\Disabled Packages" /v "!BPLDir!\%1!SUFFIX!.bpl" /f >nul 2>&1
REG DELETE "!BDSHKCU!\Package Cache\%1!SUFFIX!.bpl" /f >nul 2>&1
GOTO :EOF
rem
==================================================================================
:func_rootdir
set hlp=%2 %3 %4 %5 %6
for /f "tokens=* skip=2" %%a in ('!hlp!') do (
set "dmy=%%a"
set "dmy=!dmy:~21!
set "lastChar=!dmy:~-1!"
if "!lastChar!"=="\" set "dmy=!dmy:~0,-1!"
set "%1=!dmy!"
)
GOTO :EOF
rem
==================================================================================
:func_path
set hlp=%2 %3 %4 %5
for /f "tokens=* skip=2" %%a in ('%2 %3 %4 /v %5') do (
for /f "tokens=1,2,3,4* delims= " %%k in ('echo %%a') do (
if NOT "%%o"=="" (
set "olddata25=%%n %%o") ELSE (
set "olddata25=%%n"
)
)
)
set "%1=%olddata25%"
GOTO :EOF
rem
==================================================================================
:progress
SETLOCAL ENABLEDELAYEDEXPANSION
SET ProgressPercent=%1
rem if NOT "%ProgressPercent%"=="0" (
SET /A NumBars=%ProgressPercent%/2
SET /A NumSpaces=50-%NumBars%
SET Meter=
FOR /L %%A IN (%NumBars%,-1,1) DO SET Meter=!Meter!I
FOR /L %%A IN (%NumSpaces%,-1,1) DO SET Meter=!Meter!
TITLE Progress: [%Meter%] %ProgressPercent%%%
rem )
ENDLOCAL
GOTO :EOF
rem
==================================================================================
:TEE_Modify

set INIFILE="%~dpn1.tmp"
set DPKFile=%1
set DPKFile=!DPKFile:~0,-5!"
if exist %INIFILE% del %INIFILE% >nul 2>&1
for /f "tokens=* delims=" %%a in (%~s1) do (
set Line=%%a
set Line=!Line:tee,=tee%mytee%,!
set Line=!Line:tee;=tee%mytee%;!
set Line=!Line:teedb,=teedb%mytee%,!
set Line=!Line:teedb;=teedb%mytee%;!
set dmy=!Line!
for /l %%a in (1,1,100) do (
if "!dmy:~-1!"==" " set dmy=!dmy:~0,-1!
)
if NOT "!dmy!"=="" echo !Line!>>%INIFILE%
)
copy %INIFILE% %DPKFile% /Y
del %INIFILE% >nul 2>&1
exit /b

>nul 2>&1

rem
==================================================================================
:func_BDSCommonDir
if "%2"=="D7" (
CALL :func_HKCU RK1 D7
CALL :func_rootdir RDIR7 reg QUERY !RK1! /v RootDir
)
set "RS1=%RDIR7%\Projects"
set "RS2=%PUBLIC%\Documents\RAD Studio"
set "RS3=%PUBLIC%\Documents\Embarcadero\Studio"
set "NS=D7-%RS1%;D2007-%RS2%\5.0;D2010-%RS2%\7.0;DXE-%RS2%\8.0;DXE2-%RS2%\9.0;DXE3%RS2%\10.0;DXE4-%RS2%\11.0;DXE5-%RS2%\12.0;DXE6-%RS3%\14.0"
set v=%2
CALL SET v=%%NS:*%v%-=%%
SET v=%v:;=&rem.%
set %1=%v%
GOTO :EOF
rem
==================================================================================
:func_HKCU
set "RS1=HKCU\Software\Borland"
set "RS2=HKCU\Software\CodeGear"
set "RS3=HKCU\Software\Embarcadero\BDS"
set "NS=D7-%RS1%\Delphi\7.0;D2007-%RS1%\BDS\5.0;D2010-%RS2%\BDS\7.0;DXE%RS3%\8.0;DXE2-%RS3%\9.0;DXE3-%RS3%\10.0;DXE4-%RS3%\11.0;DXE5-%RS3%\12.0;DXE6%RS3%\14.0"
set v=%2
CALL SET v=%%NS:*%v%-=%%
SET v=%v:;=&rem.%
set %1=%v%
GOTO :EOF
rem
==================================================================================
:func_64Bit
set "NS=D7-NO;D2007-NO;D2010-NO;DXE-NO;DXE2-YES;DXE3-YES;DXE4-YES;DXE5-YES;DXE6-YES"
set v=%2
CALL SET v=%%NS:*%v%-=%%
SET v=%v:;=&rem.%
set %1=%v%

GOTO :EOF
rem
==================================================================================
:func_Suffix
set "NS=D7-D7;D2007-RS11;D2010-RS14;DXE-RS15;DXE2-RS16;DXE3-RS17;DXE4-RS18;DXE5RS19;DXE6-RS20"
set v=%2
CALL SET v=%%NS:*%v%-=%%
SET v=%v:;=&rem.%
set %1=%v%
GOTO :EOF
rem
==================================================================================
:Search_Path
set hlp=%2
set hlp=%hlp:_= %
set hlp=!hlp:~1,-1!
set "rck1="
set "rck2="
for /f "tokens=* skip=2" %%a in ('!hlp!') do (
Set "string=%%a"
call :Instr "!string!" "%4" pos
if NOT "!pos!"=="0" (
if "%4"=="\DclTeePro" (
call :Instr "!string!" ".bpl" pos2
set /a pos1 = !pos!+10
set /a pos2 = !pos2!-1
set /a pos3 = !pos2!-!pos1!+1
CALL :Substring version "!string!" !pos1! !pos3!
set "rck2=!version!"
)
set /a pos1=1
set /a pos3=!pos!-1
Set "string=%%a"
CALL :Substring tpath "!string!" !pos1! !pos3!

if "%4"=="\DclTeePro" set tpath=!tpath:\Bin=\Lib!


if NOT "!Edition!"=="D7" (
if "%4"=="\AnyDAC_Dcl" set tpath=!tpath:\BPL=\Dcp!
)
set "rck1=!tpath!"
)
)
set "%1=!rck1!"
if "%4"=="\DclTeePro" (set "%3=!rck2!") ELSE (set "%3=")
goto :EOF
rem
==================================================================================
:uppercase
for /F "delims=" %%a in ("%1%") do (
set "line=%%a"
for %%b in (A B C D E F G H I J K L M N O P Q R S T U V W X Y Z) do (
set "line=!line:%%b=%%b!"
)
set "%2=!line!"
)
goto :eof

rem ===============================================================
:Instr
setlocal enableextensions enabledelayedexpansion
echo %1|findstr %2>nul
if %errorlevel% EQU 1 (endlocal & set %3=0& goto :EOF)
set rest_=%1
set /a instr_=0
:_loop
set rest_=%rest_:~1%
echo !rest_!|findstr %2>nul
if %errorlevel% EQU 1 (endlocal & set %3=%instr_%& goto :EOF)
set /a instr_ +=1
goto _loop
rem
==================================================================================
:Substring
::Substring(retVal,string,startIndex,length)
:: extracts the substring from string starting at startIndex for the specified
length
SET string=%2%
SET startIndex=%3%
SET length=%4%
if "%4" == "0" goto :noLength
CALL SET _substring=%%string:~%startIndex%,%length%%%
goto :substringResult
:noLength
CALL SET _substring=%%string:~%startIndex%%%
:substringResult
set "%~1=%_substring%"
GOTO :EOF
rem
==================================================================================
:GetDXVersion
rem dxBuildNumber: Cardinal = 20130205;
for /f "tokens=* delims=" %%a in (%~s1) do (
set "line1=%%a"
set "line2=!line1!"
set "line2=!line2:dxBuildNumber:=!"
if NOT "!line1!"=="!line2!" (
for /f "tokens=1,2,3 delims==;" %%r in ('echo !line1!') do (
set p1=%%s
set "p1=!p1: =!"
set "dmy1=!p1:~2,2!"
set "dmy2=!p1:~4,2!"
set "dmy2=!dmy2:0=!"
set "dmy3=!p1:~6,2!"
set "lastDigit=!p1:~-1!"
if NOT "!lastDigit!"=="0" set "dmy3=!dmy3:0=!"
set %2=!dmy1!.!dmy2!.!dmy3!
)
)
)
exit /b

How to:
1. Unzip sourcecode to an installdir of your choice
2. In Install.bat: Set parameter at line 88:
D7, D2007, D2010, DXE, DXE2, DXE3, DXE4, DXE5 or DXE6
Default parameter is DXE6:

Code:
CALL :func_install DXE6

3.

Run Install.bat in <installdir> AS ADMIN

Notes:
1. It is possible to install DevExpress VCL to D7-DXE6 at once as follows:
Code:
CALL
CALL
CALL
CALL
CALL
CALL
CALL
CALL
CALL

:func_install
:func_install
:func_install
:func_install
:func_install
:func_install
:func_install
:func_install
:func_install

D7
D2007
D2010
DXE
DXE2
DXE3
DXE4
DXE5
DXE6

2. If TestMode is set ON at line 22


Code:
set "TestMode=ON"

all installation commands are logged to textfile "Log_TestMode.txt"


BUT NO CHANGES are made on your computer.
3. If 64bit-packages should not be compiled simply rename "dcc64.exe" in line 238

UnInstaller for DevExpress VCL (D7-DXE6)


*** See previous post for Installer ! ***
Features UnInstaller:

Cleaning Up installdir

Uninstalling packages from IDE

Cleaning Up BPL and DCP folders

Cleaning Up Search Path and Browsing Path


UnInstall.bat (420 lines)
Code:
@echo off
@color 1F
setlocal enabledelayedexpansion
rem ***********************************************************
rem *
rem * Uninstall DevExpress VCL D7-DXE6

rem
rem
rem
rem
rem
rem
rem
rem

*
* Tasks:
*
1) Cleaning Up installdir
*
2) Uninstalling packages from IDE
*
3) Cleaning Up BPL and DCP folders
*
4) Cleaning Up Search Path and Browsing Path
*
***********************************************************

set starttime=%time%
rem ---------------------------------------------------------rem Administrative permissions required. Detecting permissions
rem ---------------------------------------------------------net session >nul 2>&1
if %errorLevel% == 0 (
rem Success: Administrative permissions confirmed.
) else (
echo ERROR: Administrative permissions required.
echo.
echo INFO: Run batch-file again as ADMIN ...
echo.
pause
goto end
)
%~d0
cd %~p0
rem ----------------------------------------rem BAT file must be executed in <installdir>
rem ----------------------------------------if not exist "%~dp0ExpressQuantumGrid\Sources\cxGrid.pas" (
echo ERROR: Current directory is not installdir
echo.
echo INFO: Run batch-file in installdir ...
echo.
pause
goto end
)
set "cFile=%~dp0ExpressCore Library\Sources\Dxcore.pas
call :GetDXVersion "%cFile%" DXVers
TITLE UnInstalling DevExpress VCL v!DXVers!
set /a major_vers=!DXVers:~0,2!
rem
rem
rem
set
set

-----------------Setting installdir
-----------------"INSTALLDIR=%~dp0"
"INSTALLDIR=%INSTALLDIR:~0,-1%"

rem -----------------rem RUN UNINSTALLATION


rem -----------------call :func_uninstall DXE6
set endtime=%time%
echo Started at: %starttime%
echo Finished at: %endtime%
echo.
pause
:end
exit /b

rem
====================================================================================
=
rem
F U N C T I O N S
rem
====================================================================================
=
:func_uninstall
echo ============================================
echo Uninstalling DevExpress VCL v!DXVers! (%1)
echo ============================================
echo.
CALL :func_HKCU BDSHKCU %1
CALL :func_rootdir ROOTDIR reg QUERY !BDSHKCU! /v RootDir
CALL :func_64Bit Is64BitSupport %1
CALL :func_Suffix SUFFIX %1
CALL :func_BDSCommonDir BDSCOMMONDIR %1
set "BPLDir=!BDSCOMMONDIR!\Bpl"
set "DCPDir=!BDSCOMMONDIR!\Dcp"
set "Edition=%1"
if "!Edition!"=="D7" (
set "DCPDir=!INSTALLDIR!\Lib\D7"
)
set
set
set
set

"RKeySearch32=!BDSHKCU!\Library"
"RKeySearch64="
"LIBSubDir32=!Edition!"
"LIBSubDir64="

if "!Is64BitSupport!"=="YES" (
set "RKeySearch32=!BDSHKCU!\Library\Win32"
set "RKeySearch64=!BDSHKCU!\Library\Win64"
set "LIBSubDir32=!Edition!\Win32"
set "LIBSubDir64=!Edition!\Win64"
)
rem -----------------------rem Cleaning Up <installdir>
rem -----------------------Set "CleanInfo=1. Cleaning Up installdir: Library\!LIBSubDir32!"
if "!Is64BitSupport!"=="YES" Set CleanInfo=!CleanInfo! and Library\!LIBSubDir64!
echo !CleanInfo!
rd "%~dp0Library\%1" /Q /S >nul 2>&1
rem Delete directory Library if empty
for /F %%a in ('dir /S/B "%~dp0Library\*" ^| find /V /C "::"') do (if %%a EQU 0 rd
"%~dp0Library" /Q >nul 2>&1)
rem -----------------------------rem UnInstalling Packages from IDE
rem -----------------------------echo 2. UnInstalling Packages from IDE
call :DelIDE dcldxCore
call :DelIDE dclcxLibrary
call :DelIDE dxSkinBlack
call :DelIDE dxSkinBlueprint
call :DelIDE dxSkinBlue
call :DelIDE dxSkinCaramel
call :DelIDE dxSkinCoffee
call :DelIDE dxSkinDarkRoom
call :DelIDE dxSkinDarkSide
call :DelIDE dxSkinDevExpressDarkStyle
call :DelIDE dxSkinDevExpressStyle
call :DelIDE dxSkinFoggy

call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call

:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE

dxSkinGlassOceans
dxSkinHighContrast
dxSkiniMaginary
dxSkinLilian
dxSkinLiquidSky
dxSkinLondonLiquidSky
dxSkinMcSkin
dxSkinMetropolisDark
dxSkinMetropolis
dxSkinMoneyTwins
dxSkinOffice2007Black
dxSkinOffice2007Blue
dxSkinOffice2007Green
dxSkinOffice2007Pink
dxSkinOffice2007Silver
dxSkinOffice2010Black
dxSkinOffice2010Blue
dxSkinOffice2010Silver
dxSkinOffice2013DarkGray
dxSkinOffice2013LightGray
dxSkinOffice2013White
dxSkinPumpkin
dxSkinSevenClassic
dxSkinSeven
dxSkinSharpPlus
dxSkinSharp
dxSkinSilver
dxSkinSpringTime
dxSkinStardust
dxSkinSummer2008
dxSkinTheAsphaltWorld
dxSkinValentine
dxSkinVS2010
dxSkinWhiteprint
dxSkinXmas2008Blue
dcldxFlowChart
dcldxOrgC
dxSkinscxPCPainter
dxSkinsdxNavBarPainter
dclcxPageControl
dcldxBarExtDBItems
dcldxdbtr
dcldxNavBar
dcldxSkinsCore
dxSkinsdxBarPainter
dclcxPageControldxBarPopupMenu
dcldxBar
dcldxDBOr
dcldxDocking
dcldxMapControl
dcldxSkinsDesignHelper
dxSkinsdxDLPainter
dxSkinsdxRibbonPainter
dclcxEditors
dcldxBarExtItems
dcldxIconLibrary
dcldxRibbon
dcldxSpellChecker
dcldxSpreadSheet
dcldxTabbedMDI
dcldxTileControl
dcldxPSCore
dcldxSkinscxEditorsHelper
dcldxSkinscxPCPainter
dcldxSkinsdxNavBarPainter
dclcxBarEditItem
dcldxLayoutControl

call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call
call

:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE
:DelIDE

dcldxPSLnks
dcldxPSTeeChart
dcldxPScxCommon
dcldxPSdxLCLnk
dcldxPSdxOCLnk
dcldxPScxExtCommon
dcldxPSDBTeeChart
dcldxPSdxDBTVLnk
dcldxPSdxFCLnk
dcldxPSdxSpreadSheetLnk
dcldxSkinsdxBarsPainters
dcldxPSdxDBOCLnk
dcldxPSPrVwAdv
dcldxSkinsdxRibbonPainters
dcldxPSPrVwRibbon
dcldxGaugeControl
dcldxmds
dcldxWizardControl
dcldxtrmd
dcldxServerMode
dcldxBarDBNav
dclcxEditorFieldLink
dxSkinscxSchedulerPainter
dclcxScheduler
dclcxVerticalGrid
dclcxPivotGrid
dclcxTreeListdxBarPopupMenu
dclcxTreeList
dclcxPivotGridOLAP
dcldxSkinscxSchedulerPainter
dclcxGrid
dclcxSchedulerGrid
dclcxSchedulerTreeBrowser
dclcxPivotGridChart
dclcxSchedulerRibbonStyleEventEditor
dcldxPScxSchedulerLnk
dcldxPScxTLLnk
dcldxPScxVGridLnk
dclcxGridWizard
dcldxPScxGridLnk
dcldxPScxPivotGridLnk
dcldxADOServerMode
dcldxDBXServerMode
dcldxFireDACServerMode
dcldxRibbonCustomizationForm
dcldxPScxSSLnk
dclcxSpreadSheet

rem ------------------------------rem Cleaning Up BPL and DCP folders


rem ------------------------------echo 3. Cleaning Up BPL and DCP folders
call :func_deletefiles "!BPLDir!"
call :func_deletefiles "!DCPDir!"
rem ------------------------------------------------------------rem Cleaning Up Library Paths (Search Path and Browsing Path)
rem ------------------------------------------------------------echo 4. Cleaning Up Library Paths
set "RegKey1=!RKeySearch32!"
set "RegKey2=!RKeySearch64!"
set /a nCount = 2
if "!Is64BitSupport!"=="NO" set /a nCount = 1
if not exist "!ROOTDIR!\Bin\dcc64.exe" set /a nCount = 1
set "LibPath1=Search Path"
set "LibPath2=Browsing Path"

for /L %%1 IN (1,1,!nCount!) do (


for /L %%2 IN (1,1,2) do (
set "currRegKey=!RegKey%%1!"
set "currLibPath=!LibPath%%2!"
set "newpath="
set dmy=reg QUERY !currRegKey! /v "!currLibPath!"
echo
...!currRegKey!: "!currLibPath!"
CALL :update_path !dmy!
)
)
echo.
echo DevExpress VCL v!DXVers! (%1) uninstalled ...
echo.
echo.
goto:EOF
rem
==================================================================================
:DelIDE
REG DELETE "!BDSHKCU!\Known Packages" /v "!BPLDir!\%1!SUFFIX!.bpl"
/f >nul 2>&1
GOTO :EOF
rem
====================================================================================
=
:update_path
set hlp=%1 %2 %3 %4 %5
for /f "tokens=* skip=2" %%a in ('!hlp!') do (
for /f "tokens=1,2,3,4* delims= " %%k in ('echo %%a') do (
if NOT "%%o"=="" (
set "olddata25=%%n %%o") ELSE (
set "olddata25=%%n"
)
)
set "_myvar=!olddata25!"
set newpath=
:FORLOOP
for /F "tokens=1* delims=;" %%A IN ("!_myvar!") do (
set "part=%%A"
set "dmy=!part:%INSTALLDIR%=!"
if !dmy!==!part! set "newpath=!newpath!!part!;"
set "_myvar=%%B"
if NOT "!_myvar!"=="" goto :FORLOOP
)
set "lastChar=!newpath:~-1!"
if "!lastChar!"==";" set newpath=!newpath:~0,-1!
rem echo NEWPATH=!newpath!
if NOT "!newpath!"=="" reg ADD !currRegKey! /v "!currLibPath!"
newpath!" /f >nul 2>&1
)
GOTO:EOF

/d "!

rem
==================================================================================
:func_rootdir
set hlp=%2 %3 %4 %5 %6
for /f "tokens=* skip=2" %%a in ('!hlp!') do (
set "dmy=%%a"
set "dmy=!dmy:~21!
set "lastChar=!dmy:~-1!"
if "!lastChar!"=="\" set "dmy=!dmy:~0,-1!"
set "%1=!dmy!"
)

GOTO :EOF
rem
==================================================================================
:func_BDSCommonDir
if "%2"=="D7" (
CALL :func_HKCU RK1 D7
CALL :func_rootdir RDIR7 reg QUERY !RK1! /v RootDir
)
set "RS1=%RDIR7%\Projects"
set "RS2=%PUBLIC%\Documents\RAD Studio"
set "RS3=%PUBLIC%\Documents\Embarcadero\Studio"
set "NS=D7-%RS1%;D2007-%RS2%\5.0;D2010-%RS2%\7.0;DXE-%RS2%\8.0;DXE2-%RS2%\9.0;DXE3%RS2%\10.0;DXE4-%RS2%\11.0;DXE5-%RS2%\12.0;DXE6-%RS3%\14.0"
set v=%2
CALL SET v=%%NS:*%v%-=%%
SET v=%v:;=&rem.%
set %1=%v%
GOTO :EOF
rem
==================================================================================
:func_HKCU
set "RS1=HKCU\Software\Borland"
set "RS2=HKCU\Software\CodeGear"
set "RS3=HKCU\Software\Embarcadero\BDS"
set "NS=D7-%RS1%\Delphi\7.0;D2007-%RS1%\BDS\5.0;D2010-%RS2%\BDS\7.0;DXE%RS3%\8.0;DXE2-%RS3%\9.0;DXE3-%RS3%\10.0;DXE4-%RS3%\11.0;DXE5-%RS3%\12.0;DXE6%RS3%\14.0"
set v=%2
CALL SET v=%%NS:*%v%-=%%
SET v=%v:;=&rem.%
set %1=%v%
GOTO :EOF
rem
==================================================================================
:func_64Bit
set "NS=D7-NO;D2007-NO;D2010-NO;DXE-NO;DXE2-YES;DXE3-YES;DXE4-YES;DXE5-YES;DXE6-YES"
set v=%2
CALL SET v=%%NS:*%v%-=%%
SET v=%v:;=&rem.%
set %1=%v%
GOTO :EOF
rem
==================================================================================
:func_Suffix
set "NS=D7-D7;D2007-RS11;D2010-RS14;DXE-RS15;DXE2-RS16;DXE3-RS17;DXE4-RS18;DXE5RS19;DXE6-RS20"
set v=%2
CALL SET v=%%NS:*%v%-=%%
SET v=%v:;=&rem.%
set %1=%v%
GOTO :EOF
rem
==================================================================================
:func_deletefiles
set "fldr=%1"
set "fldr=!fldr:"=!"
for /f "eol=r tokens=*" %%a in ('dir *. /b') do (
dir "%~dp0%%a\Packages\*!SUFFIX!.dpk" /b 1>NUL 2>NUL
if NOT errorlevel 1 (
for /f "eol=r tokens=*" %%m in ('dir "%~dp0%%a\Packages\*!SUFFIX!.dpk" /b')
do (

rem
set
set
del

echo %%m
"dmy=%%m"
"currFiles=!dmy:.dpk=*.*!"
"!fldr!\!currFiles!" /S /Q >nul 2>&1

)
)
)
GOTO :EOF
rem
==================================================================================
:GetDXVersion
rem dxBuildNumber: Cardinal = 20130205;
for /f "tokens=* delims=" %%a in (%~s1) do (
set "line1=%%a"
set "line2=!line1!"
set "line2=!line2:dxBuildNumber:=!"
if NOT "!line1!"=="!line2!" (
for /f "tokens=1,2,3 delims==;" %%r in ('echo !line1!') do (
set p1=%%s
set "p1=!p1: =!"
set "dmy1=!p1:~2,2!"
set "dmy2=!p1:~4,2!"
set "dmy2=!dmy2:0=!"
set "dmy3=!p1:~6,2!"
set "lastDigit=!p1:~-1!"
if NOT "!lastDigit!"=="0" set "dmy3=!dmy3:0=!"
set %2=!dmy1!.!dmy2!.!dmy3!
)
)
)
exit /b

How to:
1. Set UnInstall parameter in line 66:
D7, D2007, D2010, DXE, DXE2, DXE3, DXE4, DXE5 or DXE6
Default parameter is DXE6:
Code:
CALL :func_uninstall DXE6

2.

Run UnInstall.bat in <installdir> AS ADMIN

Note:
It is possible to uninstall DevExparess VCL from D7-DXE6 at once as follows:
Code:
CALL
CALL
CALL
CALL
CALL
CALL
CALL
CALL
CALL

:func_uninstall
:func_uninstall
:func_uninstall
:func_uninstall
:func_uninstall
:func_uninstall
:func_uninstall
:func_uninstall
:func_uninstall

D7
D2007
D2010
DXE
DXE2
DXE3
DXE4
DXE5
DXE6

CleanUp Tool for DevExpress VCL Packages (D7-DXE6)


Features:

Removing all packages from previous DevExpress installations from all IDEs
(D7-DXE6)

Deleting according BPL-files


DXCleanUp.bat (100 lines)
Code:
@echo off
@color 1F
setlocal enabledelayedexpansion
rem **************************************************************************
rem *
rem * CleanUp Tool for DevExpress VCL Packages (D7-DXE6)
rem *
rem * Tasks:
rem *
1) Removing all packages from previous DevExpress installations from
rem *
all IDEs at once (D7-DXE6)
rem *
2) Deleting according BPL-files
rem *
rem ***************************************************************************
rem ---------------------------------------------------------rem Administrative permissions required. Detecting permissions
rem ---------------------------------------------------------net session >nul 2>&1
if %errorLevel% == 0 (
rem Success: Administrative permissions confirmed.
) else (
echo ERROR: Administrative permissions required.
echo.
echo INFO: Run batch-file again as ADMIN ...
echo.
pause
exit
)
set "Edition1=D7
"
set "Edition2=D2007"
set "Edition3=D2009"
set "Edition4=D2010"
set "Edition5=DXE "
set "Edition6=DXE2 "
set "Edition7=DXE3 "
set "Edition8=DXE4 "
set "Edition9=DXE5 "
set "Edition10=DXE6 "

&
&
&
&
&
&
&
&
&
&

set
set
set
set
set
set
set
set
set
set

"RegKey1=HKCU\Software\Borland\Delphi\7.0"
"RegKey2=HKCU\Software\Borland\BDS\5.0"
"RegKey3=HKCU\Software\CodeGear\BDS\6.0"
"RegKey4=HKCU\Software\CodeGear\BDS\7.0"
"RegKey5=HKCU\Software\Embarcadero\BDS\8.0"
"RegKey6=HKCU\Software\Embarcadero\BDS\9.0"
"RegKey7=HKCU\Software\Embarcadero\BDS\10.0"
"RegKey8=HKCU\Software\Embarcadero\BDS\11.0"
"RegKey9=HKCU\Software\Embarcadero\BDS\12.0"
"RegKey10=HKCU\Software\Embarcadero\BDS\14.0"

set /a nSum = 0
echo ====================================================================
echo Removing DevExpress VCL Packages from all IDEs (D7-DXE6) at once and
echo Deleting according BPL-files
echo ====================================================================
set starttime=%time%
for /L %%1 IN (1,1,10) do (
set /a nCount = 0
Set "IsInstalled=NO"
reg QUERY "!RegKey%%1!" /ve 1>NUL 2>NUL
if NOT errorlevel 1 (

Set "IsInstalled=YES"
for /f "tokens=* skip=2" %%a in ('reg QUERY "!RegKey%%1!\Known Packages" /s')
do (
call :CheckDXEntry "%%a" BPLFile
if NOT "!BPLFile!"=="" (
REG DELETE "!RegKey%%1!\Known Packages" /v "!BPLFile!"
/f
del "!BPLFile!*"
/Q >nul 2>&1
rem echo !RegKey%%1!\Known Packages\!BPLFile! deleted ...
set /a nCount = !nCount! + 1
)

>nul 2>&1

)
)
if "!IsInstalled!"=="YES" (
if !nCount! GEQ 1 (echo !Edition%%1!: !nCount! packages removed) ELSE
(echo !Edition%%1!: No package removed)
) ELSE (
echo !Edition%%1!: not installed !
)
set /a nSum = !nSum! + !nCount!
)
set endtime=%time%
echo.
echo Total sum of removed packages (D7-DXE6): !nSum!
echo.
echo Started at: %starttime%
echo Finished at: %endtime%
echo.
pause
exit
:CheckDXEntry
SET line=%1
set "line=!line:"=!"
SET divider=REG_SZ
CALL SET after=%%line:*%divider%=%%
CALL SET before=%%line:%divider%%after%=%%
set "dmy=!after!"
set "dmy=!dmy:Developer Express=!"
if NOT "!dmy!"=="!after!" (
for /l %%a in (1,1,20) do (
if "!before:~-1!"==" " set before=!before:~0,-1!
)
set %2=!before!
) ELSE (set %2=)
exit /b

How to:
Run DXCleanUp.bat in a directory of your choice

Help Installer for all versions of DevExpress VCL (D2007-DXE6)


Install_Help.bat: (210 lines)
Code:
@echo off
@color 1F
setlocal enabledelayedexpansion
%~d0
cd %~p0

rem
rem
rem
rem
rem

*****************************************************************
*
* HELP Installer for all versions of DevExpress VCL (D2007-DXE6)
*
*****************************************************************

set starttime=%time%
rem ---------------------------------------------------------rem Administrative permissions required. Detecting permissions
rem ---------------------------------------------------------net session >nul 2>&1
if %errorLevel% == 0 (
rem Success: Administrative permissions confirmed.
) else (
echo ERROR: Administrative permissions required.
echo.
echo INFO: Run batch-file again as ADMIN ...
echo.
pause
exit
)
rem ----------------------------------------rem BAT file must be executed in <installdir>
rem ----------------------------------------if not exist "%~dp0ExpressQuantumGrid\Help\ExpressQuantumGrid.HxS" (
echo ERROR: Current directory is not installdir
echo.
echo INFO: Run batch-file in installdir ...
echo.
pause
exit
)
if not exist "%~dp0H2Reg.exe" (
echo ERROR: H2Reg.exe not found in installdir
echo.
echo INFO: Copy H2Reg.exe to installdir ...
echo.
pause
exit
)
if not exist "%~dp0H2Reg.ini" (
echo ERROR: H2Reg.ini not found in installdir
echo.
echo INFO: Copy H2Reg.ini to installdir ...
echo.
pause
exit
)
call :GetDXVersion "%~dp0ExpressCore Library\Sources\Dxcore.pas" DXVers
TITLE Installing HELP for DevExpress VCL v!DXVers!
echo ===========================================================================
echo Installing Help for DevExpress VCL v!DXVers!
echo ===========================================================================
call :progress 0
rem ---------------rem RUN INSTALLATION
rem ----------------

CALL :func_install DXE6


set endtime=%time%
echo Started at: %starttime%
echo Finished at: %endtime%
echo.
pause
:end
exit
rem
==================================================================================
rem
F U N C T I O N S
rem
==================================================================================
:func_install
set p1=%1_
set "str=D2007_D2009_D2010_DXE_DXE2_DXE3_DXE4_DXE5_DXE6_"
if "x!str:%p1%=!"=="x%str%" (
echo.
echo ERROR: %1 not supported
echo.
Choose D2007, D2009, D2010, DXE, DXE2, DXE3, DXE4, DXE5 or DXE6
echo.
echo INFO: BAT file will be terminated now ...
echo.
pause
exit
)
rem --------------rem Installing HELP
rem --------------echo - Installing Help for %1
echo
(ProgressBar is displayed in TitleBar of Console Window)
echo.
set /a nCount=0
set /a nProgress=0
set H2REG="%~dp0h2reg"
call :Namespace NS %1
set IDE_NS=%NS%
call :Namespace NS %1 POST
set IDE_NS_Post=%NS%
echo
Namespace=%IDE_NS%
echo
Namespace_PostFix=%IDE_NS_Post%
echo.
if exist H2Reg_Log.txt del H2Reg_Log.txt

>nul 2>&1

for /f "eol=r tokens=*" %%a in ('dir *. /b') do (


rem echo %%a
if exist "%~dp0%%a\Help" (
for /f "eol=r tokens=*" %%k in ('dir "%~dp0%%a\Help\*.ini" /b') do (
rem echo %%k
Call :InstHelp "%~dp0%%a\Help\%%k"
set /a nCount = !nCount! + 1
set /a nProgress = !nCount!*4
if NOT "!nProgress!"=="100" call :progress !nProgress!
)
)
)

:Finish
call :progress 100
echo.
echo.
echo Help for DevExpress VCL (%1) installed ...
echo.
goto:EOF
rem
==================================================================================
:progress
SETLOCAL ENABLEDELAYEDEXPANSION
SET ProgressPercent=%1
rem if NOT "%ProgressPercent%"=="0" (
SET /A NumBars=%ProgressPercent%/2
SET /A NumSpaces=50-%NumBars%
SET Meter=
FOR /L %%A IN (%NumBars%,-1,1) DO SET Meter=!Meter!I
FOR /L %%A IN (%NumSpaces%,-1,1) DO SET Meter=!Meter!
TITLE Progress: [%Meter%] %ProgressPercent%%%
rem )
ENDLOCAL
GOTO :EOF
rem
==================================================================================
:InstHelp
set INIFILE=%1
echo
... %~n1%~x1
set INIFILE=!INIFILE:~0,-2!_"
del !INIFILE! 1>nul 2>nul
for /F "usebackq tokens=*" %%a in (%1) do (
set Line=%%a
set Line=!Line:%%=!
set Line=!Line:IDE_Namespace_Postfix=%IDE_NS_Post%!
set Line=!Line:IDE_Namespace=%IDE_NS%!
echo !Line!>>%INIFILE%
)
%H2REG%.exe -r -q CmdFile=!INIFILE! 1>nul 2>nul
del !INIFILE! 1>nul 2>nul
exit /b
:Namespace
set "NS=D2007-borland;D2009-embarcadero;D2010-embarcadero;DXE-embarcadero;DXE2embarcadero;DXE3-embarcadero;DXE4-embarcadero;DXE5-embarcadero;DXE6-embarcadero"
if "%3"=="POST" set "NS=D2007-bds5;D2009-rs2009;D2010-rs2010;DXE-rs_xe;DXE2rs_xe2;DXE3-rs_xe3;DXE4-rs_xe4;DXE5-rs_xe5;DXE6-rs_xe6"
set v=%2
rem echo %v%
CALL SET v=%%NS:*%v%-=%%
SET v=%v:;=&rem.%
set %1=%v%
GOTO :EOF
rem
==================================================================================
:GetDXVersion
rem dxBuildNumber: Cardinal = 20130205;
for /f "tokens=* delims=" %%a in (%~s1) do (
set "line1=%%a"
set "line2=!line1!"
set "line2=!line2:dxBuildNumber:=!"
if NOT "!line1!"=="!line2!" (
for /f "tokens=1,2,3 delims==;" %%r in ('echo !line1!') do (
set p1=%%s

set "p1=!p1: =!"


set "dmy1=!p1:~2,2!"
set "dmy2=!p1:~4,2!"
set "dmy2=!dmy2:0=!"
set "dmy3=!p1:~6,2!"
set "lastDigit=!p1:~-1!"
if NOT "!lastDigit!"=="0" set "dmy3=!dmy3:0=!"
set %2=!dmy1!.!dmy2!.!dmy3!
)
)
)
exit /b

UnInstall_Help.bat: (210 lines)


Code:
@echo off
@color 1F
setlocal enabledelayedexpansion
%~d0
cd %~p0
rem
rem
rem
rem
rem

******************************************************************
*
* HELP UnInstaller for all versions of DevExpress VCL (D2007-DXE6)
*
******************************************************************

set starttime=%time%
rem ---------------------------------------------------------rem Administrative permissions required. Detecting permissions
rem ---------------------------------------------------------net session >nul 2>&1
if %errorLevel% == 0 (
rem Success: Administrative permissions confirmed.
) else (
echo ERROR: Administrative permissions required.
echo.
echo INFO: Run batch-file again as ADMIN ...
echo.
pause
goto end
)
rem ----------------------------------------rem BAT file must be executed in <installdir>
rem ----------------------------------------if not exist "%~dp0ExpressQuantumGrid\Help\ExpressQuantumGrid.HxS" (
echo ERROR: Current directory is not installdir
echo.
echo INFO: Run batch-file in installdir ...
echo.
pause
exit
)
if not exist "%~dp0H2Reg.exe" (
echo ERROR: H2Reg.exe not found in installdir
echo.
echo INFO: Copy H2Reg.exe to installdir ...
echo.
pause

exit
)
if not exist "%~dp0H2Reg.ini" (
echo ERROR: H2Reg.ini not found in installdir
echo.
echo INFO: Copy H2Reg.ini to installdir ...
echo.
pause
exit
)
call :GetDXVersion "%~dp0ExpressCore Library\Sources\Dxcore.pas" DXVers
TITLE UnInstalling HELP DevExpress VCL v!DXVers!
echo ===========================================================================
echo UnInstalling Help for DevExpress VCL v!DXVers!
echo ===========================================================================
call :progress 0
rem ------------rem RUN UNINSTALL
rem ------------CALL :func_uninstall DXE6
set endtime=%time%
echo Started at: %starttime%
echo Finished at: %endtime%
echo.
pause
:end
exit
rem
==================================================================================
rem
F U N C T I O N S
rem
==================================================================================
:func_uninstall
set p1=%1_
set "str=D2007_D2009_D2010_DXE_DXE2_DXE3_DXE4_DXE5_DXE6_"
if "x!str:%p1%=!"=="x%str%" (
echo.
echo ERROR: %1 not supported
echo.
Choose D2007, D2009, D2010, DXE, DXE2, DXE3, DXE4, DXE5 or DXE6
echo.
echo INFO: BAT file will be terminated now ...
echo.
pause
exit
)
rem ----------------rem UnInstalling HELP
rem ----------------echo - UnInstalling Help for %1
echo
(ProgressBar is displayed in TitleBar of Console Window)
echo.
set /a nCount=0
set /a nProgress=0
set H2REG="%~dp0h2reg"
call :Namespace NS %1
set IDE_NS=%NS%

call :Namespace NS %1 POST


set IDE_NS_Post=%NS%
echo
echo
echo.

Namespace=%IDE_NS%
Namespace_PostFix=%IDE_NS_Post%

if exist H2Reg_Log.txt del H2Reg_Log.txt

>nul 2>&1

for /f "eol=r tokens=*" %%a in ('dir *. /b') do (


rem echo %%a
if exist "%~dp0%%a\Help" (
for /f "eol=r tokens=*" %%k in ('dir "%~dp0%%a\Help\*.ini" /b') do (
rem echo %%k
Call :UnInstHelp "%~dp0%%a\Help\%%k"
set /a nCount = !nCount! + 1
set /a nProgress = !nCount!*4
if NOT "!nProgress!"=="100" call :progress !nProgress!
)
)
)
:Finish
call :progress 100
echo.
echo.
echo Help for DevExpress VCL (%1) uninstalled ...
echo.
goto:EOF
rem
==================================================================================
:progress
SETLOCAL ENABLEDELAYEDEXPANSION
SET ProgressPercent=%1
rem if NOT "%ProgressPercent%"=="0" (
SET /A NumBars=%ProgressPercent%/2
SET /A NumSpaces=50-%NumBars%
SET Meter=
FOR /L %%A IN (%NumBars%,-1,1) DO SET Meter=!Meter!I
FOR /L %%A IN (%NumSpaces%,-1,1) DO SET Meter=!Meter!
TITLE Progress: [%Meter%] %ProgressPercent%%%
rem )
ENDLOCAL
GOTO :EOF
rem
==================================================================================
:UnInstHelp
set INIFILE=%1
echo
... %~n1%~x1
set INIFILE=!INIFILE:~0,-2!_"
del !INIFILE! 1>nul 2>nul
for /F "usebackq tokens=*" %%a in (%1) do (
set Line=%%a
set Line=!Line:%%=!
set Line=!Line:IDE_Namespace_Postfix=%IDE_NS_Post%!
set Line=!Line:IDE_Namespace=%IDE_NS%!
echo !Line!>>%INIFILE%
)
%H2REG%.exe -u -q CmdFile=!INIFILE! 1>nul 2>nul
del !INIFILE! 1>nul 2>nul
exit /b

:Namespace
set "NS=D2007-borland;D2009-embarcadero;D2010-embarcadero;DXE-embarcadero;DXE2embarcadero;DXE3-embarcadero;DXE4-embarcadero;DXE5-embarcadero;DXE6-embarcadero"
if "%3"=="POST" set "NS=D2007-bds5;D2009-rs2009;D2010-rs2010;DXE-rs_xe;DXE2rs_xe2;DXE3-rs_xe3;DXE4-rs_xe4;DXE5-rs_xe5;DXE6-rs_xe6"
set v=%2
rem echo %v%
CALL SET v=%%NS:*%v%-=%%
SET v=%v:;=&rem.%
set %1=%v%
GOTO :EOF
rem
==================================================================================
:GetDXVersion
rem dxBuildNumber: Cardinal = 20130205;
for /f "tokens=* delims=" %%a in (%~s1) do (
set "line1=%%a"
set "line2=!line1!"
set "line2=!line2:dxBuildNumber:=!"
if NOT "!line1!"=="!line2!" (
for /f "tokens=1,2,3 delims==;" %%r in ('echo !line1!') do (
set p1=%%s
set "p1=!p1: =!"
set "dmy1=!p1:~2,2!"
set "dmy2=!p1:~4,2!"
set "dmy2=!dmy2:0=!"
set "dmy3=!p1:~6,2!"
set "lastDigit=!p1:~-1!"
if NOT "!lastDigit!"=="0" set "dmy3=!dmy3:0=!"
set %2=!dmy1!.!dmy2!.!dmy3!
)
)
)
exit /b

How to:
1.

Copy H2Reg.exe and H2Reg.ini to DX-installdir


H2Reg can be downloaded from here:
Code:
http://helpware.net/downloads/h2reg_setup2010.exe

2.

Run Install_Help.bat AS ADMIN in DX-installdir


(ProgressBar will be displayed in TitelBar of ConsoleWindow)
By default help files for DXE6 are installed:
Code:
CALL :func_install DXE6

To install help files for another Delphi version change the paramter "DXE6" to
DXE5, DXE4, DXE3, DXE2, DXE, D2010, D2009 or D2007 at line 72.
It is possible to install Help files for multiple Delphi versions at once (e.g:
DXE6 and DXE5) as follows:
Code:

CALL :func_install DXE5


CALL :func_install DXE6

Note:
To uninstall help files, run UnInstall_Help.bat AS ADMIN in DX-installdir.
By default help files for DXE6 are uninstalled:
Code:
CALL :func_uninstall DXE6

Change parameter to your Delphi version at line 71 !