Jump to content

naming an object so vectorscript can use it


Recommended Posts


If you have drawn an object, is it possible to give this object a name? Because I would like to make a handle to this object in vectorscript (using GetObject function).

I know it is possible to give a name using NameObject, but this only assigns a name to the object next created.

The deeper problem: I try to link a record format to a symbol. The information in the record formats is different for each symbol-instance. When I try to get a value from a recordfield, I only get the "default" value instead of the value assigned to a specific instance.

So I need to adress a symbol-instance, but I can't get this working.

Any ideas? Is there some kind of internal naming of symbolinstances?

Link to comment


To answer your first question, if you have just drawn the object and it is still selected, Open the Object Info Palette (OIP) and click on the Data Tab at the bottom. Above the record panes is a text field. Type your name in there. It may say *DEFAULTS* when you change tabs, or if the object already has a name its name will appear there, or it may be blank if the data pane is already selected when you open the OIP. It's not a well labeled field of the OIP, but that's where you find it.

Someone better suited than I will have to address your second question.


Link to comment

The way to set an object's name in vectorscript is to use setname.

procedure setname(ObjHandle,Name);

As far as your second question I'm confused as to exactly what you are asking.

if you want to get record information you can use either GetRField which will give you the record value or GetRecord which will return the specified handle. If you want to set a record's info you can use either setRecord or SetRField.

I hope this helps.


Link to comment


Originally posted by dfortin:

As far as your second question I'm confused as to exactly what you are asking.

Thanks for your post. I couldn't find how to name an object without using Vectorscript. Because of that I couldn't get correct handles to my objects.

The previous post already helped me out!

Link to comment

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.

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.

  • Create New...