I am getting started using the Draftsight API to create add-ins using the Visual Studio C# templates installed with Draftsight Enterprise. So far everything has been going well. I can insert blocks, create sketch entities etc.
I am now trying to move all of the sketch entities in the document. I found the SketchManager.MoveEntites() method which (from the brief description) seems like what I want to use.
Here is a small part of related code:
string[] layerNames = GetLayers(dsDoc);
object entities;
object entitiesLong;
dsSketchManager.GetEntities(null, layerNames, out entitiesLong, out entities);
dsSketchManager.MoveEntities(100, 100, 0, entities); //why doesn't this work
The code compiles, and runs. There is no exception thrown but nothing happens.
I verified that I am indeed getting the right number of entities by doing this:
object[] dsEntities = (object[])entities;
dsCommandMessage.PrintLine("number of entities = " + dsEntities.Length.ToString());
