VBA Script for Exporting CofG

Hello everyone,

I am trying to write a VBA script for V6 to export the CofG co-ordinates of the selected part/product to a text file.

I've found a the below code in the DSYAutomation.chm but it returns 0,0,0 instead of the CofG of the part.


Does anyone have a script to achieve this that they could share?

Thank you