Function GetContractTenantsData
Gets a object of data about Tenants for a Tenancy
This function is a quick way to call the Function Class_ContractTenants
GetContractTenantsData([PROPCODE],[CONCODE],[GETMETHOD],[GETTYPE],[SEPARATOR],[EXPRESSION])
Parameters
# | Type | Passing | Default | Name | Description/Comments | |||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | string | required | n/a | PROPCODE | The property code, usually PROPCODE. | |||||||||||||||||||||||||||||||||||||||
2 | string | required | n/a | CONCODE | The contract code, usually CONCODE. | |||||||||||||||||||||||||||||||||||||||
3 | integer | required | 0 | GETMETHOD | Method to use to get data
These settings are the same as Function Class_ContractTenants
| |||||||||||||||||||||||||||||||||||||||
4 | integer | required | 0 | GETTYPE | 1 = Get unique email addresses (Calls GetEmailAddressList)
2 = Get unique data based on the expression in the next parameter (Calls GetExpressionList) | |||||||||||||||||||||||||||||||||||||||
5 | string | required | n/a | SEPARATOR | The separator character when more than one item returned. | |||||||||||||||||||||||||||||||||||||||
6 | string | required | n/a | EXPRESSION | The expression to use for each item (Tenant) record, when GETTYPE=2
Expression field names must always be prefixed with CLIENT irrelevant of where this is used. e.g. CLIENT.CLCODEDESC |
Returns
The resulting string
Examples
Get email address for each tenant pipe ( | ) delimited.
GetContractTenantsData(PROPCODE,CONCODE,0,1,"|","")
Get first name and surname for each tenant pipe ( | ) delimited.
GetContractTenantsData(PROPCODE,CONCODE,0,2,", ",",alltrim(CLIENT.FNAME)+' '+alltrim(CLIENT.SNAME)")
Get mobile number for each tenant pipe with a HTML break ( <br> ) in between.
GetContractTenantsData(PROPCODE,CONCODE,0,2,"<br>",",alltrim(CLIENT.MOBILE)")