InstallShield registers the OCX control

Source: Internet
Author: User

Because the OCX control is used in development, if no corresponding ocx file exists on the target machine, it will cause the applicationProgramUnable to run normally, I took a detour when registering the OCX control with installshield2009. I first used the INF file and wrote the rundll32 + inf file name in installscript. In this way, the OCX control can be correctly loaded, but the loaded ocx file will be detached during uninstallation. After searching for information, we found that InstallShield provided the automatic registration control function, such as self-loading OCX. The process is as follows:

Step 1: The Project Assistant> Application Files> Windows directory contains three subdirectories: fonts floder, Windows system, and Windows System (64bit ). If the control is installed on a 32-bit operating system machine, you can select Windows system. Here I select the Windows System directory. Click addfiles to add a self-registration file to the Windows System directory, in this way, InstallShield will install the control to the System32 directory of the system disk during installation. If you need to install the control to the subdirectory of the System32 directory of the system disk, you can create subdirectories in the Windows System directory.

Step 2: Choose installation designer-> orgnization-> setupdesign-> default feature. The default feature directory contains the selfregfiles directory. Click selfregfiles. The sefregfiles attribute is displayed on the right. The shared property is true, set the uninstal attribute to false and the Self-register attribute to true, so that your registration control can be successfully registered on the target machine and locked by other programs, it will not be uninstalled during reverse installation.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.