Chilkat Software Chilkat Software Chilkat Software
Chilkat Software Chilkat Software

  

  

  

  

  

 

(4) How to Register an ActiveX DLL from a DOS .bat Script

Run the .bat As Administrator to register to a Local Machine Registry.

Run the .bat normally (not As Administrator) to register to a Current User Registry.

  • The regsvr32 command does the registration.
  • Windows provides both 32-bit and 64-bit regsvr32 commands.
  • Use the 32-bit regsvr32 to register to a 32-bit registry.
  • Use the 64-bit regsvr32 to register to a 64-bit registry.

On a 64-bit Windows system, the 64-bit regsvr32 command is simply regsvr32. Here is a sample .bat script to register all DLLs located in the same directory as the .bat script:

@echo off
cd %~dp0
set "filemask=*.dll"
for %%A in (%filemask%) do regsvr32 %%A || GOTO:EOF
ECHO.&PAUSE&GOTO:EOF
	    

On a 64-bit Windows system, the 32-bit regsvr32 command is %systemroot%\syswow64\regsvr32. Here is a sample .bat script to register all DLLs located in the same directory as the .bat script:

@echo off
cd %~dp0
set "filemask=*.dll"
for %%A in (%filemask%) do %systemroot%\syswow64\regsvr32 %%A || GOTO:EOF
ECHO.&PAUSE&GOTO:EOF
	    

ActiveX Registration Tutorial - Page 3

ActiveX Registration Tutorial - Page 5

 


Privacy Statement. Copyright 2000-2021 Chilkat Software, Inc. All rights reserved.

(Regarding the usage of the Android logo) Portions of this page are reproduced from work created and shared by Google and used according to terms described in the Creative Commons 3.0 Attribution License.

Send feedback to support@chilkatsoft.com


Software components and libraries for Linux, MAC OS X, iOS, Android™, Solaris, RHEL/CentOS, FreeBSD, MinGW
Azure, Windows 10, Windows 8, Windows Server 2012, Windows 7, 2003 Server, 2008 Server, etc.