I'm currently trying to automatically cycle through all the parts in a given assembly within a drawing and place a sketched symbol at the COG of each part using C# (Visual Studio Express 2010 with Inventor 2012). The main code snippet is as follows:
I've tried several routes, but this is my basic approach. I feel like I am missing some GeometryIntent or something of that nature as the Sketched Symbols are showing up at the correct position but they are not associated with the given part (I've attached a screenshot of what is currently happening - the wipeouts you see should be displaying a property in them that is associated to the part). I also do not want the leader to be visible.
Any help/suggestions would be greatly appreciated. Thank you.
As of now, the sketched symbols appear at the center of mass but are not physically attached to the geometry. I've tried several methods using Geometry Intent to no avail.
All other posts on this subject utilize a user input or selection set. I want to create geometry intent at the center of each occurence and attach a sketched symbol to said geometry. Could someone atleast point me in the right direction? Any suggestions?