cancel
Showing results for 
Search instead for 
Did you mean: 
EN
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Proper way of adding a property value to single attribute

Hello again,

I'm struggling with the following situation:

1. I create a new group and new string property which I will use to put website url in it.

2. I create a new building material and make the new property available for it.

3. ( This is the problem step ) I want to assign the url value to that new building material which I created.

I'm reading about the ACAPI_​Element_​SetProperties(), which sets the properties, but the first parameter is elemGuid, which is not the building material guid, because when I try to pass it I get this error: The passed identifier is not a valid one, or valid, but not proper for the given operation.

So what's the proper way to set the property value to a particular building material ?

Thanks in advance, Julian
4 Replies 4
Anonymous
Not applicable
As far as my understanding goes the new property is set for the whole group in which belongs the new attribute which I created. Is there any way that I could set a different default value for each new attribute, before the element is even created ?
jcimentarov wrote:
3. ( This is the problem step ) I want to assign the url value to that new building material which I created.
I'm reading about the ACAPI_​Element_​SetProperties(), which sets the properties, but the first parameter is elemGuid, which is not the building material guid, because when I try to pass it I get this error: The passed identifier is not a valid one, or valid, but not proper for the given operation.
I might be misunderstanding, but are you trying to add properties to a building material? If so, that isn't currently supported – properties can only be assigned to elements (hence the command name ACAPI_​Element_​SetProperties).
Ralph Wessel BArch
Central Innovation
Akos Somorjai
Graphisoft
Graphisoft
Ralph wrote:
I might be misunderstanding, but are you trying to add properties to a building material? If so, that isn't currently supported – properties can only be assigned to elements (hence the command name ACAPI_​Element_​SetProperties).
Ralph is right, properties are not available (yet ) for attributes.

You can solve this for the current version by adding your own data to the attributes (ACAPI_Attribute_SetUserData ()) and provide your own UI for that (ACAPI_Register_AttributePanel ()).

Best, Akos
Anonymous
Not applicable
Akos wrote:
Ralph is right, properties are not available (yet ) for attributes.
Favorite teaser, really looking forward to properties on EVERYTHING, including stories, fills, pens and layouts. Basically replacing whatever scheme or text driven information field across ArchiCAD

Didn't find the answer?

Check other topics in this Forum

Back to Forum

Read the latest accepted solutions!

Accepted Solutions

Start a new conversation!