Author Topic: Setting an existing Door Style  (Read 6772 times)

0 Members and 2 Guests are viewing this topic.

BAshworth

  • Guest
Re: Setting an existing Door Style
« Reply #15 on: July 27, 2006, 10:31:15 AM »
Don't say stuff like that.  I'm going to be hanging around with him all weekend, he doesn't need head enlargement therapy right now.

Hmm.. gotta get that pinky ring shined up if it's going to start getting kissed. :D

I agree, it's a BS way of setting the active object style within ADT.  From what I understood, more recent versions of the ADT object model are more comprehensive in what they expose directly through VBA.  I use ADT 2004.

I got to thinking, and I haven't tested it, but it might work if you add a wall to the drawing of a particular style, then delete it via code.  I know that if you add a wall manually, it defaults to the last style that was drawn when you go to draw the next one.  However, I don't know if the same happens when you add a wall via code.

Of course, at that point, you might have been ahead to go ahead and write the function to modify the registry entry.  It's not all that difficult to do, and once you have the function written, you can expand it to set all sorts of other object styles as current.


Matersammichman

  • Guest
Re: Setting an existing Door Style
« Reply #16 on: July 27, 2006, 10:41:23 AM »
Walls are the easy one...Doors on the other hand fight against you when using SendCommand
...try it, you won't like it.

BAshworth

  • Guest
Re: Setting an existing Door Style
« Reply #17 on: July 27, 2006, 10:51:26 AM »
Walls are the easy one...Doors on the other hand fight against you when using SendCommand
...try it, you won't like it.

Sorry, I meant doors.  I was thinking doors, but typed walls. Yes I completely understand your frustration.  I have never experienced more WTF?! moments than when I started working with the ADT object model. Are you looking to just set the active style, or do you also want to leave it in the middle of the dooradd command so the user can place the door?
« Last Edit: July 27, 2006, 10:55:27 AM by BAshworth »

Matersammichman

  • Guest
Re: Setting an existing Door Style
« Reply #18 on: July 27, 2006, 10:56:31 AM »
DEFINITELY the latter...(Middle of the code)...
and If you have code to do this flawlessly, you get the Guru cap for the day!!!

BAshworth

  • Guest
Re: Setting an existing Door Style
« Reply #19 on: July 27, 2006, 11:10:43 AM »
DEFINITELY the latter...(Middle of the code)...
and If you have code to do this flawlessly, you get the Guru cap for the day!!!


Code: [Select]
ThisDrawing.SendCommand ("dooradd" & vbCr & vbCr & "ST" & vbCr & "Your wall style here" & vbCr)

However that leaves us at adding a free-standing door.  Not one connected to a wall assembly.   I'll give this some more work today to figure the rest out.   *grumbles about f'n dooradd command.*

DaveW

  • Guest
Re: Setting an existing Door Style
« Reply #20 on: July 27, 2006, 02:21:52 PM »
A few notes on ADT.

Both ADT and Revit are suppose to follow the design/build principle set forth as concept by the PhD's at the top technical universities. Autodesk got wind of their concept and bought Revit to take it to the next level. Unfortunately, they never understood the "entire" concept. They understood to concept of making objects react to each other and thought they could run with it. What they missed was the fundamental understanding not forcing the user to predefine a design and still get the manufacturing information. The reason being, at that time no company anywhere knew how to do it. That is what design/build was just a concept. As it stands right now, they are driving / creating the parts with a database. This starting point of driving/ creating voids the basic principal of design/build, as the user never really has true design freedom and can still get the manufacturing information. The problem lies in the fact that you must have the 3D distances AND associate those distances or dimensions to the Length, Width, and Thickness. Because the core modeling engine data base is really only points in space that do not have orientation information, they are just a point, no company every figure out how to get the Length, Width, and, Thickness without driving the drawing. This only applies to industries where the source raw material is solid. The rapid prototyping industry is unaffected and can do design/build, because their source raw material is a liquid. ADT and many other driven softwares can work well and automate a great many things. The problems always come up when you are creating something that the formulas were not created to handle. In building custom structures, even if you had enough formulas, the basic end user could not remember them all.

About the VB in ADT. There is only one company that has an OEM to ADT. That is Americad. I talked with them at great length a while back and they told me that their licence prevents them from adding any code or method that can extract information that is not already available through their exposed methods! What a bummer, huh?

Enough trivia.

Have fun guys,

Dave