2023-04-20 01:51 PM - last edited on 2023-05-20 12:17 AM by Gordana Radonic
It would be soooo nice if we could parse the text in an option-set selection using SPLIT.
This would let us key into a data stream instead of only a single bit of data.
Solved! Go to Solution.
2023-04-27 12:43 AM - edited 2023-04-27 12:47 AM
You can do this currently. I have just tried it in Ac26 and it works for me.
Create a new Property with the "String" Data Type, and use the STR function in its defining expression to convert your "Option Set" Data Type to "String" Data Type. Then you will be able to use the SPLIT function to obtain the individual parts of the Property.
2023-04-21 01:31 AM
Could you elaborate a bit more on this? Maybe provide an example?
2023-04-27 12:25 AM
Sorry,
The point here is that in building custom properties in the property manager one of the field types is to have an option set.... Option Sets are great for data integrity, but a chosen option from an option set can not be worked on with an expression. We can use an expression to display the option that was chosen in a schedule or in autotext, but you can not use any of the text-handling features to break apart the chosen option.
For example if I had an option set for finishes I might choose an option like this:
ST,B,Marble,3/4",Nero Marquina,Stone USA Distributor
If I could use the standard text handling features to parse the text in the option using the coma as a delimiter, then I could turn the option into a database that lets me use which bit of information in need for the task at hand....
I could have a label that points to the object in section that reads "ST-B" for stone type B.
I could have a schedule that is used to create a legend for stone finishes that says Type "B" - Nero Marquina.
The possibilities are endless.
Of course I can do this without using an option set, but option sets dummy proof project data, and if I change something in the option set then everyplace it is use get updated instead of needing to update multiple properties.
But sadly as it is now the case - whatever is displayed in the property for an option set is NOT text.
If Archicad really want to be the BIM, then this is part of the story.
Please use your magical influence and make this happen in the next V25 and V26 update!!!
Thank you for the magic!!
2023-04-27 12:43 AM - edited 2023-04-27 12:47 AM
You can do this currently. I have just tried it in Ac26 and it works for me.
Create a new Property with the "String" Data Type, and use the STR function in its defining expression to convert your "Option Set" Data Type to "String" Data Type. Then you will be able to use the SPLIT function to obtain the individual parts of the Property.
2023-04-27 12:54 AM
Ohhhh Myyyyy - and you bring the magic unto me!
Do you think this will work in V25?
Heck - it is already wine time in Texas - bit tipsy - I will have to try this for myself
I am so excited - i just wet myself.
I am going to start calling you "The Magic Man"!
Thank you sir
2023-04-27 01:24 AM
Cool beans - this works in V25 as well....
back last year I was complaining about this and you said it could not be done and you suggested I make a wish - I probably made the wish, but I really don't remember.
Maybe they got it fixed or we both just did not know how to pull it off.
Either way - don't really care - just glad I know how to make it work now....
This is amazing!!!
2023-04-27 06:14 AM
That other wish still stands.
This works for Properties with the "Option Set " Data Type only if the "allow multiple choices" checkbox is not checked in the Options Setup Dialog. Otherwise, they will return a "NULL" value.
By the way, I checked this again, and you do not even need to convert an Option Set Property to a String Property, it works without that as well, after all, an Option Set is still a String.
2023-05-03 01:27 AM - last edited on 2024-04-06 12:27 PM by Laszlo Nagy
You are correct Laszlo - it was the Multiple Choices that could not be split. I went back and found that I had been splitting the Options back in V25... I get confused at the end of the day after my first glass of wine. It would be amazing to be able to parse out multiple checkbox items with expressions.
Thank you again for being such a great voice in the Archicad Wilderness.
2024-04-06 12:43 AM
almost a year in for this post, but is there still no way for this to work with multiple choices allowed for the Options Setup?
for the first image below, we have set of signage codes that that we use for our door schedule. i'd like for our users to easily see what the code stand for, instead of having to jump between windows. it has the code (SN1, SN2...), a colon as delimeter, and the note at the end explaining the type of signage.
the second image below is what should appear in the door schedule
i'm testing this in 25, but we'll be moving to 27 soon.