×
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

Assemply Cloning to adhere to a new numbering system

Assemply Cloning to adhere to a new numbering system

Assemply Cloning to adhere to a new numbering system

(OP)
I have a question about naming rule in cloning, I am trying to change the names of all the assemplies and subassemplies and parts to names of a new coding system we are supposed to use,

we have hundreds of parts and I dont want to manually change the name of each part,

example of old-new code conversion

old code 0200 - new code a12-00001-01
old code 0201 - new code a12-00002-01
old code 0202 - new code a12-00003-01

in the nx naming rule, there is only add prefix or add suffix, ,replace and renmae, the suffix and prefix is sufficient for adding a12- before text and -01 after text but not changing the number itself

as you can see its arranged 00001,00002,00003,00004,.... so I think I dont need to change every part manually but a way to recognize this pattern and apply it

plz can someone help me with this?

RE: Assemply Cloning to adhere to a new numbering system

I think a journal/program is the way to go.

It is not easy to give a clear picture but here goes.

Initially you need to set up to do cloning.  This would include:

ufs.Clone.Terminate()
ufs.Clone.Initialise(UFClone.OperationClass.CloneOperation)
ufs.Clone.SetDefDirectory(assemblydir)
ufs.Clone.SetDefAction(UFClone.Action.Clone)
ufs.Clone.SetFamilyTreatment(UFClone.FamilyTreatment.TreatAsLost)
Dim naming_failures As UFClone.NamingFailures = Nothing
ufs.Clone.InitNamingFailures(naming_failures)
response1 = ufs.Clone.AddAssembly(assembly1, loadStatus2)
ufs.Clone.SetDefNaming(UFClone.NamingTechnique.UserName)

Having collected all the parts that belong to the assembly you need to set the naming using something like:

ufs.Clone.SetNaming(part_array(i).FullPath, UFClone.NamingTechnique.UserName, outputPartName)


The part_array contains the parts. The outputPartName contains the cloned name

After the naming changes are all done then call

 ufs.Clone.PerformClone(naming_failures)

Hope this is of some help to get you started.

Frank Swinkels

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