Showing results for 
Search instead for 
Did you mean: 
Level: Power Up

EntityReference type definition

When using EntityRecord.getNamedReference(), as per the docs I should receive an object of type EntityReference. When I view the type definition for this type it currently contains the following properties:


1. id -> object with guid property

2. etn -> optional

3. name


When I debug my pcf control and place breakpoints on the ts file in Chrome where this method is called I am getting the attached object returned, which does not contain and "etn" property.


This both does not match with the Type definition, and, as there is no "etn" property of this object, this means that I am not able to get the entity logical name from the reference. I have to edit the type definition and then add a couple extra optional properties to this type:


1. entityName

2. logicalName


On top of this, ComponentFramework.Context.navigation.openForm takes an EntityFormOptions object which contains a property: createFromEntity, of type EntityReference. If I follow the current type definition for this object type, I cannot use openForm to open a create entity form as the Id parameter is incorrect for the "createFromEntity". From the documentation the properties for the "createFromEntity" EntityReference should be a flat set of strings, but the type definition for the id property indicates an object with a property.




Community Support Team
Community Support Team

Re: EntityReference type definition

Hi @eleung83 ,


Please try to raise a support ticket here:




Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources


Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!


Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020


Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Kudoed Authors (Last 30 Days)
Users online (4,077)