Manually register or unregister a DLL or OCX file

Use the regsvr32 command to register or unregister a DLL

To register a DLL or OCX file

Method 1:

1. Open a DOS window.

2. Navigate to the DLL’s or OCX’s directory.

3. Enter regsvr32.exe <filename>.<dll/ocx>

Example:

regsvr32.exe mylibrary.dll

Method 2:

1. Go to Start -> Run and enter regsvr32.

2. Open Windows Explorer and find the file.

3. Drag the file from the Windows Explorer window into the Run dialog window. This will enter the full path to the DLL or OCX file.

4. Click <OK>

Example:

regsvr32.exe "c:program filesMercurymylibrary.dll"

To unregister a DLL or OCX file

Method 1:

1. Open a DOS window.

2. Navigate to the DLL’s or the OCX’s directory.

3. Enter regsvr32.exe /u <filename>.<dll/ocx>

Example:

regsvr32.exe /u mylibrary.dll

Method 2:

1. Go to Start -> Run and enter regsvr32 /u.

2. Open Windows Explorer and find the file.

3. Drag the file from the Windows Explorer window into the Run dialog window. This will enter the full path to the DLL or OCX file.

4. Click <OK>

1 thought on “Manually register or unregister a DLL or OCX file”

Leave a Comment