實體形式選項

提供對表格表單的所有相關資訊的存取。

適用於

模型導向應用程式

屬性

createFromEntity

指定根據對應資料行值提供預設值的記錄。 查閱物件具有下列屬性: id、 name和 entityType。

類型: LookupValue

entityId

要顯示表單的資料表記錄的唯一 ID。

類型:string

entityName

要顯示表單的資料表的邏輯名稱。

類型:string

formId

要顯示之表單執行個體的ID。

類型:string

height

要顯示的表單視窗高度(以像素為單位)。

類型:number

openInNewWindow

是否要在新視窗中顯示表單。

類型:boolean

使用QuickCreateForm

是否開啟快速建立表單。 預設值是 false。

類型:boolean

寬度

要顯示的表單視窗寬度(以像素為單位)。

類型:boolean

視窗位置

指定螢幕上的視窗位置。

類型:number

此 windowPosition 值是具有下列可能值的數字:

價值觀 Position
1 置中
2 邊

Example

private onRowClick(event: Event): void {
    let rowRecordId = (event.currentTarget as HTMLTableRowElement).getAttribute(
      RowRecordId
    );
    if (rowRecordId) {
      let entityreference = this.contextObj.parameters.simpleTableGrid.records[
        rowRecordId
      ].getNamedReference();
      let entityFormOptions = {
        entityName: entityreference.entityType!,
        entityId: entityreference.id
      };
      this.contextObj.navigation.openForm(entityFormOptions);
    }
  }

Power Apps 元件架構 API 參考
Power Apps 元件架構概觀