Dear all
I have a compont like the following fig. it's pathname is "d:\try\head.sldprt"
when i add this componet to assembly,I use this coads:
boolstatus = modeldoc2.AddComponent("D:\try\head.SLDPRT", 0, 0, 0)
unfortunately after that I get result like the following fig.
how can i inset this componet at assembly's origin,in other words, let this part's origin and assem's origin coincident?
I do't want to calculate the part center's x,y location value before add,
such as boolstatus = modeldoc2.AddComponent("D:\try\head.SLDPRT", 0, -0.076521211, 0),it's too complex
May be I should use MathUtility, but i am not familar with this api,
Could you kindly give me coads to achieve?
thanks
Zhengjun yuan
SolidworksApi macros