Attached is a program that creates an PLYfile. Because I use some linq commands it cannot be run as a journal. I have included the vb code, the signed dll for NX or NX12 and a dialog file for selecting a body and defining the output file name.
To use ExportPLYFile, simply put PLYExportDialog.dlx into the 'application' subfolder of your customization folder which can be defined by different ways:
Either set the UGII_USER_DIR environment variable to point to the customization folder or add the full directory path of your customization folder to the file specified by UGII_CUSTOM_DIRECTORY_FILE which defaults to $(UGII_BASE_DIR)\ugii\menus\custom_dirs.dat.