Jump to content
Sign in to follow this  
sle7en7

Embedded Symbols

Recommended Posts

Hello All,

I'm trying to do something simple in my point of view but my inability to code gets in the way and I couldn't find anything out there that was similar to this (after a 5-10 min search smirk ). What I'm trying to do is, use embedded symbols and link one's record field to the other and get it to show that value.

More simply...

I have a window symbol.

I also have a window number tag symbol.

I have a window information record as well, which has the window type field.

The window information record is attached to the window symbol and the window number tag symbol.

The number tag symbol is inside the window symbol.

I would like the window number tag symbol to show the window type field of the window information tag which is attached to the window symbol.

Is there a script out there to do this? Or another way you think that can accomplish the same thing?

I'm thinking somewhere between the lines of:


PROCEDURE Record Field 2 Record Field;

VAR mothersymbol: string
CONST MyRec="window information"
My Field="window type"

BEGIN 
SET (R.windownumbertag.windowtype IN S.window number tag) TO (R.windownumbertag.windowtype IN S.window symbol)
END
RUN Record Field 2 Record Field

Something like that... :crazy:

Thank you very much for your help and time.

Share this post


Link to post

A recordinstance can only be attached to one object. Text can only be connected to it's parent object record fields.

You can write a script that copies your values into the same record of an other symbol.

If you need this a lot you might consider it making an object instead. This way you don't 'forget' to update the data and it will be always correct.

Share this post


Link to post

Thanks for the quick response,

I think it would be a useful script to have at the least. If we can get it to loop at certain trigger points I think we can have almost like a parametric object which are controlled by sub-symbols. I know you are going to say why I don't use a PIO, because our office doesn't like them :crazy: so we are still CADing basically but I want my drawings to carry some information and be open to change.

But when you say I should consider making an object, you mean turning the window tag symbol into a object right?

Share this post


Link to post

But when you say I should consider making an object, you mean turning the window tag symbol into a object right?

Yes and no, I see I made a mistake in my first assumption so it won't be that easy.

To clarify:

Symbol A has record X attached, Symbol A contains a symbol B which also has record X attached.

Symbol C has record X attached but has no subsymbols.

The problem is that symbol A is unique, if we change the contents of it all instances will change. Thus we can't change the fields of the subsymbol B!

I think there are 2 ways to solve this:

  • Your object would be a very simple point object that places a symbol © and another symbol (B).
    The object will copy it's data into both symbols for the shared records.
    You can create 2 controlpoints to position them or you can create a special tag in symbol C to set the position for symbol B.
  • Your object would be a point object that places a symbol (A) the user can choose.
    As earlier mentioned the contents of symbol A can't be changed, but we can explode it. By exploding it you might loose some text fields bound to record fields but that can be fixed. You now have a symbol B that's not unique anymore, you can copy the recordfield data.

In both cases we can't directly let the user edit the recordfields of the symbol. What you can do is attach the same kind of record instances to the object and copy them into the symbol.

Honestly I'd go for the first option. This is the easiest way and it isn't hard to code it so it can work with any symbol. Your object just has to search common record instances between the 2 symbols and use those.

Edited by hippothamus

Share this post


Link to post
You can write a script that copies your values into the same record of an other symbol.

I think this is exactly what I need. I need a script to impose the "parentsymbol"s fields down to the "childsymbol" basically. Just need it to do it on its' own, with a looping script per say.

Now, I read your solutions as well, and yes I would do option 1 as well if I knew how :) and was able to understand it.

You can create 2 controlpoints to position them or you can create a special tag in symbol C to set the position for symbol B.

So you are saying there is an object (maybe you mean a group?) which has control points that dictate the place to insert a symbol? If so, I would love to learn how to do this object...

Thanks for the input though.

Share this post


Link to post

Ok, I just realized this is a bit of a lost cause, better to turn the ChildSymbol into group. I realize that two parentsymbols with 2 different record fields can't have a childsymbol which can accommodate those 2 different record values, because the parentsymbol needs to be the same throughout. Sorry for the confusion and stealing time.

Share this post


Link to post

So you are saying there is an object (maybe you mean a group?) which has control points that dictate the place to insert a symbol? If so, I would love to learn how to do this object...

Thanks for the input though.

You can create some parameters for objects. One of them is a controlpoint the user can move to position something.

Ok, I just realized this is a bit of a lost cause, better to turn the ChildSymbol into group. I realize that two parentsymbols with 2 different record fields can't have a childsymbol which can accommodate those 2 different record values, because the parentsymbol needs to be the same throughout. Sorry for the confusion and stealing time.

If you can create one symbol that combines both yes you have an easy solution.

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

 

7150 Riverwood Drive, Columbia, Maryland 21046, USA   |   Contact Us:   410-290-5114

 

© 2018 Vectorworks, Inc. All Rights Reserved. Vectorworks, Inc. is part of the Nemetschek Group.

×
×
  • Create New...