Jump to content

Location criteria & spaces


Recommended Posts

 

I was wondering if anyone knew if there is difference between how VW treats the "location" of an object versus how it returns the surrounding (or adjacent?) space via worksheet functions? 

 

Does the GetSpaceNameForObj (or number) function work differently to location criteria? Are heights, drawing stacking order etc. at play here?

 

My specific issue here is with scheduling. I have created door/window schedules that (correctly) show the space that the object is within/directly bordering. In the extract below, "Room" is given by =GetSpaceNameForObj

 

image.png.fc313dfb23dfeb90308c62f80ad4926b.png

 

 

I then have separate room data sheets, which use a whole bunch of criteria to return various parameters/objects within spaces - in effect the inverse schedule.

 

Ideally, I would expect the relevant windows to show up in every space they are linked to in the above schedule, which is only the case some of the time. In the below, the windows are (correctly) returned with a database header that includes the criteria LOC=RM-SH-00-10.

 

image.png.ec266e4657214d66bb91e7840d0beedf.png

 

 

However, in other instances, the windows are not returned in the same way. For some windows, I have to manually extend the space to fully enclose the windows:

 

image.png.5eb9a2975e9a84c1c32ad8e7b17ec605.png

These windows do not show up as having their location in the yellow space, even though GetSpaceNameForObj returns the name of this space for these windows.

 

    image.png.787cdca0750a023d7994bce9465fdffa.png These do.

 

image.png.b7abf81430bbe73b25f22a80292a9382.png 

However, these windows are returned by LOC=[yellow space name].

 

 

Similarly, for doors, it seems LOC=[space name] only returns the door when the swing is fully within the space.

 

 

This would make sense to me if the GetSpaceNameForObj didn't work in reverse, but as that does I'm guessing the functions work in different ways? I'm guess I'm struggling to pin down exactly out what is considered a "surrounding" space. 

 

 

Link to comment
  • Vectorworks, Inc Employee

@Bart S 
The LOCATION criterion is a generic criterion that uses pure geographical boundaries to determine locations. Object A is located within Object B if it is clearly within the boundaries of Object B. This is why the windows will be located within the space only if the space encloses the windows.

 

GetSpaceNameForObj is a function that is specialized for spaces. It is aware of the context of a Space object and use special rules that apply to Spaces where objects don't necessarily need to be enclosed by a Space to belong to it. 

 

 

  • Like 1
Link to comment
  • Vectorworks, Inc Employee
10 hours ago, Bart S said:

@Hugues

That makes sense, thanks. 

 

Is there any way of creating a criterion for database headers that uses these similar rules to filter all objects "belonging" to a certain Space that you are aware of?

The only to do something like this is to create the database using DATABASEBYSCRIPT. You would have to write the script that filters the objects.

Link to comment
12 hours ago, Hugues said:

The only to do something like this is to create the database using DATABASEBYSCRIPT. You would have to write the script that filters the objects.

Ok thanks - I think that might be a bit beyond my pay grade for now! I've not explored scripting yet and not sure it's something I'd be too confident attempting right now.

 

Might be something I revisit when I have a spare afternoon..

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.

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.

×
×
  • Create New...