I want to write some journals that automate the export of solid models. Parasolids are the preferred type we would like to automate. Is this possible? I don't see a parasolid export as an option for NX5 or NX6. We will be upgrading to NX7.5 mid-summer.
Exporting a Parasolid is NOT 'journalable' in NX 5.0 or NX 6.0, or for that matter in NX 7.5. Therefore you will need to use NX Open as an alternative and create a custom program to do that.
John R. Baker, P.E.
Product 'Evangelist'
Product Design Solutions
Siemens PLM Software Inc.
Industry Sector
Cypress, CA
You can however automate Iges and I belive you could also automate step using the same methodology that I've seen as these have exe files that you can fire up from a journal.
Not your ideal but a possible solution.
When I said that Exporting a Parasolid was NOT 'journalable' what I meant was that you could NOT record a Journal file which would export a Parasolid since the Export -> Parasolid dialog is not suitable for Journalizing. Granted, one could manually WRITE a journal but that would require at least some programming experience.
Now if you were able to find an existing manually written Journal which does the job great...
John R. Baker, P.E.
Product 'Evangelist'
Product Design Solutions
Siemens PLM Software Inc.
Industry Sector
Cypress, CA
Attached is a VB file to run as a journal for writing out parasolid parts. It asumes you have an assembly then for each component all solid bodies are collected and the component name is changed for wiriting out the parasolid file. This may not be quite what you want. It does show that it is easily done. Let me know if you want it to de different.
Thank you all for your help. I do have limited experience with .vb programming and have customized journals in the past.
@FrankSwinks
I'm not sure if this journal is working. It doesn't give me any errors, however, I'm not being prompted as to where to save the file and I can not locate where its being saved.
In a perfect world, I'd like the journal to be able to export all solid bodies displayed in modeling (not blanked or turned off in layers) whether it be a single component or an assmebly. Then if possible, I'd like to downgrade the parasolid version to NX1.0 and prompt where to save it.
The first journal only worked for assemblies. The next journal now tests if the part is a component or piece part. That is the attached journal will now work for either piece part or assembly.
For either we now use parasolid version 14.0 which is suitable for NX1.
For the piece part I disregard blanked solids and if the solid is on a hidden layer.
I don't prompt for a directory. The parasolid file is placed in the path of the partfile. I rename the part file by replacing ".prt" with for example "_bodies_5_xt.x_t". Here 5 is the number of bodies in the file. You will need to let me know how much of the file name you wish to enter or do you want a windows dialog.
Finally let me see if I have it right for an assembly. Do you want only one parasolid file which includes displayed solids in components that are not suppressed or blanked?
@FrankSwinks
Thanks for your help! The parasolid export does work both with single components as well as assemblies. That is exactly what I needed. However, we have all our cad files in Teamcenter, therefore, it cannot export the parasolid to the same directory. I need to be able to put it in a hard location (i.e. C:/Parasolids). As far as the naming goes, I was thinking of doing something like the following:
Dim strPartNumber as string
Dim strCurrentDate as string
I'm new to NX and to this forum so please excuse me. I am trying to export displayed data as parasolid and came across your code. When I tried to run the journal I got a Journal Execution Error stating "No main found."
The journal (ExportParaSolid.vb) uses a naming convention for the parasolid file which is an attribute name (DB_PART_NO). The attribute value together whith a current date is used for the file name. If the attribute does not exist then no parasolid file is created.
Let me know if you want to use some other form of file naming.