Nico vd Schaaf Posted October 15, 2020 Share Posted October 15, 2020 Is it possible to use an IFC property as a database criteria in a WS? I can use GET IFC Property as a function in a WS column but I want to use it as a filter in the database formula. When I enter =GETIFCPROPERTY('Pset_SlabCommon.Reference')='floorfinish' it shows true/false for each item but I want the false items to be removed from the list... any help would be appreciated! Quote Link to comment
Kars Keizer Posted October 15, 2020 Share Posted October 15, 2020 (edited) When setting up criteria you can filter objects by having or not having an certain IFC attached. Is this what your are looking for? the formula it is creating looks like this: ((IFC_ENTITY='IfcDoor')) Edited October 15, 2020 by Kars Keizer Quote Link to comment
Nico vd Schaaf Posted October 15, 2020 Author Share Posted October 15, 2020 (edited) I'm trying to filter not by IFC Entity but by a specific IFC Criteria of that IFC Entity type... a little background might clarify: I have lots of different types of floor finish slab styles (for carpets). Both the class of the slab and the slab component are the same. Otherwise I can't control the 2d appearance of the slab by class. All different carpet types would have the same color on the drawing. The only option is to change the color within the slab style itself...which I hate...I like to draw 'by class' as much as possible...So in the worksheet I can't use classes to filter. The easiest way for now is to name the components which I want to be grouped identically. E.a. 'carpet'. And add specific info on color etc. in the description field of the slab style. This way I could just use =DATABASE((COMP='carpet')) as formula and filter by =GETIFCPROPERTY('IfcSlab.Description')... But naming all the components 'floorfinish' isn't ideal... Edited October 15, 2020 by Nico vd Schaaf Quote Link to comment
Kars Keizer Posted October 15, 2020 Share Posted October 15, 2020 I can not find a way to filter by IFC criteria. (not saying it is not possible), so in that way I can not help you. Is it maybe an idea to make an (simple) record and attach it to the components you want to filter later on? you can filter on having an record or on the text inside the record fields. just thinking along, I don't know if it fits your uses and drawingstyle. Quote Link to comment
Pat Stanford Posted October 16, 2020 Share Posted October 16, 2020 Take a look at this post and see if you can use something similar. Quote Link to comment
Nico vd Schaaf Posted October 20, 2020 Author Share Posted October 20, 2020 Thanks Pat, I'm not sure if I can capture the results of that script in a worksheet? I've already created a workaround so I can use the standard criteria... It seems that custom scripts can be very helpful. Do you have tips on learning to write them? Nico Quote Link to comment
Recommended Posts
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.