CATIA V6 VBA Selection

Print Friendly, PDF & Email

CATIA V6 VBA Selection

In this post were going to look at a couple of ways in which we can add selection capability’s to our VBA script, so that the user can select objects from the specification tree.

Deprecated

When working with API’s, there are occasions when a published API is rewritten completely which changes its behavior and or signature. When this happens the developers have to mark the old API as Deprecated and create a new version. We can see this in the documentation in a few places specifically the Selection object. The Count API has two version Count and Count2, when we see this we must use the newer API and in old scripts replace the old method with the new one.

Deprecated API

Selection Object

When we look at the object model map, we can see that the Selection object is a child of the Editor object.

Selection Object