Microsoft KB Archive/244064

= INFO: Upgrade Techniques for Controls and Extenders with the VBA SDK =

Article ID: 244064

Article Last Modified on 11/19/1999

-

APPLIES TO


 * Microsoft Visual Basic for Applications (VBA) Software Development Kit (SDK) 5.0
 * Microsoft Visual Basic for Applications (VBA) Software Development Kit (SDK) 6.0
 * Microsoft Visual Basic for Applications (VBA) Software Development Kit (SDK) 6.1

-



This article was previously published under Q244064



SUMMARY
When a control is added to a VBA-enabled application, Visual Basic for Applications (VBA) creates a copy of its type library in a file with an .exd or a .twd extension. This file is used to merge the type information of the control with that of a host-provided extender object, which helps give the control added functionality while running inside the VBA-enabled application. This article describes the techniques required when either the control or the VBA-enabled application is upgraded.



MORE INFORMATION
When a control that has been added to a VBA-enabled application needs to be upgraded, the .exd and .twd files that VBA created for it must be deleted. VBA determines that the .exd and .twd files are missing, and re-creates them with the new type information of the control. In this fashion, new properties, methods, and interfaces are made available to VBA. If the .exd and .twd files are not deleted when the control is upgraded, VBA remains unaware of any new functionality provided by the control.

When a VBA-enabled application needs to be upgraded, the .exd and .twd files that were created when controls were added must be deleted, just as in the case when the control is upgraded. However, in this case, an extra step is required. In addition to deleting the .exd and .twd files themselves, the registry entries that point to these .exd and .twd files must be deleted. The upgrade program can remove these entries as the files are deleted using the UnRegisterTypeLib API.

Keywords: kbinfo KB244064

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.