Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Catia Macro: Automating Removals

Status
Not open for further replies.

peterbeamish1

Automotive
Aug 16, 2013
13
0
0
CA
Hey,

I am trying to write a macro that will automate the removal of a tool (body) from a plate it sits in(product). It is creating the removal,

This Code is adding the affected component to "Male1", but I need it to go into "Male155227-8#K813 Male Plate"

Set product5 = products1.Item("Male1")
Set assemblyBoolean1 = assemblyFeatures1.AddAssemblyRemove(body1, product4, product5)'
assemblyBoolean1.AddAffectedComponent product5

I believe addAffectedComponent method is the issue. What should I be passing, to apply the remove to a component within the product?

Attached will be my full source and a picture illistrating what SHOULD happen.

This is one of my first CATIA scripts, any guidance is much appreciated.

NOTE: source code may be hard to follow as it contains several features that are only half implemented/ disabled.


Regards,

Peter
 
Status
Not open for further replies.
Back
Top