Views:

Description

Creates an in-memory entity.

This allows you to build up complicated entities in memory with which you can then use the function CreateRecordFromEntity('entity') to physically create the record in the database and receive the GUID of the new record.

Signature

CreateEntity('entityname', 
  SetAttribute('attributename', 'attributevalue')
)

Note 1: Fields of type lookup  need SetAttributeLookup('fieldname', 'entityname', 'recordguid') 
Note 2: Fields of type PartyList need SetAttributePartyList('fieldname', 'entityname', 'partyguid' , 'partyguid')"

Example

CreateEntity(
  'contact',
  SetAttribute('firstname', 'Bill'),
  SetAttribute('lastname', 'gates'),
  SetAttribute('creditlimit', '5000'),
  SetAttribute('description', '?'),
  SetAttributeLookup('preferredsystemuserid',
    'systemuser',
    '670dd379c-ee2f-11db-8314-0800200c888')
)

Parameters

Name Type Description Required
inputstring xxxx xxxx xxxx
stringtobereplaced xxxx xxxx xxxx
replacementstring xxxx xxxx xxxx