Mate API not working

HI all,

I have an API which creates an assembly. It opens different parts and put them in the assembly and creates some mates. But once I run it few mates are suppressed after they are created. Any idea how I can fix it ? It is happening to some mates not all, and I am using the same command for all of them.

Thanks in advance

Fariz

SolidworksApi macros