0

I load a step file in Eyeshot. The step is created with Solidworks from a file.

if I add codes like:

Entity[] a1 = ((BlockReference)viewportLayout1.Entities[0]).GetEntities(viewportLayout1.Blocks); 
Entity[] a2 = ((BlockReference)a1[1]).GetEntities(viewportLayout1.Blocks);
a2[0].Translate(0,0,1000);

Then a2[0] will move by (0,-1000,0) in viewport.

I want to all of entities to have their Coordinate-orientation be same. What I should do ?

I had try UpdateOrientedBoundingBox(), and nothing happen.

I don't know if my parameters are wrong or it can't change file's entity assembly relationship (and... sorry! my english is awful.)

Franck
  • 4,438
  • 1
  • 28
  • 55
  • What do you want to achieve exactly ? can you elaborate more. Also just to let you know that when you export from `Solidworks` try to use the `AP203` instead of `AP214` for `Step`. It has nothing to do with your issue but i personally encountered issues with some `AP214` not importing correctly while their `AP203` version works perfectly – Franck Jun 28 '18 at 16:26

1 Answers1

0

If you update an entity inside a Block you need to call viewportLayout1.Entities.Regen() afterwards.

ilCosmico
  • 1,319
  • 15
  • 26