Pass 'not' category.id to relatedTo in Craft I have a search page that filters with these params:

{% set results = craft.entries({
    section: 'properties',
    price: range,
    search: query.location,
    relatedTo: status,
    order: priceDesc
}) %}


The status variable needs to be set to a 'not' this category (or an array of all the other categories), but I can't seem to phrase my param correctly.

I've tried both the string and array method with category ID's, like this:

relatedTo: ['not', category.id]

And this:

relatedTo: ['or', category1.id, category2.id, ...]

Advice?
You need to exclude the ids in order to achieve your goal. So instead of relatedTo not you need a normal related to but the not statement in your id

I'm not on my computer currently so I'll edit the exact code in about 2h but it's the same like that one 
https://craftcms.stackexchange.com/a/22532/5557

id.('and, not ' ~ idsOfEntriesYouWantToExclude|join(', not ')
Is the important part. In order to get them you just select all entries that are related to the thing you want to exclude 

Edit
untested but this should do it

{% relatedEntries = craft.entries.relatedTo(status).ids() %}
{# just for debugging to test if the queryString is correct #}
{% set queryString = 'not ' ~ relatedEntries|join(', not ') %}
{% set results = craft.entries({
    id: 'and, ' ~ queryString,
    section: 'properties',
    price: range,
    search: query.location,
    order: priceDesc
}) %}