Placing objects in space Vector and Matrix and TransientGeometry
 When you add an occurrence of a part you can specify the placement using Vector and Matrix. The example below places the part at 20,2,2:       // Need some transient geometry to add in a part...     CComPtr pTransGeom;     hr = pInvApp->get_TransientGeometry(&pTransGeom);       CComPtr pMatrix; // Defaults to 0,0,0 position     hr = pTransGeom->CreateMatrix(&pMatrix);       CComPtr pVector; // Create a Vector to modify the Matrix     hr = pTransGeom->CreateVector(20,2,2,&pVector);     pMatrix->SetTranslation (pVector,VARIANT_TRUE) ;       CComPtr pOcc2;     hr = pOccs->Add(csFileName,pMatrix,&pOcc2) ;   The TransientGeometry pTransGeom object is an object which creates Vector and Matrix etc. It is a machine for making these abstract objects.   Also note that the second parameter of SetTranslation is set to VARIANT_TRUE. That means "Yes, reset any rotation components in the matrix". If you've only just created the matrix as in the above example, there will be no rotation components inside the matrix, but I generally do the call with VARIANT_TRUE.   You can rotate and move an occurrence of a part like this:      CComPtr pGeom = GetTransGeomPtr () ;       pGeom->CreateMatrix(&pFinalMatrix);      // First rotate ...    CComPtr pZAxis = nullptr;    pGeom->CreateVector(0, 0, 1, &pZAxis);      CComPtr pOrigin = nullptr;    pGeom->CreatePoint(0, 0, 0, &pOrigin);    pFinalMatrix->SetToRotation(kRadians, pZAxis, pOrigin);      // Then shift ....    CComPtr pTransMatrix;    pGeom->CreateMatrix(&pTransMatrix);    CComPtr pTransVector; // Create a Vector to modify the Matrix    pGeom->CreateVector(50.0,0.0,0.0,&pTransVector);    pTransMatrix->SetTranslation (pTransVector,VARIANT_TRUE) ;      pFinalMatrix->PostMultiplyBy(pTransMatrix);