When creating statements programmatically through the API, the following sequence should be followed to ensure that the information is consistent.
- Set the Base property.
- Set the Tool property
- Set the ExternalTcp property (using property setter which is equivalent to calling SetExternalTcp with keepWorldPosition == true).
- Set the Target property.
- Set the Configuration property (for joint motion statements only.)
- Call SetJoints to set the individual joint values.