To use the Chilkat ActiveX in a Visual Basic 6.0 program, review each of these items to make sure you’re doing everything correctly:
- Make sure you’re using the 32-bit ActiveX, even on 64-bit Windows.
- The ActiveX must be registered (via regsvr32) on each computer. If you’re having trouble, try using the .msi installer available here: Chilkat 32-bit ActiveX MSI Installer
- The ActiveX should be added to the VB6 project by adding a reference. Add a reference from the VB6 menu “Project–>References”. Do NOT “add the component”. Do NOT add the ActiveX via the “Project–>Components…” menu item. You should NOT see anything added to the VB6 palette. The Chilkat objects are non-visual and should always be instantiated dynamically using the New keyword. Do NOT drag-and-drop a Chilkat object onto a form. (This should not be possible if you’ve only added a reference.)
- If the first method call on an object crashes, check to see if the object was created. Check to see if the variable is Nothing prior to calling the method. If there is still a problem, check to see if you can examine the Version property. All Chilkat objects have a Version property. If the access to the Version property crashes, the ActiveX object was never instantiated. It may not be registered correctly, or your program may have never created an instance via the New keyword.
- If you see a .oca file, this is not something provided by Chilkat. It is something VB6 generated. If you recently updated to a new version of the Chilkat ActiveX, delete the old .oca.