Femtet Macro Help/Manual
 

Home / If a Macro Created with an Older Version of Femtet Does Not Work Correctly

If a Macro Created with an Older Version of Femtet Does Not Work Correctly

A modeling kernel (Parasolid) was upgraded in Femtet2018.
The topology ID after the modeling operation may be different before and after Femtet2018.

If an macro, that was created in version 2017 or older, contains commands to specify the topology ID, to move face, or to set the boundary condition,
it may not work correctly in Femtet2018 or later version due to the change of topology ID.


Corrective Procedure

  1. Identify the command that caused the error.
  2. Check the topology ID set in the command that caused the error.
  3. If the topology ID is invalid, correct it.

Example: Failure of Boundary Condition Setting

  1. Identify the command location where an error occurred.

  • Topology ID "999" set in GetFaceBYID() is invalid.
    An error occurs because the boundary condition is set to an non-existent Face0.

  1. Run the macro just before the command that caused an error.

  1. On the modeling window, check the topology ID of the face where you want to set the boundary condition.

  • Confirm the correct topology ID is "2".

  1. Correct the topology ID in the command that caused the error.

  • Set the topology ID in GetFaceBYID() to "2".