I am trying to anchor a door to a wall and i want to relocate the door with Autodesk Architecture 2010 in combination with doing measurements by a tachymeter.
I am new to VBA and created a code to build up walls and doors using the measurement data from my tachymeter. My Problem is now to create the anchor to a wall and relocating a door. To solve my Problems i searched the Discussion Group and found a code in this Thread at the 4th comment:
But it actually doesnt work in Autocad Architecture 2010. I know it is performing well in combination with Autocad Architecture 2004. But cant find a way to perform it in Autodesk Architecture 2009 or 2010.
First of all, yes i tried the right library from Auocad Architecture 2004 in 2009 and 2010, but it stopped.
Hopefully someone can help me with this tiny problem. I think the problem can be solved very easy, but i simply dont get it :/
If you post your code example it is easier to solve.
Doors should automatically anchor unless you have release the anchors or placed without an anchor.
You will need to select your wall and door instead of creating as in Robs code. Then create an anchor pasing the wall to this and then door.attachanchor and pass the anchor.
Dim anchor As AecAnchorOpeningBaseToWall
anchor.Reference = wall
anchor.XDistance = Distance
anchor.FlipX = True
For moving the door use Anchor.xdistance = anchor.xdistance + "How far you wont to move it"