Multiple versions and updates

When you distribute a new version of an object, you can reuse the GUID that was the CLSID for the previous version, or you can assign a new GUID. Your choice should depend on the degree of compatibility between the versions.

Table 20-7: CLSID options

Option for the CLSID

Conditions

Reuse the GUID

The interface for the object is the same and existing applications can access the same properties and functions that were in the old version

Assign a new GUID

The interface has changed and existing applications will fail if they access the new version

If you assign a new GUID so that the old object remains available to existing applications, you need a new ProgID too. If the existing application refers to the version-independent ProgID and you use the same ProgID for the new version, the old application will connect to the new object anyway.

When you design your server object, you need to think about its future development and design current applications accordingly.