- Start Delphi and select Component | Import ActiveX Control...
- Look for an ActiveX control you wish to import (dialog displays the ActiveX controls registered on your system). I will call this control: SomeActiveX
- Select the Component palette location in which you want to place selected library.
- Maybe the best is to leave the ActiveX option selected.
- Click on Install.
- Select a package where the new component must be installed or
- Create a new package for the new TSomeActiveX control.
- Click on OK.
- Delphi will prompt you whether you want to rebuild the modified/new package or not.
- Click on Yes.
- After the package is compiled, Delphi will show you a message saying that the new TSomeActiveX component was registered and already available as part of the VCL.
- Close the package detail window, allowing Delphi to save the changes to it.
- The component is now available in the ActiveX tab (if you didn't change this setting in step 4)
- Drop the component on a form, and simply: use it.
Tips:
- In step 3, selecting the component palette for new TSomeActiveX component allows you to group controls by function or vendor, for example.
- The component wrapper is linked into the application executable file (or a runtime package), but the .OCX file for the component also needs to be deployed with the application.
- ActiveX controls need to be registered on the deployment computer before use. Installation programs such as InstallShield Express automate this registration process.
No comments:
Post a Comment