×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

Automating Exporting data (.prt files) from Teamcenter

Automating Exporting data (.prt files) from Teamcenter

Automating Exporting data (.prt files) from Teamcenter

(OP)
Hi, Currently we open the Teamcenter and open the part file and use file > export from teamcenter operation to export the data from the teamcenter. It typically takes 25 minutes to complete the process.(for 5 MB data)

I was wondering whether we could automate this process( Using Journal or Macros) and reduce the process time. We use NX 7.5 and Teamcenter 8.

Any help with this is appreciated.
Thanks in Advance.

RE: Automating Exporting data (.prt files) from Teamcenter

Vpmodi,

There are two command line utilities (scripts) to perform the export operation.

"%UGII_BASE_DIR%\ugmanager\ugmanager_batch_clone"
and
"%UGII_BASE_DIR%\ugmanager\ugmanager_clone"

Regards,
Joe

CODE --> From the Documentation

Following are examples for the Export operation:

•Export a part:

ugmanager_clone -pim=yes -u=<userid> -p=<password> -g=<group> -o=export -par=@DB/12345/A
-default_n=autotranslate
•Export a part with a drawing:

ugmanager_clone -pim=yes -u=<userid> -p=<password> —g=<group> -o=export -par=@DB/12345/A
-copy_n=<type>:yes -default_n=autotranslate
where <type> is specification or manifestation. If you do not enter a type, the drawing is not exported.

•Export an assembly:

ugmanager_clone -pim=yes -u=<userid> -p=<password> -g=<group> -o=export -asse=@DB/6789/A
-default_n=autotranslate
•Export an assembly with checkout:

ugmanager_clone -pim=yes -u=<userid> -p=<password> -g=<group> -o=export -asse=@DB/6789/A
-default_n=autotranslate -default_checko=yes•Export multiple assemblies:

ugmanager_clone -pim= -o=export -default_dir=c:\temp -default_n=autotranslate
-asse=@DB/widget_assy1/A -asse=@DB/widget_assy2/A
•Export only the assembly UGMASTER and its non-masters:

The solution is a three part process that requires a simple editing procedure to complete.

◦Use the following command to generate the export.clone log file.

ug_clone -pim=yes -u=<userid> -p=<password> -g=<group> -o=export
-asse=@DB/<item_id>/<rev_id> -default_a=exclude -default_n=autotranslate –drIn this process, you can find only the –asse= option used, and the exclude action for the –default_n and the –dr (for dryrun) options added. The log file contains all the children of the assembly.

It is acceptable to have the children of the assembly in the log file, as it is programmed to exclude all the specified items from the export.

◦Open the export.clone log file in an editor, and change the Cloning_Action for the relevant UGMASTER part (in the earlier process, it is the Part: @DB/<item_id>/<rev_id>) from Default_Disp to OVERWRITE.

In the following process, it is programmed that only the UGMASTER and its non_masters are exported.

&LOG Part: @DB/<item_id>/<rev_id>&LOG Cloning_Action: OVERWRITE Naming_Technique: DEFAULT_NAMING◦Rerun the export using the edited export.clone log file as input.

ug_clone -pim=yes -u=<userid> -p=<password> -g=<group> -o=export -l=export.clone

RE: Automating Exporting data (.prt files) from Teamcenter

(OP)
Thanks for the solution.
But I am new to command line scripting. I tried to run the command form CMD window. But I got an error message " the system cannot find the path specified"

can you give me some link where which I can start learning the scripting of NX or any link where which i can start learning automation of the NX.  

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources