House, design, repair, decor.  Yard and garden.  DIY

House, design, repair, decor. Yard and garden. DIY

» How to register *.dll, *.ocx files. Installing and registering DLLs in Windows How to register a windows 7 x64 dll file

How to register *.dll, *.ocx files. Installing and registering DLLs in Windows How to register a windows 7 x64 dll file

Familiarize yourself with how this method works. To register a DLL file, you can use the "regsvr" command and the name of the DLL file (if the file supports this command). A path will be created from the Windows registry to the DLL file, making it easier for the system to find and use the file.

  • Typically, this method is used to register DLL files that are third-party programs and that interact directly with system utilities (such as the command line).

Understand the essence of the error "entry point" (entry point). If the DLL is already registered, does not support the "regsvr" command, or its code does not allow it to connect to the Windows Registry, you will receive an error "The module was loaded but the entry point DllRegisterServer was not found" (Module [DLL file name] loaded, but the DllRegisterServer entry point was not found). If this message is displayed on the screen, you will not be able to register the DLL file.

  • The "entry point" error is not so much a problem as it is confirmation that the DLL file does not need to be registered.
  • Find the DLL you want to register. Navigate to the folder with the desired DLL file and find it.

    • If the DLL file belongs to an installed program, open the program's folder (for example, C:\Program Files\[program name]).
  • Open the properties of the DLL file. Right-click on the DLL file and select "Properties" from the menu. A pop-up window will open.

    Find the name of the DLL file. In the text box at the top of the Properties window, you'll find the full filename.

    • Most DLL files have complicated names, so leave the Properties window open so you can copy the name later.
  • Copy the path to the DLL file. Hold down the left mouse button and drag your pointer across the text that appears in the "Location" bar, and then press Ctrl + C to copy the path to the DLL file.

    Find the command line. Type command prompt in the start menu search bar. The command prompt icon will appear at the top of the start menu.

    Open command prompt as administrator. For this:

  • Change to the directory with the DLL file. Type cd , press space, press Ctrl + V to paste the path to the DLL file, and then press ↵Enter.

    • For example, if the DLL file is located in the "SysWOW64" folder, which is located in the "Windows" folder, the command would be: cd C:\Windows\SysWOW64
  • Enter the command "regsvr" followed by the name of the DLL file. Type regsvr32 , hit the space bar, type in the name of the DLL file (including the .dll extension) and hit ↵Enter. If the DLL file can be registered, a registration confirmation will appear on the screen.

    • For example, if the DLL file name is "usbperf.dll", the command would be: regsvr32 usbperf.dll
    • To copy the DLL file name, reopen the DLL file folder (Properties window opens), highlight the file name and press Ctrl + C . Then paste the name into the command line by pressing Ctrl + V .
    • If the DLL is already registered or cannot be registered, an "entry point" error will be displayed instead of registration confirmation.
  • Try unregistering the DLL file and then re-registering it. If entering the "regsvr" command results in an error that is not an "entry point" error, unregister the DLL and then reregister it; for this:

    • type regsvr32 /u filename.dll and click ↵Enter. Replace "filename" with the name of your DLL file;
    • Type regsvr32 filename.dll and click ↵Enter. Replace "filename" with the name of your DLL file.
  • Sometimes when you try to start a game or application on your computer, you get an error that this DLL file was not found. The fact is that this file may be on your computer, but it is simply not registered. In this article, we will just talk about how to register a DLL in Windows 7. We will focus on the seventh version of Windows, but it is quite possible that the DLL will be registered on other versions as well. So let's get started.

    The first way to register a DLL

    Before starting registration, it is worth making a remark and saying that there are only three ways, but each of them is almost the same as the others, so we advise you to read the article to the end, and then which method to use. Well, now let's go directly to how to register a DLL.

    Initially, it should be said that all manipulations with registering a DLL file should be carried out only if this same file is where it should be. Most often this is the system32 folder. In the example, we will represent this folder.

    Now let's talk about the most common way to register a DLL, at least it is the most common on the Internet. It is quite simple, so the user should not cause problems.

    1. You need to get to the "Run" window. It can be opened in several ways. In the "Start" menu, go along the path "All Programs → Accessories" and select "Run" there. You can also search with the name of the utility in the same Start menu. But the easiest way is to press the Win + R keys.
    2. When the window is open, in the input field you need to write the command "regsvr32.exe", then specify the path to the file to be registered.
    3. It remains only to press the "OK" button.

    Please note that the path to the file must be specified in full. Starting from drive C. For example: regsvr32.exe c:windows/system32/openal32.dll.

    In this case, after pressing the "OK" button, there are two options for the development of events. The first implies success, in which case you will be shown an appropriate message. Or failure, the corresponding window will fly out.

    This was the first way to register a DLL, but we remind you that there are only three of them, so let's move on.

    The second way to register a DLL

    The second method is practically no different, only the place of action. You need to get into the "Command Line" utility, you can also do this in several ways: either in the "Start" menu in the standard folder, open the program of the same name, or by calling the "Run" window, enter It's up to you to decide.

    Now the command line is open in front of you, in it you need to enter exactly the same data that was entered in the first method. That is, initially specify the program that will work with the dll (regsvr32.exe), and then the path to the file.

    As you can see, the second way, how to register a DLL, is practically no different from the first, which was discussed at the beginning of the article. But the third one has more noticeable differences, so let's move on to it.

    The third way to register a DLL

    This method is likely to be easier for the average user, so let's start considering it.

    All you need to do is open the DLL file with regsvr32.exe. Here's how to do it:

    1. Right-click on the desired DLL file.
    2. Select "Open With..." from the menu.
    3. In the window, find and click the "Browse" button.
    4. Path the path to the regsvr32.exe file, it is located in the System32 folder, which is located in the Windows folder on drive C.
    5. Click "Open".

    That's all, now you know as many as three ways of what to do when a DLL error appears.

    Dll, ActiveX not registered under Windows 7 - what to do?

    In Windows familiar to everyone up to and including XP, registration of Dll, ActiveX components was performed without problems by the regsvr32 command.

    In Windows 7, in principle, the same thing, but some "improvements" have been made, which is why the usual procedure often does not give the expected result. For instance:

    Agree, very clear and informative message. An excellent occasion for an OS developer is to offer the user to purchase and release Windows 8, a new, even more improved version, where this message will possibly be translated into human language.

    Namely: the terminal window (command line, cmd) should be opened with the "Run as administrator" command (accessible by pressing the right mouse button).

    In most cases, it solves the problem.

    Additional steps may be required if a 64bit version of the OS is being used. The fact is that the programs in it can be not only 64-bit but also 32-bit. Moreover, most programs are 32-bit, because 64-bit is useful only for resource-intensive applications.

    In particular, the client part of 1C (that is, the 1C with which the user works) is a 32-bit application. (Here, the 1C server can already be both 32-bit and 64-bit, but this applies to large organizations, if you have 1C Accounting and 5 users, then 99% that you have no 1C server and everything is 32-bit).

    ActiveX components can also be 32-bit or 64-bit, and the version that matches the bit depth of the application must be used. OcvitaBarcode ActiveX is a 32 bit application.

    So, the programs for registering 32-bit and 64-bit ActiveX in Windows 6 64-bit are also different, but they are both called regsvr32.exe. (As Kozma Prutkov said, "if "buffalo" is written on the cage with an elephant, do not believe your eyes.") Therefore, if you simply type in the command line

    regsvr32 some .ocx

    then in theory the necessary regsvr32 should start, in practice anything can start. Why is this done? Well, everything is for the same, if you immediately do it humanly, who will buy the new version of Windows.

    Therefore, to guarantee the launch of 32-bit regsvr32, you should type the command in the terminal window

    c:\windows\syswow64\regsvr32.exe OcvitaBarcode.ocx

    If windows is not installed in c: \ windows, then the path is natural, we indicate which one is. And remember that the terminal window should be opened as an administrator.

    Subject to the above rules, 32-bit ActiveX, incl. OcvitaBarcode ActiveX work without problems in Windows 7:


    Sometimes, however, it is required to register or re-register a DLL. And once again, googling, I realized that I need to add myself. This small, rare, but useful note. Almost everything is taken from the original source, it's hard to come up with a bike of a new design :) when the team's format is straight as a rail.

    And so we went. All that we essentially need to remember is the writing of the utility itself regsvr32. This is the hardest part for me because I don't use it every day. It can be used to register OLE controls such as ActiveX and DLLs in the Windows registry. And then the path and command format.

    On 64-bit versions of Windows, there are two versions of the Regsv32.exe file:
    32-bit version - %systemroot%\\System32\\regsvr32.exe ;
    64-bit version - %systemroot%\\SysWoW64\\regsvr32.exe .

    Regsvr32 Command Syntax

    The RegSvr32.exe program has the following command line options.
    Regsvr32] DLL file

    /u - unregisters the server

    /i - calls DllInstall, passing it an optional command_string as a parameter; when used with the /u switch, calls DllUnInstall.
    /n - does not call DllRegisterServer; this can be used with the /i switch

    /s – "silent" mode; message boxes not showing

    A message appears that the *. dll(For example, VCompLib.dll). In this case, the program, of course, does not start.

    Error messages can be different (this depends mainly on the language in which the program is written), for example: "Component "MSCOMM32.OCX" not correctly registered: file is missing or invalid" , or "The application failed to start because MSVBVM50.DLL was not found. Reinstalling the application may fix this issue", or "Runtime DLL/OCX File error". This may bring up a window Program Compatibility Assistant with a message This program requires a missing Windows component.

    Ways to solve the problem

    If you encounter errors related to *. dll, necessary:

    1. Reinstall the program.

    2. If reinstalling the program does not help, you need to check the presence of the required files in the system.

    Files *. dll, as a rule, should be located in the folder \Windows\System32(less often - in the directory of a specific program). If the files are present, you need to check them in.

    If the required files are not there, search for them on the Internet, download and copy to a folder \Windows\System32 and to the program directory. Now we need to register them.

    How to register *.dll files

    Registering *. dll performed using the registration server regsvr32.exe(whose disk address is \Windows\System32).

    Consider registration methods:

    1. Press the button Start;

    - in the text field Find programs and files enter regsvr32 filename–> Enter .

    2. Press the button Start;

    - in the text field Find programs and files enter cmd;

    - in the list that appears (under the heading Programs) right click cmd.exe;

    – select from the context menu Run as administrator;

    – enter the password if prompted;

    - in the opened window at the system prompt, enter regsvr32 filename , click Enter.

    3. If you use a file manager Total Commander, you can register *. dll using the command line Total Commander.

    If registering *. dll successful, a window will appear RegSvr32 with the corresponding message, for example: "Successful execution of DllRegisterServer in C:\WINDOWS\system32\msvbvm50.dll":


    Notes

    1. When registering *. dll they are recorded in Windows Registry. However, in the thread the corresponding parameter is created REG_DWORD with meaning 1 .

    2. Using the command regsvr32:

    regsvr32 ] dll file

    /u- cancel registration DLL;

    /s– “silent” mode – message windows are not displayed;

    /i- calls DllInstall, passing an optional command_string as a parameter, when used with the /u switch, calls DLLUnInstall;